http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41202
kl4yfd at gmail dot com changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |kl4yfd at gmail dot com --- Comment #1 from kl4yfd at gmail dot com 2012-11-18 07:50:27 UTC --- (In reply to comment #0) > But this last one doesn't seem sensible: > > $ /usr/local/gcc-4.4.1/bin/gcc -m32 -march=core2 -mno-mmx -E -dM -x c > /dev/null > | grep "\(MMX\|SSE\)" > #define __SSE2__ 1 > #define __SSSE3__ 1 > #define __SSE__ 1 > #define __SSE3__ 1 > This one is sensible. SSE is actually not dependent on MMX, even though gcc is setup that way. :-) Setting MMX as a dependency to SSE_MATH just a trick to prevent those registers in the CPU and the extra processing power from being wasted when the 387 is not in use (as 387 and MMX share those registers... poorly) Will double-check if -mfpumath=sse (SSE_MATH) sets MMX with -m32 in gcc 4.7.2 > I can repeat these last few tests using the default 64-bit configuration: > > $ /usr/local/gcc-4.4.1/bin/gcc -E -dM -x c /dev/null | grep > "\(MMX\|SSE\)"#define __MMX__ 1 > #define __SSE2_MATH__ 1 > #define __SSE_MATH__ 1 > #define __SSE2__ 1 > #define __SSE__ 1 > $ /usr/local/gcc-4.4.1/bin/gcc -mno-sse2 -E -dM -x c /dev/null | grep > "\(MMX\|SSE\)" > #define __MMX__ 1 > #define __SSE_MATH__ 1 > #define __SSE__ 1 > $ /usr/local/gcc-4.4.1/bin/gcc -mno-sse -E -dM -x c /dev/null | grep > "\(MMX\|SSE\)" > #define __MMX__ 1 This one needs a look. On first example, SSE_MATH is enabled but MMX is not auto-enabled <-- ? On last example, when compiled with -mno-sse (and therefore no SSE_MATH..) MMX was on by default. <-- ? - for this example, FPU math is being done in the 387, but MMX is also on. - Should this unsafe behavior be the default ? == Will check if persists in 4.7.2