[dpdk-dev] [PATCH] headers: typeof -> __typeof__ to unbreak C++11 code
Simon Kågström
simon.kagstrom at netinsight.net
Thu Feb 26 12:24:33 CET 2015
On 2015-02-26 12:14, Thomas Monjalon wrote:
> 2015-02-25 14:28, Simon Kagstrom:
>> When compiling C++11-code or above (--std=c++11), the build fails with
>> lots of
>>
>> rte_eth_ctrl.h:517:3: note: in expansion of macro RTE_ALIGN
>> (RTE_ALIGN(RTE_ETH_FLOW_MAX, UINT32_BIT)/UINT32_BIT)
>> ^
> I'd like to be sure that it's working with every compilers we support
> (gcc, icc, clang).
> Anyone to check please?
I guess you mean compiling DPDK itself, but I can add that compiling my
example "app" (i.e., a file which includes the DPDK headers and an empty
main()) with clang++ gives more problems:
include/rte_devargs.h:89:5: error:
'virtual' can only appear on non-static member functions
} virtual;
^
and a slew of warnings of the type
include/rte_byteorder_64.h:45:2: warning:
'register' storage class specifier is deprecated
[-Wdeprecated-register]
register uint64_t x = _x;
^~~~~~~~~
include/rte_memcpy.h:85:25: warning:
cast from 'const uint8_t *' (aka 'const unsigned char *') to
'const __m128i *' increases required alignment from 1 to 16
[-Wcast-align]
xmm0 = _mm_loadu_si128((const __m128i *)src);
// Simon
More information about the dev
mailing list