[dpdk-dev] warnings when including DPDK headers from a C++17 source file
Montorsi, Francesco
fmontorsi at empirix.com
Fri Jul 13 15:51:21 CEST 2018
Hi all,
I just noticed that, because of the removal of the "register" keyword in C++17, when I compile my DPDK-enabled code with -std=c++17 I get the following:
In file included from ../../../Third-Party/cpp-libs/dpdk/include/rte_ether.h:53:0,
from ../../../Third-Party/cpp-libs/dpdk/include/rte_ethdev.h:186,
from HwEmulCaptureDPDK.cpp:43:
../../../Third-Party/cpp-libs/dpdk/include/rte_byteorder.h: In function 'uint16_t rte_arch_bswap16(uint16_t)':
../../../Third-Party/cpp-libs/dpdk/include/rte_byteorder.h:57:20: warning: ISO C++1z does not allow 'register' storage class specifier [-Wregister]
register uint16_t x = _x;
^
../../../Third-Party/cpp-libs/dpdk/include/rte_byteorder.h: In function 'uint32_t rte_arch_bswap32(uint32_t)':
../../../Third-Party/cpp-libs/dpdk/include/rte_byteorder.h:72:20: warning: ISO C++1z does not allow 'register' storage class specifier [-Wregister]
register uint32_t x = _x;
^
In file included from ../../../Third-Party/cpp-libs/dpdk/include/rte_byteorder.h:121:0,
from ../../../Third-Party/cpp-libs/dpdk/include/rte_ether.h:53,
from ../../../Third-Party/cpp-libs/dpdk/include/rte_ethdev.h:186,
from HwEmulCaptureDPDK.cpp:43:
../../../Third-Party/cpp-libs/dpdk/include/rte_byteorder_64.h: In function 'uint64_t rte_arch_bswap64(uint64_t)':
../../../Third-Party/cpp-libs/dpdk/include/rte_byteorder_64.h:52:20: warning: ISO C++1z does not allow 'register' storage class specifier [-Wregister]
register uint64_t x = _x;
^
?Just thought to let you know... that's a small issue for me since I'm using -Werror
Thanks,
Francesco
More information about the dev
mailing list