lib: clean up build files

Switch from using tabs to 4 spaces for meson.build indentation. Perform
other formatting cleanups such as ensure that long lists of files are one
per line, and terminating with a final comma before the closing brace to
make addition/removals easier. In some cases, reorder lists of items
where they were not in alphabetical order.

Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
This commit is contained in:
Bruce Richardson 2021-04-20 11:22:24 +01:00 committed by Thomas Monjalon
parent 9cc02b1794
commit 6fc406593a
44 changed files with 808 additions and 705 deletions

View File

@ -2,82 +2,82 @@
# Copyright(c) 2017 Intel Corporation
sources = files('acl_bld.c', 'acl_gen.c', 'acl_run_scalar.c',
'rte_acl.c', 'tb_mem.c')
'rte_acl.c', 'tb_mem.c')
headers = files('rte_acl.h', 'rte_acl_osdep.h')
if dpdk_conf.has('RTE_ARCH_X86')
sources += files('acl_run_sse.c')
sources += files('acl_run_sse.c')
# compile AVX2 version if either:
# a. we have AVX supported in minimum instruction set baseline
# b. it's not minimum instruction set, but supported by compiler
#
# in former case, just add avx2 C file to files list
# in latter case, compile c file to static lib, using correct compiler
# flags, and then have the .o file from static lib linked into main lib.
if cc.get_define('__AVX2__', args: machine_args) != ''
sources += files('acl_run_avx2.c')
cflags += '-DCC_AVX2_SUPPORT'
elif cc.has_argument('-mavx2')
avx2_tmplib = static_library('avx2_tmp',
'acl_run_avx2.c',
dependencies: static_rte_eal,
c_args: cflags + ['-mavx2'])
objs += avx2_tmplib.extract_objects('acl_run_avx2.c')
cflags += '-DCC_AVX2_SUPPORT'
endif
# compile AVX2 version if either:
# a. we have AVX supported in minimum instruction set baseline
# b. it's not minimum instruction set, but supported by compiler
#
# in former case, just add avx2 C file to files list
# in latter case, compile c file to static lib, using correct compiler
# flags, and then have the .o file from static lib linked into main lib.
if cc.get_define('__AVX2__', args: machine_args) != ''
sources += files('acl_run_avx2.c')
cflags += '-DCC_AVX2_SUPPORT'
elif cc.has_argument('-mavx2')
avx2_tmplib = static_library('avx2_tmp',
'acl_run_avx2.c',
dependencies: static_rte_eal,
c_args: cflags + ['-mavx2'])
objs += avx2_tmplib.extract_objects('acl_run_avx2.c')
cflags += '-DCC_AVX2_SUPPORT'
endif
# compile AVX512 version if:
# we are building 64-bit binary AND binutils can generate proper code
# compile AVX512 version if:
# we are building 64-bit binary AND binutils can generate proper code
if dpdk_conf.has('RTE_ARCH_X86_64') and binutils_ok.returncode() == 0
if dpdk_conf.has('RTE_ARCH_X86_64') and binutils_ok.returncode() == 0
# compile AVX512 version if either:
# a. we have AVX512 supported in minimum instruction set
# baseline
# b. it's not minimum instruction set, but supported by
# compiler
#
# in former case, just add avx512 C file to files list
# in latter case, compile c file to static lib, using correct
# compiler flags, and then have the .o file from static lib
# linked into main lib.
# compile AVX512 version if either:
# a. we have AVX512 supported in minimum instruction set
# baseline
# b. it's not minimum instruction set, but supported by
# compiler
#
# in former case, just add avx512 C file to files list
# in latter case, compile c file to static lib, using correct
# compiler flags, and then have the .o file from static lib
# linked into main lib.
# check if all required flags already enabled (variant a).
acl_avx512_flags = ['__AVX512F__', '__AVX512VL__',
'__AVX512CD__', '__AVX512BW__']
# check if all required flags already enabled (variant a).
acl_avx512_flags = ['__AVX512F__', '__AVX512VL__',
'__AVX512CD__', '__AVX512BW__']
acl_avx512_on = true
foreach f:acl_avx512_flags
acl_avx512_on = true
foreach f:acl_avx512_flags
if cc.get_define(f, args: machine_args) == ''
acl_avx512_on = false
endif
endforeach
if cc.get_define(f, args: machine_args) == ''
acl_avx512_on = false
endif
endforeach
if acl_avx512_on == true
if acl_avx512_on == true
sources += files('acl_run_avx512.c')
cflags += '-DCC_AVX512_SUPPORT'
sources += files('acl_run_avx512.c')
cflags += '-DCC_AVX512_SUPPORT'
elif cc.has_multi_arguments('-mavx512f', '-mavx512vl',
'-mavx512cd', '-mavx512bw')
elif cc.has_multi_arguments('-mavx512f', '-mavx512vl',
'-mavx512cd', '-mavx512bw')
avx512_tmplib = static_library('avx512_tmp',
'acl_run_avx512.c',
dependencies: static_rte_eal,
c_args: cflags +
['-mavx512f', '-mavx512vl',
'-mavx512cd', '-mavx512bw'])
objs += avx512_tmplib.extract_objects(
'acl_run_avx512.c')
cflags += '-DCC_AVX512_SUPPORT'
endif
endif
avx512_tmplib = static_library('avx512_tmp',
'acl_run_avx512.c',
dependencies: static_rte_eal,
c_args: cflags +
['-mavx512f', '-mavx512vl',
'-mavx512cd', '-mavx512bw'])
objs += avx512_tmplib.extract_objects(
'acl_run_avx512.c')
cflags += '-DCC_AVX512_SUPPORT'
endif
endif
elif dpdk_conf.has('RTE_ARCH_ARM')
cflags += '-flax-vector-conversions'
sources += files('acl_run_neon.c')
cflags += '-flax-vector-conversions'
sources += files('acl_run_neon.c')
elif dpdk_conf.has('RTE_ARCH_PPC_64')
sources += files('acl_run_altivec.c')
sources += files('acl_run_altivec.c')
endif

View File

@ -3,6 +3,6 @@
sources = files('rte_bbdev.c')
headers = files('rte_bbdev.h',
'rte_bbdev_pmd.h',
'rte_bbdev_op.h')
'rte_bbdev_pmd.h',
'rte_bbdev_op.h')
deps += ['mbuf']

View File

@ -2,26 +2,26 @@
# Copyright(c) 2018 Intel Corporation
sources = files('bpf.c',
'bpf_exec.c',
'bpf_load.c',
'bpf_pkt.c',
'bpf_validate.c')
'bpf_exec.c',
'bpf_load.c',
'bpf_pkt.c',
'bpf_validate.c')
if arch_subdir == 'x86' and dpdk_conf.get('RTE_ARCH_64')
sources += files('bpf_jit_x86.c')
sources += files('bpf_jit_x86.c')
elif dpdk_conf.has('RTE_ARCH_ARM64')
sources += files('bpf_jit_arm64.c')
sources += files('bpf_jit_arm64.c')
endif
headers = files('bpf_def.h',
'rte_bpf.h',
'rte_bpf_ethdev.h')
'rte_bpf.h',
'rte_bpf_ethdev.h')
deps += ['mbuf', 'net', 'ethdev']
dep = dependency('libelf', required: false, method: 'pkg-config')
if dep.found()
dpdk_conf.set('RTE_LIBRTE_BPF_ELF', 1)
sources += files('bpf_load_elf.c')
ext_deps += dep
dpdk_conf.set('RTE_LIBRTE_BPF_ELF', 1)
sources += files('bpf_load_elf.c')
ext_deps += dep
endif

View File

@ -2,33 +2,33 @@
# Copyright(c) 2017 Intel Corporation
sources = files('cmdline.c',
'cmdline_cirbuf.c',
'cmdline_parse.c',
'cmdline_parse_etheraddr.c',
'cmdline_parse_ipaddr.c',
'cmdline_parse_num.c',
'cmdline_parse_portlist.c',
'cmdline_parse_string.c',
'cmdline_rdline.c',
'cmdline_socket.c',
'cmdline_vt100.c')
'cmdline_cirbuf.c',
'cmdline_parse.c',
'cmdline_parse_etheraddr.c',
'cmdline_parse_ipaddr.c',
'cmdline_parse_num.c',
'cmdline_parse_portlist.c',
'cmdline_parse_string.c',
'cmdline_rdline.c',
'cmdline_socket.c',
'cmdline_vt100.c')
headers = files('cmdline.h',
'cmdline_parse.h',
'cmdline_parse_num.h',
'cmdline_parse_ipaddr.h',
'cmdline_parse_etheraddr.h',
'cmdline_parse_string.h',
'cmdline_rdline.h',
'cmdline_vt100.h',
'cmdline_socket.h',
'cmdline_cirbuf.h',
'cmdline_parse_portlist.h')
'cmdline_parse.h',
'cmdline_parse_num.h',
'cmdline_parse_ipaddr.h',
'cmdline_parse_etheraddr.h',
'cmdline_parse_string.h',
'cmdline_rdline.h',
'cmdline_vt100.h',
'cmdline_socket.h',
'cmdline_cirbuf.h',
'cmdline_parse_portlist.h')
if is_windows
sources += files('cmdline_os_windows.c')
sources += files('cmdline_os_windows.c')
else
sources += files('cmdline_os_unix.c')
sources += files('cmdline_os_unix.c')
endif
deps += ['net']

View File

@ -2,10 +2,10 @@
# Copyright(c) 2018 Intel Corporation
sources = files('rte_compressdev.c',
'rte_compressdev_pmd.c',
'rte_comp.c')
'rte_compressdev_pmd.c',
'rte_comp.c')
headers = files('rte_compressdev.h',
'rte_compressdev_pmd.h',
'rte_compressdev_internal.h',
'rte_comp.h')
'rte_compressdev_pmd.h',
'rte_compressdev_internal.h',
'rte_comp.h')
deps += ['kvargs', 'mbuf']

View File

@ -3,10 +3,10 @@
sources = files('rte_cryptodev.c', 'rte_cryptodev_pmd.c', 'cryptodev_trace_points.c')
headers = files('rte_cryptodev.h',
'rte_cryptodev_pmd.h',
'rte_cryptodev_trace.h',
'rte_cryptodev_trace_fp.h',
'rte_crypto.h',
'rte_crypto_sym.h',
'rte_crypto_asym.h')
'rte_cryptodev_pmd.h',
'rte_cryptodev_trace.h',
'rte_cryptodev_trace_fp.h',
'rte_crypto.h',
'rte_crypto_sym.h',
'rte_crypto_asym.h')
deps += ['kvargs', 'mbuf', 'rcu']

View File

@ -3,9 +3,9 @@
sources = files('rte_distributor.c', 'rte_distributor_single.c')
if arch_subdir == 'x86'
sources += files('rte_distributor_match_sse.c')
sources += files('rte_distributor_match_sse.c')
else
sources += files('rte_distributor_match_generic.c')
sources += files('rte_distributor_match_generic.c')
endif
headers = files('rte_distributor.h')
deps += ['mbuf']

View File

@ -2,33 +2,33 @@
# Copyright(c) 2017 Intel Corporation.
arch_headers = files(
'rte_atomic_32.h',
'rte_atomic_64.h',
'rte_atomic.h',
'rte_byteorder.h',
'rte_cpuflags_32.h',
'rte_cpuflags_64.h',
'rte_cpuflags.h',
'rte_cycles_32.h',
'rte_cycles_64.h',
'rte_cycles.h',
'rte_io_64.h',
'rte_io.h',
'rte_mcslock.h',
'rte_memcpy_32.h',
'rte_memcpy_64.h',
'rte_memcpy.h',
'rte_pause_32.h',
'rte_pause_64.h',
'rte_pause.h',
'rte_pflock.h',
'rte_power_intrinsics.h',
'rte_prefetch_32.h',
'rte_prefetch_64.h',
'rte_prefetch.h',
'rte_rwlock.h',
'rte_spinlock.h',
'rte_ticketlock.h',
'rte_vect.h',
'rte_atomic_32.h',
'rte_atomic_64.h',
'rte_atomic.h',
'rte_byteorder.h',
'rte_cpuflags_32.h',
'rte_cpuflags_64.h',
'rte_cpuflags.h',
'rte_cycles_32.h',
'rte_cycles_64.h',
'rte_cycles.h',
'rte_io_64.h',
'rte_io.h',
'rte_mcslock.h',
'rte_memcpy_32.h',
'rte_memcpy_64.h',
'rte_memcpy.h',
'rte_pause_32.h',
'rte_pause_64.h',
'rte_pause.h',
'rte_pflock.h',
'rte_power_intrinsics.h',
'rte_prefetch_32.h',
'rte_prefetch_64.h',
'rte_prefetch.h',
'rte_rwlock.h',
'rte_spinlock.h',
'rte_ticketlock.h',
'rte_vect.h',
)
install_headers(arch_headers, subdir: get_option('include_subdir_arch'))

View File

@ -4,8 +4,8 @@
subdir('include')
sources += files(
'rte_cpuflags.c',
'rte_cycles.c',
'rte_hypervisor.c',
'rte_power_intrinsics.c',
'rte_cpuflags.c',
'rte_cycles.c',
'rte_hypervisor.c',
'rte_power_intrinsics.c',
)

View File

@ -6,83 +6,83 @@ includes += include_directories('.')
cflags += [ '-DABI_VERSION="@0@"'.format(abi_version) ]
if is_windows
sources += files(
'eal_common_bus.c',
'eal_common_class.c',
'eal_common_config.c',
'eal_common_debug.c',
'eal_common_dev.c',
'eal_common_devargs.c',
'eal_common_dynmem.c',
'eal_common_errno.c',
'eal_common_fbarray.c',
'eal_common_hexdump.c',
'eal_common_launch.c',
'eal_common_lcore.c',
'eal_common_log.c',
'eal_common_mcfg.c',
'eal_common_memalloc.c',
'eal_common_memory.c',
'eal_common_memzone.c',
'eal_common_options.c',
'eal_common_string_fns.c',
'eal_common_tailqs.c',
'eal_common_thread.c',
'eal_common_trace_points.c',
'malloc_elem.c',
'malloc_heap.c',
'rte_malloc.c',
'eal_common_timer.c',
'rte_random.c',
'rte_reciprocal.c',
'rte_service.c',
'rte_version.c',
)
subdir_done()
sources += files(
'eal_common_bus.c',
'eal_common_class.c',
'eal_common_config.c',
'eal_common_debug.c',
'eal_common_dev.c',
'eal_common_devargs.c',
'eal_common_dynmem.c',
'eal_common_errno.c',
'eal_common_fbarray.c',
'eal_common_hexdump.c',
'eal_common_launch.c',
'eal_common_lcore.c',
'eal_common_log.c',
'eal_common_mcfg.c',
'eal_common_memalloc.c',
'eal_common_memory.c',
'eal_common_memzone.c',
'eal_common_options.c',
'eal_common_string_fns.c',
'eal_common_tailqs.c',
'eal_common_thread.c',
'eal_common_trace_points.c',
'malloc_elem.c',
'malloc_heap.c',
'rte_malloc.c',
'eal_common_timer.c',
'rte_random.c',
'rte_reciprocal.c',
'rte_service.c',
'rte_version.c',
)
subdir_done()
endif
sources += files(
'eal_common_bus.c',
'eal_common_cpuflags.c',
'eal_common_class.c',
'eal_common_config.c',
'eal_common_debug.c',
'eal_common_devargs.c',
'eal_common_dev.c',
'eal_common_errno.c',
'eal_common_fbarray.c',
'eal_common_hexdump.c',
'eal_common_hypervisor.c',
'eal_common_launch.c',
'eal_common_lcore.c',
'eal_common_log.c',
'eal_common_mcfg.c',
'eal_common_memalloc.c',
'eal_common_memory.c',
'eal_common_memzone.c',
'eal_common_options.c',
'eal_common_proc.c',
'eal_common_string_fns.c',
'eal_common_tailqs.c',
'eal_common_thread.c',
'eal_common_timer.c',
'eal_common_trace.c',
'eal_common_trace_ctf.c',
'eal_common_trace_points.c',
'eal_common_trace_utils.c',
'eal_common_uuid.c',
'hotplug_mp.c',
'malloc_elem.c',
'malloc_heap.c',
'malloc_mp.c',
'rte_keepalive.c',
'rte_malloc.c',
'rte_random.c',
'rte_reciprocal.c',
'rte_service.c',
'rte_version.c',
'eal_common_bus.c',
'eal_common_cpuflags.c',
'eal_common_class.c',
'eal_common_config.c',
'eal_common_debug.c',
'eal_common_devargs.c',
'eal_common_dev.c',
'eal_common_errno.c',
'eal_common_fbarray.c',
'eal_common_hexdump.c',
'eal_common_hypervisor.c',
'eal_common_launch.c',
'eal_common_lcore.c',
'eal_common_log.c',
'eal_common_mcfg.c',
'eal_common_memalloc.c',
'eal_common_memory.c',
'eal_common_memzone.c',
'eal_common_options.c',
'eal_common_proc.c',
'eal_common_string_fns.c',
'eal_common_tailqs.c',
'eal_common_thread.c',
'eal_common_timer.c',
'eal_common_trace.c',
'eal_common_trace_ctf.c',
'eal_common_trace_points.c',
'eal_common_trace_utils.c',
'eal_common_uuid.c',
'hotplug_mp.c',
'malloc_elem.c',
'malloc_heap.c',
'malloc_mp.c',
'rte_keepalive.c',
'rte_malloc.c',
'rte_random.c',
'rte_reciprocal.c',
'rte_service.c',
'rte_version.c',
)
if is_linux
sources += files('eal_common_dynmem.c')
sources += files('eal_common_dynmem.c')
endif

View File

@ -4,18 +4,18 @@
subdir('include')
sources += files(
'eal.c',
'eal_alarm.c',
'eal_cpuflags.c',
'eal_debug.c',
'eal_dev.c',
'eal_hugepage_info.c',
'eal_interrupts.c',
'eal_lcore.c',
'eal_memalloc.c',
'eal_memory.c',
'eal_thread.c',
'eal_timer.c',
'eal.c',
'eal_alarm.c',
'eal_cpuflags.c',
'eal_debug.c',
'eal_dev.c',
'eal_hugepage_info.c',
'eal_interrupts.c',
'eal_lcore.c',
'eal_memalloc.c',
'eal_memory.c',
'eal_thread.c',
'eal_timer.c',
)
deps += ['kvargs', 'telemetry']

View File

@ -4,67 +4,67 @@
includes += include_directories('.')
headers += files(
'rte_alarm.h',
'rte_bitmap.h',
'rte_bitops.h',
'rte_branch_prediction.h',
'rte_bus.h',
'rte_class.h',
'rte_common.h',
'rte_compat.h',
'rte_debug.h',
'rte_dev.h',
'rte_devargs.h',
'rte_eal.h',
'rte_eal_memconfig.h',
'rte_eal_trace.h',
'rte_errno.h',
'rte_fbarray.h',
'rte_hexdump.h',
'rte_hypervisor.h',
'rte_interrupts.h',
'rte_keepalive.h',
'rte_launch.h',
'rte_lcore.h',
'rte_log.h',
'rte_malloc.h',
'rte_memory.h',
'rte_memzone.h',
'rte_pci_dev_feature_defs.h',
'rte_pci_dev_features.h',
'rte_per_lcore.h',
'rte_random.h',
'rte_reciprocal.h',
'rte_service.h',
'rte_service_component.h',
'rte_string_fns.h',
'rte_tailq.h',
'rte_thread.h',
'rte_time.h',
'rte_trace.h',
'rte_trace_point.h',
'rte_trace_point_register.h',
'rte_uuid.h',
'rte_version.h',
'rte_vfio.h',
'rte_alarm.h',
'rte_bitmap.h',
'rte_bitops.h',
'rte_branch_prediction.h',
'rte_bus.h',
'rte_class.h',
'rte_common.h',
'rte_compat.h',
'rte_debug.h',
'rte_dev.h',
'rte_devargs.h',
'rte_eal.h',
'rte_eal_memconfig.h',
'rte_eal_trace.h',
'rte_errno.h',
'rte_fbarray.h',
'rte_hexdump.h',
'rte_hypervisor.h',
'rte_interrupts.h',
'rte_keepalive.h',
'rte_launch.h',
'rte_lcore.h',
'rte_log.h',
'rte_malloc.h',
'rte_memory.h',
'rte_memzone.h',
'rte_pci_dev_feature_defs.h',
'rte_pci_dev_features.h',
'rte_per_lcore.h',
'rte_random.h',
'rte_reciprocal.h',
'rte_service.h',
'rte_service_component.h',
'rte_string_fns.h',
'rte_tailq.h',
'rte_thread.h',
'rte_time.h',
'rte_trace.h',
'rte_trace_point.h',
'rte_trace_point_register.h',
'rte_uuid.h',
'rte_version.h',
'rte_vfio.h',
)
indirect_headers += files('rte_eal_interrupts.h')
# special case install the generic headers, since they go in a subdir
generic_headers = files(
'generic/rte_atomic.h',
'generic/rte_byteorder.h',
'generic/rte_cpuflags.h',
'generic/rte_cycles.h',
'generic/rte_io.h',
'generic/rte_mcslock.h',
'generic/rte_memcpy.h',
'generic/rte_pause.h',
'generic/rte_power_intrinsics.h',
'generic/rte_prefetch.h',
'generic/rte_rwlock.h',
'generic/rte_spinlock.h',
'generic/rte_ticketlock.h',
'generic/rte_vect.h',
'generic/rte_atomic.h',
'generic/rte_byteorder.h',
'generic/rte_cpuflags.h',
'generic/rte_cycles.h',
'generic/rte_io.h',
'generic/rte_mcslock.h',
'generic/rte_memcpy.h',
'generic/rte_pause.h',
'generic/rte_power_intrinsics.h',
'generic/rte_prefetch.h',
'generic/rte_rwlock.h',
'generic/rte_spinlock.h',
'generic/rte_ticketlock.h',
'generic/rte_vect.h',
)
install_headers(generic_headers, subdir: 'generic')

View File

@ -4,24 +4,24 @@
subdir('include')
sources += files(
'eal.c',
'eal_alarm.c',
'eal_cpuflags.c',
'eal_debug.c',
'eal_dev.c',
'eal_hugepage_info.c',
'eal_interrupts.c',
'eal_lcore.c',
'eal_log.c',
'eal_memalloc.c',
'eal_memory.c',
'eal_thread.c',
'eal_timer.c',
'eal_vfio.c',
'eal_vfio_mp_sync.c',
'eal.c',
'eal_alarm.c',
'eal_cpuflags.c',
'eal_debug.c',
'eal_dev.c',
'eal_hugepage_info.c',
'eal_interrupts.c',
'eal_lcore.c',
'eal_log.c',
'eal_memalloc.c',
'eal_memory.c',
'eal_thread.c',
'eal_timer.c',
'eal_vfio.c',
'eal_vfio_mp_sync.c',
)
deps += ['kvargs', 'telemetry']
if has_libnuma == 1
dpdk_conf.set10('RTE_EAL_NUMA_AWARE_HUGEPAGES', true)
dpdk_conf.set10('RTE_EAL_NUMA_AWARE_HUGEPAGES', true)
endif

View File

@ -7,7 +7,7 @@ subdir('include')
subdir('common')
if not is_windows
subdir('unix')
subdir('unix')
endif
dpdk_conf.set('RTE_EXEC_ENV_' + exec_env.to_upper(), 1)
@ -17,11 +17,11 @@ subdir(arch_subdir)
deps += ['kvargs']
if not is_windows
deps += ['telemetry']
deps += ['telemetry']
endif
if dpdk_conf.has('RTE_USE_LIBBSD')
ext_deps += libbsd
ext_deps += libbsd
endif
if cc.has_function('getentropy', prefix : '#include <unistd.h>')
cflags += '-DRTE_LIBEAL_USE_GETENTROPY'
cflags += '-DRTE_LIBEAL_USE_GETENTROPY'
endif

View File

@ -2,21 +2,21 @@
# Copyright(c) 2018 Luca Boccassi <bluca@debian.org>
arch_headers = files(
'rte_altivec.h',
'rte_atomic.h',
'rte_byteorder.h',
'rte_cpuflags.h',
'rte_cycles.h',
'rte_io.h',
'rte_mcslock.h',
'rte_memcpy.h',
'rte_pause.h',
'rte_pflock.h',
'rte_power_intrinsics.h',
'rte_prefetch.h',
'rte_rwlock.h',
'rte_spinlock.h',
'rte_ticketlock.h',
'rte_vect.h',
'rte_altivec.h',
'rte_atomic.h',
'rte_byteorder.h',
'rte_cpuflags.h',
'rte_cycles.h',
'rte_io.h',
'rte_mcslock.h',
'rte_memcpy.h',
'rte_pause.h',
'rte_pflock.h',
'rte_power_intrinsics.h',
'rte_prefetch.h',
'rte_rwlock.h',
'rte_spinlock.h',
'rte_ticketlock.h',
'rte_vect.h',
)
install_headers(arch_headers, subdir: get_option('include_subdir_arch'))

View File

@ -4,8 +4,8 @@
subdir('include')
sources += files(
'rte_cpuflags.c',
'rte_cycles.c',
'rte_hypervisor.c',
'rte_power_intrinsics.c',
'rte_cpuflags.c',
'rte_cycles.c',
'rte_hypervisor.c',
'rte_power_intrinsics.c',
)

View File

@ -2,8 +2,8 @@
# Copyright(c) 2020 Dmitry Kozlyuk
sources += files(
'eal_file.c',
'eal_unix_memory.c',
'eal_unix_timer.c',
'rte_thread.c',
'eal_file.c',
'eal_unix_memory.c',
'eal_unix_timer.c',
'rte_thread.c',
)

View File

@ -4,22 +4,22 @@
subdir('include')
sources += files(
'eal.c',
'eal_alarm.c',
'eal_debug.c',
'eal_file.c',
'eal_hugepages.c',
'eal_interrupts.c',
'eal_lcore.c',
'eal_log.c',
'eal_memalloc.c',
'eal_memory.c',
'eal_mp.c',
'eal_thread.c',
'eal_timer.c',
'fnmatch.c',
'getopt.c',
'rte_thread.c',
'eal.c',
'eal_alarm.c',
'eal_debug.c',
'eal_file.c',
'eal_hugepages.c',
'eal_interrupts.c',
'eal_lcore.c',
'eal_log.c',
'eal_memalloc.c',
'eal_memory.c',
'eal_mp.c',
'eal_thread.c',
'eal_timer.c',
'fnmatch.c',
'getopt.c',
'rte_thread.c',
)
dpdk_conf.set10('RTE_EAL_NUMA_AWARE_HUGEPAGES', true)

View File

@ -2,29 +2,28 @@
# Copyright(c) 2017 Intel Corporation
arch_headers = files(
'rte_atomic.h',
'rte_byteorder.h',
'rte_cpuflags.h',
'rte_cycles.h',
'rte_io.h',
'rte_mcslock.h',
'rte_memcpy.h',
'rte_pause.h',
'rte_pflock.h',
'rte_power_intrinsics.h',
'rte_prefetch.h',
'rte_rtm.h',
'rte_rwlock.h',
'rte_spinlock.h',
'rte_ticketlock.h',
'rte_vect.h',
'rte_atomic.h',
'rte_byteorder.h',
'rte_cpuflags.h',
'rte_cycles.h',
'rte_io.h',
'rte_mcslock.h',
'rte_memcpy.h',
'rte_pause.h',
'rte_pflock.h',
'rte_power_intrinsics.h',
'rte_prefetch.h',
'rte_rtm.h',
'rte_rwlock.h',
'rte_spinlock.h',
'rte_ticketlock.h',
'rte_vect.h',
)
arch_indirect_headers = files(
'rte_atomic_32.h',
'rte_atomic_64.h',
'rte_byteorder_32.h',
'rte_byteorder_64.h',
'rte_atomic_32.h',
'rte_atomic_64.h',
'rte_byteorder_32.h',
'rte_byteorder_64.h',
)
install_headers(arch_headers + arch_indirect_headers,
subdir: get_option('include_subdir_arch'))
install_headers(arch_headers + arch_indirect_headers, subdir: get_option('include_subdir_arch'))
dpdk_chkinc_headers += arch_headers

View File

@ -4,9 +4,9 @@
subdir('include')
sources += files(
'rte_cpuflags.c',
'rte_cycles.c',
'rte_hypervisor.c',
'rte_spinlock.c',
'rte_power_intrinsics.c',
'rte_cpuflags.c',
'rte_cycles.c',
'rte_hypervisor.c',
'rte_spinlock.c',
'rte_power_intrinsics.c',
)

View File

@ -1,33 +1,39 @@
# SPDX-License-Identifier: BSD-3-Clause
# Copyright(c) 2017 Intel Corporation
sources = files('ethdev_private.c',
'ethdev_profile.c',
'ethdev_trace_points.c',
'rte_class_eth.c',
'rte_ethdev.c',
'rte_flow.c',
'rte_mtr.c',
'rte_tm.c')
sources = files(
'ethdev_private.c',
'ethdev_profile.c',
'ethdev_trace_points.c',
'rte_class_eth.c',
'rte_ethdev.c',
'rte_flow.c',
'rte_mtr.c',
'rte_tm.c',
)
headers = files('rte_ethdev.h',
'rte_ethdev_trace.h',
'rte_ethdev_trace_fp.h',
'rte_dev_info.h',
'rte_flow.h',
'rte_flow_driver.h',
'rte_mtr.h',
'rte_mtr_driver.h',
'rte_tm.h',
'rte_tm_driver.h')
headers = files(
'rte_ethdev.h',
'rte_ethdev_trace.h',
'rte_ethdev_trace_fp.h',
'rte_dev_info.h',
'rte_flow.h',
'rte_flow_driver.h',
'rte_mtr.h',
'rte_mtr_driver.h',
'rte_tm.h',
'rte_tm_driver.h',
)
indirect_headers += files(
'rte_ethdev_core.h',
'rte_eth_ctrl.h')
'rte_ethdev_core.h',
'rte_eth_ctrl.h',
)
driver_sdk_headers += files(
'ethdev_driver.h',
'ethdev_pci.h',
'ethdev_vdev.h')
'ethdev_driver.h',
'ethdev_pci.h',
'ethdev_vdev.h',
)
deps += ['net', 'kvargs', 'meter', 'telemetry']

View File

@ -2,26 +2,30 @@
# Copyright(c) 2017 Intel Corporation
if is_linux
cflags += '-DLINUX'
cflags += '-DLINUX'
else
cflags += '-DBSD'
cflags += '-DBSD'
endif
sources = files('rte_eventdev.c',
'rte_event_ring.c',
'eventdev_trace_points.c',
'rte_event_eth_rx_adapter.c',
'rte_event_timer_adapter.c',
'rte_event_crypto_adapter.c',
'rte_event_eth_tx_adapter.c')
headers = files('rte_eventdev.h',
'rte_eventdev_trace.h',
'rte_eventdev_trace_fp.h',
'rte_event_ring.h',
'rte_event_eth_rx_adapter.h',
'rte_event_timer_adapter.h',
'rte_event_timer_adapter_pmd.h',
'rte_event_crypto_adapter.h',
'rte_event_eth_tx_adapter.h')
sources = files(
'rte_eventdev.c',
'rte_event_ring.c',
'eventdev_trace_points.c',
'rte_event_eth_rx_adapter.c',
'rte_event_timer_adapter.c',
'rte_event_crypto_adapter.c',
'rte_event_eth_tx_adapter.c',
)
headers = files(
'rte_eventdev.h',
'rte_eventdev_trace.h',
'rte_eventdev_trace_fp.h',
'rte_event_ring.h',
'rte_event_eth_rx_adapter.h',
'rte_event_timer_adapter.h',
'rte_event_timer_adapter_pmd.h',
'rte_event_crypto_adapter.h',
'rte_event_eth_tx_adapter.h',
)
deps += ['ring', 'ethdev', 'hash', 'mempool', 'mbuf', 'timer', 'cryptodev']
deps += ['telemetry']

View File

@ -9,50 +9,50 @@ deps += ['rib']
# compile AVX512 version if:
# we are building 64-bit binary AND binutils can generate proper code
if dpdk_conf.has('RTE_ARCH_X86_64') and binutils_ok.returncode() == 0
# compile AVX512 version if either:
# a. we have AVX512F supported in minimum instruction set baseline
# b. it's not minimum instruction set, but supported by compiler
#
# in former case, just add avx512 C file to files list
# in latter case, compile c file to static lib, using correct
# compiler flags, and then have the .o file from static lib
# linked into main lib.
# compile AVX512 version if either:
# a. we have AVX512F supported in minimum instruction set baseline
# b. it's not minimum instruction set, but supported by compiler
#
# in former case, just add avx512 C file to files list
# in latter case, compile c file to static lib, using correct
# compiler flags, and then have the .o file from static lib
# linked into main lib.
# check if all required flags already enabled (variant a).
acl_avx512_flags = ['__AVX512F__','__AVX512DQ__']
acl_avx512_on = true
foreach f:acl_avx512_flags
if cc.get_define(f, args: machine_args) == ''
acl_avx512_on = false
endif
endforeach
# check if all required flags already enabled (variant a).
acl_avx512_flags = ['__AVX512F__','__AVX512DQ__']
acl_avx512_on = true
foreach f:acl_avx512_flags
if cc.get_define(f, args: machine_args) == ''
acl_avx512_on = false
endif
endforeach
if acl_avx512_on == true
cflags += ['-DCC_DIR24_8_AVX512_SUPPORT']
sources += files('dir24_8_avx512.c')
# TRIE AVX512 implementation uses avx512bw intrinsics along with
# avx512f and avx512dq
if cc.get_define('__AVX512BW__', args: machine_args) != ''
cflags += ['-DCC_TRIE_AVX512_SUPPORT']
sources += files('trie_avx512.c')
endif
elif cc.has_multi_arguments('-mavx512f', '-mavx512dq')
dir24_8_avx512_tmp = static_library('dir24_8_avx512_tmp',
'dir24_8_avx512.c',
dependencies: static_rte_eal,
c_args: cflags + ['-mavx512f', '-mavx512dq'])
objs += dir24_8_avx512_tmp.extract_objects('dir24_8_avx512.c')
cflags += ['-DCC_DIR24_8_AVX512_SUPPORT']
# TRIE AVX512 implementation uses avx512bw intrinsics along with
# avx512f and avx512dq
if cc.has_argument('-mavx512bw')
trie_avx512_tmp = static_library('trie_avx512_tmp',
'trie_avx512.c',
dependencies: static_rte_eal,
c_args: cflags + ['-mavx512f', \
'-mavx512dq', '-mavx512bw'])
objs += trie_avx512_tmp.extract_objects('trie_avx512.c')
cflags += ['-DCC_TRIE_AVX512_SUPPORT']
endif
endif
if acl_avx512_on == true
cflags += ['-DCC_DIR24_8_AVX512_SUPPORT']
sources += files('dir24_8_avx512.c')
# TRIE AVX512 implementation uses avx512bw intrinsics along with
# avx512f and avx512dq
if cc.get_define('__AVX512BW__', args: machine_args) != ''
cflags += ['-DCC_TRIE_AVX512_SUPPORT']
sources += files('trie_avx512.c')
endif
elif cc.has_multi_arguments('-mavx512f', '-mavx512dq')
dir24_8_avx512_tmp = static_library('dir24_8_avx512_tmp',
'dir24_8_avx512.c',
dependencies: static_rte_eal,
c_args: cflags + ['-mavx512f', '-mavx512dq'])
objs += dir24_8_avx512_tmp.extract_objects('dir24_8_avx512.c')
cflags += ['-DCC_DIR24_8_AVX512_SUPPORT']
# TRIE AVX512 implementation uses avx512bw intrinsics along with
# avx512f and avx512dq
if cc.has_argument('-mavx512bw')
trie_avx512_tmp = static_library('trie_avx512_tmp',
'trie_avx512.c',
dependencies: static_rte_eal,
c_args: cflags + ['-mavx512f', \
'-mavx512dq', '-mavx512bw'])
objs += trie_avx512_tmp.extract_objects('trie_avx512.c')
cflags += ['-DCC_TRIE_AVX512_SUPPORT']
endif
endif
endif

View File

@ -1,7 +1,14 @@
# SPDX-License-Identifier: BSD-3-Clause
# Copyright(C) 2020 Marvell International Ltd.
sources = files('node.c', 'graph.c', 'graph_ops.c', 'graph_debug.c', 'graph_stats.c', 'graph_populate.c')
sources = files(
'node.c',
'graph.c',
'graph_ops.c',
'graph_debug.c',
'graph_stats.c',
'graph_populate.c',
)
headers = files('rte_graph.h', 'rte_graph_worker.h')
deps += ['eal']

View File

@ -1,6 +1,12 @@
# SPDX-License-Identifier: BSD-3-Clause
# Copyright(c) 2017 Intel Corporation
sources = files('rte_gro.c', 'gro_tcp4.c', 'gro_udp4.c', 'gro_vxlan_tcp4.c', 'gro_vxlan_udp4.c')
sources = files(
'rte_gro.c',
'gro_tcp4.c',
'gro_udp4.c',
'gro_vxlan_tcp4.c',
'gro_vxlan_udp4.c',
)
headers = files('rte_gro.h')
deps += ['ethdev']

View File

@ -1,7 +1,13 @@
# SPDX-License-Identifier: BSD-3-Clause
# Copyright(c) 2017 Intel Corporation
sources = files('gso_common.c', 'gso_tcp4.c', 'gso_udp4.c',
'gso_tunnel_tcp4.c', 'gso_tunnel_udp4.c', 'rte_gso.c')
sources = files(
'gso_common.c',
'gso_tcp4.c',
'gso_udp4.c',
'gso_tunnel_tcp4.c',
'gso_tunnel_udp4.c',
'rte_gso.c',
)
headers = files('rte_gso.h')
deps += ['ethdev']

View File

@ -1,11 +1,13 @@
# SPDX-License-Identifier: BSD-3-Clause
# Copyright(c) 2017 Intel Corporation
headers = files('rte_fbk_hash.h',
'rte_hash_crc.h',
'rte_hash.h',
'rte_jhash.h',
'rte_thash.h')
headers = files(
'rte_fbk_hash.h',
'rte_hash_crc.h',
'rte_hash.h',
'rte_jhash.h',
'rte_thash.h',
)
indirect_headers += files('rte_crc_arm64.h')
sources = files('rte_cuckoo_hash.c', 'rte_fbk_hash.c', 'rte_thash.c')

View File

@ -1,11 +1,13 @@
# SPDX-License-Identifier: BSD-3-Clause
# Copyright(c) 2017 Intel Corporation
sources = files('rte_ipv4_fragmentation.c',
'rte_ipv6_fragmentation.c',
'rte_ipv4_reassembly.c',
'rte_ipv6_reassembly.c',
'rte_ip_frag_common.c',
'ip_frag_internal.c')
sources = files(
'rte_ipv4_fragmentation.c',
'rte_ipv6_fragmentation.c',
'rte_ipv4_reassembly.c',
'rte_ipv6_reassembly.c',
'rte_ip_frag_common.c',
'ip_frag_internal.c',
)
headers = files('rte_ip_frag.h')
deps += ['ethdev', 'hash']

View File

@ -2,8 +2,8 @@
# Copyright(c) 2017 Intel Corporation
if not is_linux or not dpdk_conf.get('RTE_ARCH_64')
build = false
reason = 'only supported on 64-bit Linux'
build = false
reason = 'only supported on 64-bit Linux'
endif
sources = files('rte_kni.c')
headers = files('rte_kni.h', 'rte_kni_common.h')

View File

@ -5,6 +5,11 @@ sources = files('rte_lpm.c', 'rte_lpm6.c')
headers = files('rte_lpm.h', 'rte_lpm6.h')
# since header files have different names, we can install all vector headers
# without worrying about which architecture we actually need
indirect_headers += files('rte_lpm_altivec.h', 'rte_lpm_neon.h', 'rte_lpm_sse.h', 'rte_lpm_sve.h')
indirect_headers += files(
'rte_lpm_altivec.h',
'rte_lpm_neon.h',
'rte_lpm_sse.h',
'rte_lpm_sve.h',
)
deps += ['hash']
deps += ['rcu']

View File

@ -1,9 +1,17 @@
# SPDX-License-Identifier: BSD-3-Clause
# Copyright(c) 2017 Intel Corporation
sources = files('rte_mbuf.c', 'rte_mbuf_ptype.c', 'rte_mbuf_pool_ops.c',
'rte_mbuf_dyn.c')
headers = files('rte_mbuf.h', 'rte_mbuf_core.h',
'rte_mbuf_ptype.h', 'rte_mbuf_pool_ops.h',
'rte_mbuf_dyn.h')
sources = files(
'rte_mbuf.c',
'rte_mbuf_ptype.c',
'rte_mbuf_pool_ops.c',
'rte_mbuf_dyn.c',
)
headers = files(
'rte_mbuf.h',
'rte_mbuf_core.h',
'rte_mbuf_ptype.h',
'rte_mbuf_pool_ops.h',
'rte_mbuf_dyn.h'
)
deps += ['mempool']

View File

@ -4,13 +4,20 @@
extra_flags = []
foreach flag: extra_flags
if cc.has_argument(flag)
cflags += flag
endif
if cc.has_argument(flag)
cflags += flag
endif
endforeach
sources = files('rte_mempool.c', 'rte_mempool_ops.c',
'rte_mempool_ops_default.c', 'mempool_trace_points.c')
headers = files('rte_mempool.h', 'rte_mempool_trace.h',
'rte_mempool_trace_fp.h')
sources = files(
'rte_mempool.c',
'rte_mempool_ops.c',
'rte_mempool_ops_default.c',
'mempool_trace_points.c',
)
headers = files(
'rte_mempool.h',
'rte_mempool_trace.h',
'rte_mempool_trace_fp.h',
)
deps += ['ring']

View File

@ -6,8 +6,8 @@ headers = files('rte_metrics.h', 'rte_metrics_telemetry.h')
jansson = dependency('jansson', required: false, method: 'pkg-config')
if jansson.found()
dpdk_conf.set('RTE_HAS_JANSSON', 1)
ext_deps += jansson
dpdk_conf.set('RTE_HAS_JANSSON', 1)
ext_deps += jansson
endif
deps += ['ethdev', 'telemetry']

View File

@ -1,110 +1,121 @@
# SPDX-License-Identifier: BSD-3-Clause
# Copyright(c) 2017-2020 Intel Corporation
headers = files('rte_ip.h',
'rte_tcp.h',
'rte_udp.h',
'rte_esp.h',
'rte_sctp.h',
'rte_icmp.h',
'rte_arp.h',
'rte_ether.h',
'rte_vxlan.h',
'rte_gre.h',
'rte_gtp.h',
'rte_net.h',
'rte_net_crc.h',
'rte_mpls.h',
'rte_higig.h',
'rte_ecpri.h',
'rte_geneve.h')
headers = files(
'rte_ip.h',
'rte_tcp.h',
'rte_udp.h',
'rte_esp.h',
'rte_sctp.h',
'rte_icmp.h',
'rte_arp.h',
'rte_ether.h',
'rte_vxlan.h',
'rte_gre.h',
'rte_gtp.h',
'rte_net.h',
'rte_net_crc.h',
'rte_mpls.h',
'rte_higig.h',
'rte_ecpri.h',
'rte_geneve.h',
)
sources = files('rte_arp.c', 'rte_ether.c', 'rte_net.c', 'rte_net_crc.c')
sources = files(
'rte_arp.c',
'rte_ether.c',
'rte_net.c',
'rte_net_crc.c',
)
deps += ['mbuf']
if dpdk_conf.has('RTE_ARCH_X86_64')
net_crc_sse42_cpu_support = (
cc.get_define('__PCLMUL__', args: machine_args) != '')
net_crc_avx512_cpu_support = (
cc.get_define('__AVX512F__', args: machine_args) != '' and
cc.get_define('__AVX512BW__', args: machine_args) != '' and
cc.get_define('__AVX512DQ__', args: machine_args) != '' and
cc.get_define('__AVX512VL__', args: machine_args) != '' and
cc.get_define('__VPCLMULQDQ__', args: machine_args) != '')
net_crc_sse42_cpu_support = (cc.get_define('__PCLMUL__', args: machine_args) != '')
net_crc_avx512_cpu_support = (
cc.get_define('__AVX512F__', args: machine_args) != '' and
cc.get_define('__AVX512BW__', args: machine_args) != '' and
cc.get_define('__AVX512DQ__', args: machine_args) != '' and
cc.get_define('__AVX512VL__', args: machine_args) != '' and
cc.get_define('__VPCLMULQDQ__', args: machine_args) != ''
)
net_crc_sse42_cc_support = (
cc.has_argument('-mpclmul') and cc.has_argument('-maes'))
net_crc_avx512_cc_support = (
not machine_args.contains('-mno-avx512f') and
cc.has_argument('-mavx512f') and
cc.has_argument('-mavx512bw') and
cc.has_argument('-mavx512dq') and
cc.has_argument('-mavx512vl') and
cc.has_argument('-mvpclmulqdq') and
cc.has_argument('-mavx2') and
cc.has_argument('-mavx'))
net_crc_sse42_cc_support = (cc.has_argument('-mpclmul') and cc.has_argument('-maes'))
net_crc_avx512_cc_support = (
not machine_args.contains('-mno-avx512f') and
cc.has_argument('-mavx512f') and
cc.has_argument('-mavx512bw') and
cc.has_argument('-mavx512dq') and
cc.has_argument('-mavx512vl') and
cc.has_argument('-mvpclmulqdq') and
cc.has_argument('-mavx2') and
cc.has_argument('-mavx')
)
build_static_net_crc_sse42_lib = 0
build_static_net_crc_avx512_lib = 0
build_static_net_crc_sse42_lib = 0
build_static_net_crc_avx512_lib = 0
if net_crc_sse42_cpu_support == true
sources += files('net_crc_sse.c')
cflags += ['-DCC_X86_64_SSE42_PCLMULQDQ_SUPPORT']
if net_crc_avx512_cpu_support == true
sources += files('net_crc_avx512.c')
cflags += ['-DCC_X86_64_AVX512_VPCLMULQDQ_SUPPORT']
elif net_crc_avx512_cc_support == true
build_static_net_crc_avx512_lib = 1
net_crc_avx512_lib_cflags = ['-mavx512f',
'-mavx512bw',
'-mavx512dq',
'-mavx512vl',
'-mvpclmulqdq',
'-mavx2',
'-mavx']
cflags += ['-DCC_X86_64_AVX512_VPCLMULQDQ_SUPPORT']
endif
elif net_crc_sse42_cc_support == true
build_static_net_crc_sse42_lib = 1
net_crc_sse42_lib_cflags = ['-mpclmul', '-maes']
cflags += ['-DCC_X86_64_SSE42_PCLMULQDQ_SUPPORT']
if net_crc_avx512_cc_support == true
build_static_net_crc_avx512_lib = 1
net_crc_avx512_lib_cflags = ['-mpclmul',
'-maes',
'-mavx512f',
'-mavx512bw',
'-mavx512dq',
'-mavx512vl',
'-mvpclmulqdq',
'-mavx2',
'-mavx']
cflags += ['-DCC_X86_64_AVX512_VPCLMULQDQ_SUPPORT']
endif
endif
if net_crc_sse42_cpu_support == true
sources += files('net_crc_sse.c')
cflags += ['-DCC_X86_64_SSE42_PCLMULQDQ_SUPPORT']
if net_crc_avx512_cpu_support == true
sources += files('net_crc_avx512.c')
cflags += ['-DCC_X86_64_AVX512_VPCLMULQDQ_SUPPORT']
elif net_crc_avx512_cc_support == true
build_static_net_crc_avx512_lib = 1
net_crc_avx512_lib_cflags = [
'-mavx512f',
'-mavx512bw',
'-mavx512dq',
'-mavx512vl',
'-mvpclmulqdq',
'-mavx2',
'-mavx',
]
cflags += ['-DCC_X86_64_AVX512_VPCLMULQDQ_SUPPORT']
endif
elif net_crc_sse42_cc_support == true
build_static_net_crc_sse42_lib = 1
net_crc_sse42_lib_cflags = ['-mpclmul', '-maes']
cflags += ['-DCC_X86_64_SSE42_PCLMULQDQ_SUPPORT']
if net_crc_avx512_cc_support == true
build_static_net_crc_avx512_lib = 1
net_crc_avx512_lib_cflags = [
'-mpclmul',
'-maes',
'-mavx512f',
'-mavx512bw',
'-mavx512dq',
'-mavx512vl',
'-mvpclmulqdq',
'-mavx2',
'-mavx',
]
cflags += ['-DCC_X86_64_AVX512_VPCLMULQDQ_SUPPORT']
endif
endif
if build_static_net_crc_sse42_lib == 1
net_crc_sse42_lib = static_library(
'net_crc_sse42_lib',
'net_crc_sse.c',
dependencies: static_rte_eal,
c_args: [cflags,
net_crc_sse42_lib_cflags])
objs += net_crc_sse42_lib.extract_objects('net_crc_sse.c')
endif
if build_static_net_crc_sse42_lib == 1
net_crc_sse42_lib = static_library(
'net_crc_sse42_lib',
'net_crc_sse.c',
dependencies: static_rte_eal,
c_args: [cflags,
net_crc_sse42_lib_cflags])
objs += net_crc_sse42_lib.extract_objects('net_crc_sse.c')
endif
if build_static_net_crc_avx512_lib == 1
net_crc_avx512_lib = static_library(
'net_crc_avx512_lib',
'net_crc_avx512.c',
dependencies: static_rte_eal,
c_args: [cflags,
net_crc_avx512_lib_cflags])
objs += net_crc_avx512_lib.extract_objects('net_crc_avx512.c')
endif
if build_static_net_crc_avx512_lib == 1
net_crc_avx512_lib = static_library(
'net_crc_avx512_lib',
'net_crc_avx512.c',
dependencies: static_rte_eal,
c_args: [cflags,
net_crc_avx512_lib_cflags])
objs += net_crc_avx512_lib.extract_objects('net_crc_avx512.c')
endif
elif (dpdk_conf.has('RTE_ARCH_ARM64') and
cc.get_define('__ARM_FEATURE_CRYPTO', args: machine_args) != '')
sources += files('net_crc_neon.c')
cflags += ['-DCC_ARM64_NEON_PMULL_SUPPORT']
cc.get_define('__ARM_FEATURE_CRYPTO', args: machine_args) != '')
sources += files('net_crc_neon.c')
cflags += ['-DCC_ARM64_NEON_PMULL_SUPPORT']
endif

View File

@ -1,8 +1,17 @@
# SPDX-License-Identifier: BSD-3-Clause
# Copyright(C) 2020 Marvell International Ltd.
sources = files('null.c', 'log.c', 'ethdev_rx.c', 'ethdev_tx.c', 'ip4_lookup.c',
'ip4_rewrite.c', 'pkt_drop.c', 'ethdev_ctrl.c', 'pkt_cls.c')
sources = files(
'ethdev_ctrl.c',
'ethdev_rx.c',
'ethdev_tx.c',
'ip4_lookup.c',
'ip4_rewrite.c',
'log.c',
'null.c',
'pkt_cls.c',
'pkt_drop.c',
)
headers = files('rte_node_ip4_api.h', 'rte_node_eth_api.h')
# Strict-aliasing rules are violated by uint8_t[] to context size casts.
cflags += '-fno-strict-aliasing'

View File

@ -1,16 +1,20 @@
# SPDX-License-Identifier: BSD-3-Clause
# Copyright(c) 2017 Intel Corporation
sources = files('rte_pipeline.c',
'rte_port_in_action.c',
'rte_table_action.c',
'rte_swx_pipeline.c',
'rte_swx_pipeline_spec.c',
'rte_swx_ctl.c',)
headers = files('rte_pipeline.h',
'rte_port_in_action.h',
'rte_table_action.h',
'rte_swx_pipeline.h',
'rte_swx_extern.h',
'rte_swx_ctl.h',)
sources = files(
'rte_pipeline.c',
'rte_port_in_action.c',
'rte_table_action.c',
'rte_swx_pipeline.c',
'rte_swx_pipeline_spec.c',
'rte_swx_ctl.c',
)
headers = files(
'rte_pipeline.h',
'rte_port_in_action.h',
'rte_table_action.h',
'rte_swx_pipeline.h',
'rte_swx_extern.h',
'rte_swx_ctl.h',
)
deps += ['port', 'table', 'meter', 'sched', 'cryptodev']

View File

@ -2,45 +2,45 @@
# Copyright(c) 2017 Intel Corporation
sources = files(
'rte_port_ethdev.c',
'rte_port_fd.c',
'rte_port_frag.c',
'rte_port_ras.c',
'rte_port_ring.c',
'rte_port_sched.c',
'rte_port_source_sink.c',
'rte_port_sym_crypto.c',
'rte_port_eventdev.c',
'rte_swx_port_ethdev.c',
'rte_swx_port_fd.c',
'rte_swx_port_ring.c',
'rte_swx_port_source_sink.c',
)
'rte_port_ethdev.c',
'rte_port_fd.c',
'rte_port_frag.c',
'rte_port_ras.c',
'rte_port_ring.c',
'rte_port_sched.c',
'rte_port_source_sink.c',
'rte_port_sym_crypto.c',
'rte_port_eventdev.c',
'rte_swx_port_ethdev.c',
'rte_swx_port_fd.c',
'rte_swx_port_ring.c',
'rte_swx_port_source_sink.c',
)
headers = files(
'rte_port_ethdev.h',
'rte_port_fd.h',
'rte_port_frag.h',
'rte_port_ras.h',
'rte_port.h',
'rte_port_ring.h',
'rte_port_sched.h',
'rte_port_source_sink.h',
'rte_port_sym_crypto.h',
'rte_port_eventdev.h',
'rte_swx_port.h',
'rte_swx_port_ethdev.h',
'rte_swx_port_fd.h',
'rte_swx_port_ring.h',
'rte_swx_port_source_sink.h',
)
'rte_port_ethdev.h',
'rte_port_fd.h',
'rte_port_frag.h',
'rte_port_ras.h',
'rte_port.h',
'rte_port_ring.h',
'rte_port_sched.h',
'rte_port_source_sink.h',
'rte_port_sym_crypto.h',
'rte_port_eventdev.h',
'rte_swx_port.h',
'rte_swx_port_ethdev.h',
'rte_swx_port_fd.h',
'rte_swx_port_ring.h',
'rte_swx_port_source_sink.h',
)
deps += ['ethdev', 'sched', 'ip_frag', 'cryptodev', 'eventdev']
if dpdk_conf.has('RTE_PORT_PCAP')
ext_deps += pcap_dep # dependency provided in config/meson.build
ext_deps += pcap_dep # dependency provided in config/meson.build
endif
if dpdk_conf.has('RTE_LIB_KNI')
sources += files('rte_port_kni.c')
headers += files('rte_port_kni.h')
deps += 'kni'
sources += files('rte_port_kni.c')
headers += files('rte_port_kni.h')
deps += 'kni'
endif

View File

@ -2,16 +2,23 @@
# Copyright(c) 2017 Intel Corporation
if not is_linux
build = false
reason = 'only supported on Linux'
build = false
reason = 'only supported on Linux'
endif
sources = files('rte_power.c', 'power_acpi_cpufreq.c',
'power_kvm_vm.c', 'guest_channel.c',
'rte_power_empty_poll.c',
'power_pstate_cpufreq.c',
'rte_power_pmd_mgmt.c',
'power_common.c')
headers = files('rte_power.h','rte_power_empty_poll.h',
'rte_power_pmd_mgmt.h',
'rte_power_guest_channel.h')
sources = files(
'guest_channel.c',
'power_acpi_cpufreq.c',
'power_common.c',
'power_kvm_vm.c',
'power_pstate_cpufreq.c',
'rte_power.c',
'rte_power_empty_poll.c',
'rte_power_pmd_mgmt.c',
)
headers = files(
'rte_power.h',
'rte_power_empty_poll.h',
'rte_power_pmd_mgmt.h',
'rte_power_guest_channel.h'
)
deps += ['timer', 'ethdev']

View File

@ -2,7 +2,6 @@
# Copyright 2020 Mellanox Technologies, Ltd
sources = files('rte_regexdev.c')
headers = files('rte_regexdev.h',
'rte_regexdev_driver.h')
headers = files('rte_regexdev.h', 'rte_regexdev_driver.h')
indirect_headers += files('rte_regexdev_core.h')
deps += ['mbuf']

View File

@ -5,15 +5,16 @@ sources = files('rte_ring.c')
headers = files('rte_ring.h')
# most sub-headers are not for direct inclusion
indirect_headers += files (
'rte_ring_core.h',
'rte_ring_elem.h',
'rte_ring_elem_pvt.h',
'rte_ring_c11_pvt.h',
'rte_ring_generic_pvt.h',
'rte_ring_hts.h',
'rte_ring_hts_elem_pvt.h',
'rte_ring_peek.h',
'rte_ring_peek_elem_pvt.h',
'rte_ring_peek_zc.h',
'rte_ring_rts.h',
'rte_ring_rts_elem_pvt.h')
'rte_ring_core.h',
'rte_ring_elem.h',
'rte_ring_elem_pvt.h',
'rte_ring_c11_pvt.h',
'rte_ring_generic_pvt.h',
'rte_ring_hts.h',
'rte_ring_hts_elem_pvt.h',
'rte_ring_peek.h',
'rte_ring_peek_elem_pvt.h',
'rte_ring_peek_zc.h',
'rte_ring_rts.h',
'rte_ring_rts_elem_pvt.h',
)

View File

@ -2,6 +2,10 @@
# Copyright(c) 2017 Intel Corporation
sources = files('rte_sched.c', 'rte_red.c', 'rte_approx.c')
headers = files('rte_sched.h', 'rte_sched_common.h',
'rte_red.h', 'rte_approx.h')
headers = files(
'rte_approx.h',
'rte_red.h',
'rte_sched.h',
'rte_sched_common.h',
)
deps += ['mbuf', 'meter']

View File

@ -5,7 +5,8 @@ sources = files('rte_stack.c', 'rte_stack_std.c', 'rte_stack_lf.c')
headers = files('rte_stack.h')
# subheaders, not for direct inclusion by apps
indirect_headers += files(
'rte_stack_std.h',
'rte_stack_lf.h',
'rte_stack_lf_generic.h',
'rte_stack_lf_c11.h')
'rte_stack_std.h',
'rte_stack_lf.h',
'rte_stack_lf_generic.h',
'rte_stack_lf_c11.h',
)

View File

@ -1,36 +1,40 @@
# SPDX-License-Identifier: BSD-3-Clause
# Copyright(c) 2017 Intel Corporation
sources = files('rte_table_acl.c',
'rte_table_lpm.c',
'rte_table_lpm_ipv6.c',
'rte_table_hash_cuckoo.c',
'rte_table_hash_key8.c',
'rte_table_hash_key16.c',
'rte_table_hash_key32.c',
'rte_table_hash_ext.c',
'rte_table_hash_lru.c',
'rte_table_array.c',
'rte_table_stub.c',
'rte_swx_table_em.c',
'rte_swx_table_wm.c',
)
headers = files('rte_table.h',
'rte_table_acl.h',
'rte_table_lpm.h',
'rte_table_lpm_ipv6.h',
'rte_table_hash.h',
'rte_table_hash_cuckoo.h',
'rte_table_hash_func.h',
'rte_lru.h',
'rte_table_array.h',
'rte_table_stub.h',
'rte_swx_table.h',
'rte_swx_table_em.h',
'rte_swx_table_wm.h',
)
sources = files(
'rte_swx_table_em.c',
'rte_swx_table_wm.c',
'rte_table_acl.c',
'rte_table_array.c',
'rte_table_hash_cuckoo.c',
'rte_table_hash_ext.c',
'rte_table_hash_key8.c',
'rte_table_hash_key16.c',
'rte_table_hash_key32.c',
'rte_table_hash_lru.c',
'rte_table_lpm.c',
'rte_table_lpm_ipv6.c',
'rte_table_stub.c',
)
headers = files(
'rte_lru.h',
'rte_swx_table.h',
'rte_swx_table_em.h',
'rte_swx_table_wm.h',
'rte_table.h',
'rte_table_acl.h',
'rte_table_array.h',
'rte_table_hash.h',
'rte_table_hash_cuckoo.h',
'rte_table_hash_func.h',
'rte_table_lpm.h',
'rte_table_lpm_ipv6.h',
'rte_table_stub.h',
)
deps += ['mbuf', 'port', 'lpm', 'hash', 'acl']
indirect_headers += files('rte_lru_x86.h',
'rte_lru_arm64.h',
'rte_table_hash_func_arm64.h')
indirect_headers += files(
'rte_lru_arm64.h',
'rte_lru_x86.h',
'rte_table_hash_func_arm64.h'
)

View File

@ -2,25 +2,36 @@
# Copyright(c) 2017-2018 Intel Corporation
if not is_linux
build = false
reason = 'only supported on Linux'
build = false
reason = 'only supported on Linux'
endif
if has_libnuma == 1
dpdk_conf.set10('RTE_LIBRTE_VHOST_NUMA', true)
dpdk_conf.set10('RTE_LIBRTE_VHOST_NUMA', true)
endif
if (toolchain == 'gcc' and cc.version().version_compare('>=8.3.0'))
cflags += '-DVHOST_GCC_UNROLL_PRAGMA'
cflags += '-DVHOST_GCC_UNROLL_PRAGMA'
elif (toolchain == 'clang' and cc.version().version_compare('>=3.7.0'))
cflags += '-DVHOST_CLANG_UNROLL_PRAGMA'
cflags += '-DVHOST_CLANG_UNROLL_PRAGMA'
elif (toolchain == 'icc' and cc.version().version_compare('>=16.0.0'))
cflags += '-DVHOST_ICC_UNROLL_PRAGMA'
cflags += '-DVHOST_ICC_UNROLL_PRAGMA'
endif
dpdk_conf.set('RTE_LIBRTE_VHOST_POSTCOPY',
cc.has_header('linux/userfaultfd.h'))
dpdk_conf.set('RTE_LIBRTE_VHOST_POSTCOPY', cc.has_header('linux/userfaultfd.h'))
cflags += '-fno-strict-aliasing'
sources = files('fd_man.c', 'iotlb.c', 'socket.c', 'vdpa.c',
'vhost.c', 'vhost_user.c',
'virtio_net.c', 'vhost_crypto.c')
headers = files('rte_vhost.h', 'rte_vdpa.h', 'rte_vdpa_dev.h',
'rte_vhost_crypto.h', 'rte_vhost_async.h')
sources = files(
'fd_man.c',
'iotlb.c',
'socket.c',
'vdpa.c',
'vhost.c',
'vhost_crypto.c',
'vhost_user.c',
'virtio_net.c',
)
headers = files(
'rte_vdpa.h',
'rte_vdpa_dev.h',
'rte_vhost.h',
'rte_vhost_async.h',
'rte_vhost_crypto.h',
)
deps += ['ethdev', 'cryptodev', 'hash', 'pci']