On 6/16/16, 10:03 AM, "users on behalf of Pavey, Nicholas" <users-bounces at 
dpdk.org on behalf of npavey at akamai.com> wrote:

>Hi Folks,
>
>I?m developing a benchmarking environment for some code that I?ll eventually 
>link with the DPDK. However, at the moment it?s not integrated with the DPDK 
>because it makes testing and debug easier.
>
>I?d like to use the ?rte_memcpy? function, since it?s a good implementation 
>using non-temporal instructions. The DPDK version is a lot better than 
>something I hack together ;-)
>
>When I compile the code I?m getting a lot of errors along the lines of this:
>
>c_src/rte_memcpy.h:870:2: error: incompatible type for argument 2 of 
>'_mm_storeu_si128'
>In file included from c_src/main.h:23:0,
>                 from c_src/main.c:1:
>/usr/lib/gcc/x86_64-linux-gnu/4.8/include/emmintrin.h:700:1: note: expected 
>'__m128i' but argument is of type 'int'
> _mm_storeu_si128 (__m128i *__P, __m128i __B)
> ^
>In file included from c_src/main.h:33:0,
>                 from c_src/main.c:1:
>c_src/rte_memcpy.h:870:2: error: incompatible type for argument 2 of 
>'_mm_storeu_si128'
>  MOVEUNALIGNED_LEFT47(dst, src, n, srcofs);
>  ^
>In file included from c_src/main.h:23:0,
>                 from c_src/main.c:1:
>/usr/lib/gcc/x86_64-linux-gnu/4.8/include/emmintrin.h:700:1: note: expected 
>'__m128i' but argument is of type 'int'
> _mm_storeu_si128 (__m128i *__P, __m128i __B)
> ^
>In file included from c_src/main.h:33:0,
>                 from c_src/main.c:1:
>c_src/rte_memcpy.h:870:2: error: incompatible type for argument 2 of 
>'_mm_storeu_si128'
>  MOVEUNALIGNED_LEFT47(dst, src, n, srcofs);
>  ^
>In file included from c_src/main.h:23:0,
>                 from c_src/main.c:1:
>/usr/lib/gcc/x86_64-linux-gnu/4.8/include/emmintrin.h:700:1: note: expected 
>'__m128i' but argument is of type 'int'
> _mm_storeu_si128 (__m128i *__P, __m128i __B)
>
>(There are an awful lot of these?)
>
>
>The compile command line is:
>
>  gcc -O3 --no-omit-frame-pointer -Wall -m64 -std=c99 -g 
> ?I/include/path/to/libhugetlbfs ?I/include/path/to/libnuma -Ic_src -Icpp_src 
> -c c_src/main.c -o c_objs/main.o

One suggestion is to build DPDK and link against the DPDK library to get 
rte_memcpy or link using the rte_memcpy.o file. Also if DPDK compiles without 
problems, then add a ?V=1? to the make line as in ?make install 
T=x86_64-native-linuxapp-gcc V=1? which will show you the compile line for 
rte_memcpy.c

I hope this helps.
++Keith
>
>The compiler version is:
>
>  gcc -v
>  Using built-in specs.
>  COLLECT_GCC=gcc
>  COLLECT_LTO_WRAPPER=/usr/lib/gcc/x86_64-linux-gnu/4.8/lto-wrapper
>  Target: x86_64-linux-gnu
>  Configured with: ../src/configure -v --with-pkgversion='Ubuntu 
> 4.8.4-2ubuntu1~14.04.1' 
> --with-bugurl=file:///usr/share/doc/gcc-4.8/README.Bugs 
> --enable-languages=c,c++,java,go,d,fortran,objc,obj-c++ --prefix=/usr 
> --program-suffix=-4.8 --enable-shared --enable-linker-build-id 
> --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix 
> --with-gxx-include-dir=/usr/include/c++/4.8 --libdir=/usr/lib --enable-nls 
> --with-sysroot=/ --enable-clocale=gnu --enable-libstdcxx-debug 
> --enable-libstdcxx-time=yes --enable-gnu-unique-object --disable-libmudflap 
> --enable-plugin --with-system-zlib --disable-browser-plugin 
> --enable-java-awt=gtk --enable-gtk-cairo 
> --with-java-home=/usr/lib/jvm/java-1.5.0-gcj-4.8-amd64/jre --enable-java-home 
> --with-jvm-root-dir=/usr/lib/jvm/java-1.5.0-gcj-4.8-amd64 
> --with-jvm-jar-dir=/usr/lib/jvm-exports/java-1.5.0-gcj-4.8-amd64 
> --with-arch-directory=amd64 --with-ecj-jar=/usr/share/java/eclipse-ecj.jar 
> --enable-objc-gc --enable-multiarch --disable-werror --with-arch-32=i686 
> --with-abi=m64 --with-multilib-list=m32,m64,mx32 --with-tune=generic 
> --enable-checking=release --build=x86_64-linux-gnu --host=x86_64-linux-gnu 
> --target=x86_64-linux-gnu
>  Thread model: posix
>  gcc version 4.8.4 (Ubuntu 4.8.4-2ubuntu1~14.04.1) 
>
>OS distribution : Ubuntu 14.04
>Kernel version : 3.13.0-85-generic
>
>Processor type : Intel(R) Core(TM) i5-3470 CPU @ 3.20GHz
>Processor flags: fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov 
>pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx rdtscp lm 
>constant_tsc arch_perfmon pebs bts rep_good nopl xtopology nonstop_tsc 
>aperfmperf eagerfpu pni pclmulqdq dtes64 monitor ds_cpl vmx smx est tm2 ssse3 
>cx16 xtpr pdcm pcid sse4_1 sse4_2 x2apic popcnt tsc_deadline_timer aes xsave 
>avx f16c rdrand lahf_lm ida arat epb xsaveopt pln pts dtherm tpr_shadow vnmi 
>flexpriority ept vpid fsgsbase smep erms
>
>
>Can anyone suggest what I can do to make ?rte_memcpy? compile correctly 
>outside of the complete build environment?
>
>Thanks,
>
>
>Nick
>
>
>



Reply via email to