Regarding SIMD features of GCC

John (Eljay) Love-Jensen eljay@adobe.com
Sat Oct 7 14:05:00 GMT 2006


Hi Ranjith,

Sorry - partial answer, may be somewhat tangential.

You can get the compiler to produce a list of optimization produced by a given optimization level list this:

Example for C and -O2:
echo "" | gcc -O2 -fverbose-asm -c -S -x c -; cat ./-.s; rm ./-.s

Example for C++ and -O3:
echo "" | g++ -O3 -fverbose-asm -c -S -x c++ -; cat ./-.s; rm ./-.s

If you have them on your system, one way to access the SSE facilities is through the #include <mmintrin.h> and #include <xmmintrin.h> headers.

HTH,
--Eljay



More information about the Gcc-help mailing list