From: Ruifeng Wang <ruifeng.wang@arm.com>
To: aconole@redhat.com, maicolgabriel@hotmail.com,
bruce.richardson@intel.com, konstantin.ananyev@intel.com,
cristian.dumitrescu@intel.com, yipeng1.wang@intel.com,
sameh.gobriel@intel.com
Cc: dev@dpdk.org, david.marchand@redhat.com,
anatoly.burakov@intel.com, gavin.hu@arm.com,
honnappa.nagarahalli@arm.com, juraj.linkes@pantheon.tech,
nd@arm.com, Ruifeng Wang <ruifeng.wang@arm.com>
Subject: [dpdk-dev] [PATCH v3 2/4] ci: generate fast-tests suite base on hugepage availability
Date: Fri, 13 Mar 2020 16:16:12 +0800 [thread overview]
Message-ID: <20200313081614.195335-3-ruifeng.wang@arm.com> (raw)
In-Reply-To: <20200313081614.195335-1-ruifeng.wang@arm.com>
In environments where hugepage are not available, such as
containers, many cases in fast-tests suite should also run
if no-huge EAL option is used.
Flag is appended to each case in fast-tests suite to indicate
whether it lives with no-huge mode.
With the flag, fast-tests suite can be generated based on
detected hugepage availability of building environment.
All cases will be valid if hugepage is available, whereas
only applicable cases will be added if environment has no
hugepage support.
Suggested-by: Aaron Conole <aconole@redhat.com>
Signed-off-by: Ruifeng Wang <ruifeng.wang@arm.com>
Reviewed-by: Gavin Hu <gavin.hu@arm.com>
---
app/test/meson.build | 216 ++++++++++++++++++++++++-------------------
1 file changed, 120 insertions(+), 96 deletions(-)
diff --git a/app/test/meson.build b/app/test/meson.build
index 0a2ce710f..dd121a297 100644
--- a/app/test/meson.build
+++ b/app/test/meson.build
@@ -154,87 +154,89 @@ test_deps = ['acl',
'timer'
]
+# Each test is marked with flag true/false
+# to indicate whether it can run in no-huge mode.
fast_test_names = [
- 'acl_autotest',
- 'alarm_autotest',
- 'atomic_autotest',
- 'byteorder_autotest',
- 'cmdline_autotest',
- 'common_autotest',
- 'cpuflags_autotest',
- 'cycles_autotest',
- 'debug_autotest',
- 'eal_flags_c_opt_autotest',
- 'eal_flags_master_opt_autotest',
- 'eal_flags_n_opt_autotest',
- 'eal_flags_hpet_autotest',
- 'eal_flags_no_huge_autotest',
- 'eal_flags_w_opt_autotest',
- 'eal_flags_b_opt_autotest',
- 'eal_flags_vdev_opt_autotest',
- 'eal_flags_r_opt_autotest',
- 'eal_flags_mem_autotest',
- 'eal_flags_file_prefix_autotest',
- 'eal_flags_misc_autotest',
- 'eal_fs_autotest',
- 'errno_autotest',
- 'event_ring_autotest',
- 'fib_autotest',
- 'fib6_autotest',
- 'func_reentrancy_autotest',
- 'flow_classify_autotest',
- 'hash_autotest',
- 'interrupt_autotest',
- 'logs_autotest',
- 'lpm_autotest',
- 'lpm6_autotest',
- 'malloc_autotest',
- 'mbuf_autotest',
- 'mcslock_autotest',
- 'memcpy_autotest',
- 'memory_autotest',
- 'mempool_autotest',
- 'memzone_autotest',
- 'meter_autotest',
- 'multiprocess_autotest',
- 'per_lcore_autotest',
- 'prefetch_autotest',
- 'rcu_qsbr_autotest',
- 'red_autotest',
- 'rib_autotest',
- 'rib6_autotest',
- 'ring_autotest',
- 'rwlock_test1_autotest',
- 'rwlock_rda_autotest',
- 'rwlock_rds_wrm_autotest',
- 'rwlock_rde_wro_autotest',
- 'sched_autotest',
- 'spinlock_autotest',
- 'stack_autotest',
- 'stack_lf_autotest',
- 'string_autotest',
- 'table_autotest',
- 'tailq_autotest',
- 'timer_autotest',
- 'user_delay_us',
- 'version_autotest',
- 'crc_autotest',
- 'delay_us_sleep_autotest',
- 'distributor_autotest',
- 'eventdev_common_autotest',
- 'fbarray_autotest',
- 'hash_readwrite_func_autotest',
- 'ipsec_autotest',
- 'kni_autotest',
- 'kvargs_autotest',
- 'member_autotest',
- 'metrics_autotest',
- 'power_cpufreq_autotest',
- 'power_autotest',
- 'power_kvm_vm_autotest',
- 'reorder_autotest',
- 'service_autotest',
- 'thash_autotest',
+ ['acl_autotest', true],
+ ['alarm_autotest', false],
+ ['atomic_autotest', false],
+ ['byteorder_autotest', true],
+ ['cmdline_autotest', true],
+ ['common_autotest', true],
+ ['cpuflags_autotest', true],
+ ['cycles_autotest', true],
+ ['debug_autotest', true],
+ ['eal_flags_c_opt_autotest', false],
+ ['eal_flags_master_opt_autotest', false],
+ ['eal_flags_n_opt_autotest', false],
+ ['eal_flags_hpet_autotest', false],
+ ['eal_flags_no_huge_autotest', false],
+ ['eal_flags_w_opt_autotest', false],
+ ['eal_flags_b_opt_autotest', false],
+ ['eal_flags_vdev_opt_autotest', false],
+ ['eal_flags_r_opt_autotest', false],
+ ['eal_flags_mem_autotest', false],
+ ['eal_flags_file_prefix_autotest', false],
+ ['eal_flags_misc_autotest', false],
+ ['eal_fs_autotest', true],
+ ['errno_autotest', true],
+ ['event_ring_autotest', true],
+ ['fib_autotest', true],
+ ['fib6_autotest', true],
+ ['func_reentrancy_autotest', false],
+ ['flow_classify_autotest', false],
+ ['hash_autotest', true],
+ ['interrupt_autotest', true],
+ ['logs_autotest', true],
+ ['lpm_autotest', true],
+ ['lpm6_autotest', true],
+ ['malloc_autotest', false],
+ ['mbuf_autotest', false],
+ ['mcslock_autotest', false],
+ ['memcpy_autotest', true],
+ ['memory_autotest', false],
+ ['mempool_autotest', false],
+ ['memzone_autotest', false],
+ ['meter_autotest', true],
+ ['multiprocess_autotest', false],
+ ['per_lcore_autotest', true],
+ ['prefetch_autotest', true],
+ ['rcu_qsbr_autotest', true],
+ ['red_autotest', true],
+ ['rib_autotest', true],
+ ['rib6_autotest', true],
+ ['ring_autotest', true],
+ ['rwlock_test1_autotest', true],
+ ['rwlock_rda_autotest', true],
+ ['rwlock_rds_wrm_autotest', true],
+ ['rwlock_rde_wro_autotest', true],
+ ['sched_autotest', true],
+ ['spinlock_autotest', true],
+ ['stack_autotest', false],
+ ['stack_lf_autotest', false],
+ ['string_autotest', true],
+ ['table_autotest', true],
+ ['tailq_autotest', true],
+ ['timer_autotest', false],
+ ['user_delay_us', true],
+ ['version_autotest', true],
+ ['crc_autotest', true],
+ ['delay_us_sleep_autotest', true],
+ ['distributor_autotest', false],
+ ['eventdev_common_autotest', true],
+ ['fbarray_autotest', true],
+ ['hash_readwrite_func_autotest', false],
+ ['ipsec_autotest', true],
+ ['kni_autotest', false],
+ ['kvargs_autotest', true],
+ ['member_autotest', true],
+ ['metrics_autotest', true],
+ ['power_cpufreq_autotest', false],
+ ['power_autotest', true],
+ ['power_kvm_vm_autotest', false],
+ ['reorder_autotest', true],
+ ['service_autotest', true],
+ ['thash_autotest', true],
]
perf_test_names = [
@@ -334,13 +336,13 @@ if dpdk_conf.has('RTE_LIBRTE_RING_PMD')
test_sources += 'test_link_bonding_mode4.c'
test_sources += 'sample_packet_forward.c'
test_sources += 'test_pdump.c'
- fast_test_names += 'ring_pmd_autotest'
+ fast_test_names += [['ring_pmd_autotest', true]]
perf_test_names += 'ring_pmd_perf_autotest'
- fast_test_names += 'event_eth_tx_adapter_autotest'
- fast_test_names += 'bitratestats_autotest'
- fast_test_names += 'latencystats_autotest'
+ fast_test_names += [['event_eth_tx_adapter_autotest', false]]
+ fast_test_names += [['bitratestats_autotest', true]]
+ fast_test_names += [['latencystats_autotest', true]]
driver_test_names += 'link_bonding_mode4_autotest'
- fast_test_names += 'pdump_autotest'
+ fast_test_names += [['pdump_autotest', true]]
endif
if dpdk_conf.has('RTE_LIBRTE_POWER')
@@ -368,7 +370,7 @@ if dpdk_conf.has('RTE_LIBRTE_COMPRESSDEV')
test_dep_objs += compress_test_dep
test_sources += 'test_compressdev.c'
test_deps += 'compressdev'
- fast_test_names += 'compressdev_autotest'
+ fast_test_names += [['compressdev_autotest', false]]
endif
endif
@@ -395,6 +397,17 @@ dpdk_test = executable('dpdk-test',
install_rpath: driver_install_path,
install: true)
+has_hugepage = true
+if host_machine.system() == 'linux'
+ check_hugepage = run_command('cat',
+ '/proc/sys/vm/nr_hugepages')
+ if (check_hugepage.returncode() != 0 or
+ check_hugepage.stdout().strip() == '0')
+ has_hugepage = false
+ endif
+endif
+message('hugepage availbility: @0@'.format(has_hugepage))
+
# some perf tests (eg: memcpy perf autotest)take very long
# to complete, so timeout to 10 minutes
timeout_seconds = 600
@@ -407,22 +420,33 @@ test_args = [num_cores_arg]
foreach arg : fast_test_names
if (get_option('default_library') == 'shared' and
- arg == 'event_eth_tx_adapter_autotest')
+ arg[0] == 'event_eth_tx_adapter_autotest')
foreach drv:dpdk_drivers
test_args += ['-d', drv.full_path().split('.a')[0] + '.so']
endforeach
endif
if host_machine.system() == 'linux'
- test(arg, dpdk_test,
- env : ['DPDK_TEST=' + arg],
- args : test_args +
- ['--file-prefix=@0@'.format(arg)],
- timeout : timeout_seconds_fast,
- is_parallel : false,
- suite : 'fast-tests')
+ if has_hugepage
+ test(arg[0], dpdk_test,
+ env : ['DPDK_TEST=' + arg[0]],
+ args : test_args +
+ ['--file-prefix=@0@'.format(arg[0])],
+ timeout : timeout_seconds_fast,
+ is_parallel : false,
+ suite : 'fast-tests')
+ elif arg[1]
+ test(arg[0], dpdk_test,
+ env : ['DPDK_TEST=' + arg[0]],
+ args : test_args +
+ ['--no-huge'] + ['-m 2048'] +
+ ['--file-prefix=@0@'.format(arg[0])],
+ timeout : timeout_seconds_fast,
+ is_parallel : false,
+ suite : 'fast-tests')
+ endif
else
- test(arg, dpdk_test,
- env : ['DPDK_TEST=' + arg],
+ test(arg[0], dpdk_test,
+ env : ['DPDK_TEST=' + arg[0]],
args : test_args,
timeout : timeout_seconds_fast,
is_parallel : false,
--
2.17.1
next prev parent reply other threads:[~2020-03-13 8:17 UTC|newest]
Thread overview: 46+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-02-25 7:32 [dpdk-dev] [PATCH v1] ci: add test suite run without hugepage Ruifeng Wang
2020-02-25 9:14 ` David Marchand
2020-02-25 14:36 ` Aaron Conole
2020-02-25 15:39 ` Ruifeng Wang
2020-02-25 15:56 ` Aaron Conole
2020-02-26 2:47 ` Ruifeng Wang
2020-02-25 15:23 ` Ruifeng Wang
2020-02-28 4:19 ` [dpdk-dev] [PATCH v2 0/2] no-huge test suite Ruifeng Wang
2020-02-28 4:19 ` [dpdk-dev] [PATCH v2 1/2] ci: allow multiple test suites to run in one job Ruifeng Wang
2020-02-28 4:19 ` [dpdk-dev] [PATCH v2 2/2] ci: add test suite run without hugepage Ruifeng Wang
2020-03-04 17:31 ` Aaron Conole
2020-03-05 3:41 ` Ruifeng Wang
2020-03-05 14:36 ` Aaron Conole
2020-03-06 8:09 ` Ruifeng Wang
2020-03-06 15:56 ` Aaron Conole
2020-03-06 16:05 ` David Marchand
2020-03-06 16:16 ` Aaron Conole
2020-03-06 16:33 ` Bruce Richardson
2020-03-07 14:36 ` Ruifeng Wang
2020-03-12 7:13 ` Juraj Linkeš
2020-03-12 8:33 ` Ruifeng Wang
2020-03-13 8:16 ` [dpdk-dev] [PATCH v3 0/4] no-huge unit test Ruifeng Wang
2020-03-13 8:16 ` [dpdk-dev] [PATCH v3 1/4] test: enable tests to run in no-huge mode Ruifeng Wang
2020-03-17 12:49 ` Aaron Conole
2020-03-17 19:15 ` Wang, Yipeng1
2020-03-13 8:16 ` Ruifeng Wang [this message]
2020-03-17 12:50 ` [dpdk-dev] [PATCH v3 2/4] ci: generate fast-tests suite base on hugepage availability Aaron Conole
2020-03-23 8:56 ` David Marchand
2020-03-23 9:32 ` David Marchand
2020-03-23 15:50 ` Ruifeng Wang
2020-03-28 16:17 ` David Marchand
2020-03-30 16:03 ` Ruifeng Wang
2020-04-10 12:25 ` David Marchand
2020-03-23 15:36 ` Ruifeng Wang
2020-03-13 8:16 ` [dpdk-dev] [PATCH v3 3/4] ci: proceed with verification without hugepage Ruifeng Wang
2020-03-17 12:50 ` Aaron Conole
2020-03-13 8:16 ` [dpdk-dev] [PATCH v3 4/4] ci: enable unit test for aarch64 Ruifeng Wang
2020-03-17 12:50 ` Aaron Conole
2020-03-13 12:48 ` [dpdk-dev] [PATCH v3 0/4] no-huge unit test Aaron Conole
2020-03-13 13:04 ` Aaron Conole
2020-03-13 15:54 ` David Marchand
2020-03-16 8:27 ` Ruifeng Wang
2020-03-16 13:25 ` Aaron Conole
2020-03-16 14:13 ` Aaron Conole
2020-03-16 14:41 ` Bruce Richardson
2020-03-17 17:02 ` dwilder
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200313081614.195335-3-ruifeng.wang@arm.com \
--to=ruifeng.wang@arm.com \
--cc=aconole@redhat.com \
--cc=anatoly.burakov@intel.com \
--cc=bruce.richardson@intel.com \
--cc=cristian.dumitrescu@intel.com \
--cc=david.marchand@redhat.com \
--cc=dev@dpdk.org \
--cc=gavin.hu@arm.com \
--cc=honnappa.nagarahalli@arm.com \
--cc=juraj.linkes@pantheon.tech \
--cc=konstantin.ananyev@intel.com \
--cc=maicolgabriel@hotmail.com \
--cc=nd@arm.com \
--cc=sameh.gobriel@intel.com \
--cc=yipeng1.wang@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).