numam-dpdk/lib
David Marchand 8674b203f1 eal: remove limitation on cpuset with --lcores
Contrary to the -c/-l options, where a logical core runs on the same
physical core in a 1:1 fashion (example: lcore 0 runs on core 0, lcore
16 runs on core 16), the --lcores option makes it possible to select the
physical cores on which runs a logical core.

However the current parsing code still limits the cpuset to the
[0, RTE_MAX_LCORE] range.

Example, before the patch, on a 24 cores system with RTE_MAX_LCORE == 16:
$ ./master/app/testpmd --no-huge --no-pci -m 512 --log-level *:debug \
 --lcores 0@16,1@17 -- -i --total-num-mbufs 2048
EAL: Detected lcore 0 as core 0 on socket 0
EAL: Detected lcore 1 as core 1 on socket 0
EAL: Detected lcore 2 as core 2 on socket 0
EAL: Detected lcore 3 as core 3 on socket 0
EAL: Detected lcore 4 as core 4 on socket 0
EAL: Detected lcore 5 as core 5 on socket 0
EAL: Detected lcore 6 as core 6 on socket 0
EAL: Detected lcore 7 as core 8 on socket 0
EAL: Detected lcore 8 as core 9 on socket 0
EAL: Detected lcore 9 as core 10 on socket 0
EAL: Detected lcore 10 as core 11 on socket 0
EAL: Detected lcore 11 as core 12 on socket 0
EAL: Detected lcore 12 as core 13 on socket 0
EAL: Detected lcore 13 as core 14 on socket 0
EAL: Detected lcore 14 as core 0 on socket 0
EAL: Detected lcore 15 as core 1 on socket 0
EAL: Skipped lcore 16 as core 2 on socket 0
EAL: Skipped lcore 17 as core 3 on socket 0
EAL: Skipped lcore 18 as core 4 on socket 0
EAL: Skipped lcore 19 as core 5 on socket 0
EAL: Skipped lcore 20 as core 6 on socket 0
EAL: Skipped lcore 21 as core 8 on socket 0
EAL: Skipped lcore 22 as core 9 on socket 0
EAL: Skipped lcore 23 as core 10 on socket 0
EAL: Skipped lcore 24 as core 11 on socket 0
EAL: Skipped lcore 25 as core 12 on socket 0
EAL: Skipped lcore 26 as core 13 on socket 0
EAL: Skipped lcore 27 as core 14 on socket 0
EAL: Support maximum 16 logical core(s) by configuration.
EAL: Detected 16 lcore(s)
EAL: Detected 1 NUMA nodes
EAL: invalid parameter for --lcores

We can remove this limitation by using a cpuset_t (which is a more
natural type since this is what gets passed to pthread_setaffinity*
in the end).

After the patch:
$ ./master/app/testpmd --no-huge --no-pci -m 512 --log-level *:debug \
 --lcores 0@16,1@17 -- -i --total-num-mbufs 2048
[...]
EAL: Master lcore 0 is ready (tid=7f94217bbc00;cpuset=[16])
EAL: lcore 1 is ready (tid=7f941f491700;cpuset=[17])

Signed-off-by: David Marchand <david.marchand@redhat.com>
2020-01-21 01:22:33 +01:00
..
librte_acl build: align symbols with global ABI version 2019-11-20 23:05:39 +01:00
librte_bbdev build: remove individual library versions 2019-11-20 23:05:39 +01:00
librte_bitratestats build: align symbols with global ABI version 2019-11-20 23:05:39 +01:00
librte_bpf bpf/arm: fix clang build 2019-11-21 00:30:39 +01:00
librte_cfgfile cfgfile: fix symbols map 2020-01-20 00:29:49 +01:00
librte_cmdline build: align symbols with global ABI version 2019-11-20 23:05:39 +01:00
librte_compressdev build: remove individual library versions 2019-11-20 23:05:39 +01:00
librte_cryptodev cryptodev: support ECPM 2020-01-15 15:01:55 +01:00
librte_distributor build: align symbols with global ABI version 2019-11-20 23:05:39 +01:00
librte_eal eal: remove limitation on cpuset with --lcores 2020-01-21 01:22:33 +01:00
librte_efd build: align symbols with global ABI version 2019-11-20 23:05:39 +01:00
librte_ethdev ethdev: allow multiple security sessions to use flow rule 2020-01-20 12:12:20 +01:00
librte_eventdev eventdev: use custom element size rings 2020-01-19 19:32:50 +01:00
librte_fib remove blank lines at end of file 2019-11-26 00:12:08 +01:00
librte_flow_classify build: remove individual library versions 2019-11-20 23:05:39 +01:00
librte_gro build: align symbols with global ABI version 2019-11-20 23:05:39 +01:00
librte_gso build: align symbols with global ABI version 2019-11-20 23:05:39 +01:00
librte_hash hash: add max key id query API 2020-01-20 01:14:57 +01:00
librte_ip_frag build: align symbols with global ABI version 2019-11-20 23:05:39 +01:00
librte_ipsec build: remove individual library versions 2019-11-20 23:05:39 +01:00
librte_jobstats build: align symbols with global ABI version 2019-11-20 23:05:39 +01:00
librte_kni kni: fix build with Linux 4.9.x 2019-11-28 14:48:24 +01:00
librte_kvargs build: align symbols with global ABI version 2019-11-20 23:05:39 +01:00
librte_latencystats latency: fix calculation for multi-thread 2020-01-20 01:32:50 +01:00
librte_lpm build: align symbols with global ABI version 2019-11-20 23:05:39 +01:00
librte_mbuf mbuf: create pool with external memory buffers 2020-01-20 23:36:38 +01:00
librte_member build: align symbols with global ABI version 2019-11-20 23:05:39 +01:00
librte_mempool mempool: remove memory wastage on non-x86 2020-01-20 16:37:27 +01:00
librte_meter meter: remove experimental flag from RFC4115 trTCM API 2020-01-20 16:37:27 +01:00
librte_metrics build: align symbols with global ABI version 2019-11-20 23:05:39 +01:00
librte_net build: align symbols with global ABI version 2019-11-20 23:05:39 +01:00
librte_pci build: align symbols with global ABI version 2019-11-20 23:05:39 +01:00
librte_pdump build: align symbols with global ABI version 2019-11-20 23:05:39 +01:00
librte_pipeline build: align symbols with global ABI version 2019-11-20 23:05:39 +01:00
librte_port port: replace license text with SPDX tag 2019-11-28 03:02:51 +01:00
librte_power power: fix error log on guest message polling 2019-11-26 00:29:24 +01:00
librte_rawdev build: align symbols with global ABI version 2019-11-20 23:05:39 +01:00
librte_rcu build: remove individual library versions 2019-11-20 23:05:39 +01:00
librte_reorder build: align symbols with global ABI version 2019-11-20 23:05:39 +01:00
librte_rib build: remove individual library versions 2019-11-20 23:05:39 +01:00
librte_ring ring: support configurable element size 2020-01-19 19:32:48 +01:00
librte_sched build: align symbols with global ABI version 2019-11-20 23:05:39 +01:00
librte_security build: align symbols with global ABI version 2019-11-20 23:05:39 +01:00
librte_stack build: remove individual library versions 2019-11-20 23:05:39 +01:00
librte_table build: align symbols with global ABI version 2019-11-20 23:05:39 +01:00
librte_telemetry build: remove individual library versions 2019-11-20 23:05:39 +01:00
librte_timer timer: add API to query ticks until the next timer 2020-01-20 01:55:19 +01:00
librte_vhost vhost: fix deadlock on port deletion 2020-01-17 19:46:26 +01:00
Makefile vhost: fix build dependency on hash lib 2019-11-08 23:15:05 +01:00
meson.build build: fix soname info for 19.11 compatibility 2019-12-19 16:18:21 +01:00