On Feb 5, 2014, at 3:43 PM, David Laight <da...@l8s.co.uk> wrote: > On Wed, Feb 05, 2014 at 03:09:59PM -0800, Matt Thomas wrote: >> >>>> >>>> This breaks clang. Please do not depend on one SSE option disabling >>>> another. >>> >>> Without those flags I believe gcc might generate x87 instructions. >>> Quite possibly even for amd64. >>> See a very recent linux fix. >>> Try searching for: Disable generation of traditional x87 instructions >> >> I think Joerg is saying put in -mno-sse2 since that is not disabled >> by -mno-sse when using clang. > > with the gcc I'm looking at (if I'm reading to code properly): > no-sse => no-sse2 => no-sse3 => no-ssse3 & no-sse4a => no-sse4_1 > => no-sse4_2 => no-avx => no-fma => no-fma4
But clang is not gcc. :) > You either need all of them, and the one that the next sub-version > of the cpu/compiler add, or you assume that the first ones imply the > latter - at least to some degree. From llvm/dist/llvm/lib/Target/X86/X86.td: // All x86-64 hardware has SSE2, but we don't mark SSE2 as an implied // feature, because SSE2 can be disabled (e.g. for compiling OS kernels) // without disabling 64-bit mode.