changing -mattr behavior with mmx and sse


When setting -mattr option on X86, I would like to treat MMX separately from SSE levels. This would allow a client who sets the attributes directly to set the SSE level independent of MMX, e.g., llc -march=x86 -mattr=sse41, one would get sse4.1 with mmx disabled while llc -march=x86 -mattr=mmx -mattr=sse42 will get mmx and sse42. If anyone objects to this change, please let me know.

   -- Mon Ping

Might you instead consider just adding a -disable-mmx option?


I don't object, but please don't change the defaults.
You're likely to find places the SSE code assumes MMX exists...

Might you instead consider just adding a -disable-mmx option?

I agree, this is a better approach. This distinguishes between capabilities of the chip and the desire to codegen specific vectors one way or another.


This approach sounds better to me as well.

   -- Mon Ping

Hi Dale,

I will not change the default. I would dislike to see any regressions due to this type of change.

-- Mon Ping

For what it's worth, we've been operating in this mode for a while now (using a somewhat brute force local patch), and haven't seen any issues with it so far.