I'm working on changing the MMX implementation to use intrinsics in all cases, which should stop various optimization passes from creating MMX instructions that screw up the x87 stack. Right now the MMX instructions are split between X86InstrMMX.td and X86InstrSSE.td, presumably on the historical grounds that some of them weren't introduced until SSE or SSSE3, and require support for that feature to work. I'm thinking it would be cleaner to keep them all in X86InstrMMX. Does anyone have an opinion about this?
On Sep 8, 2010, at 3:08 PM, Dale Johannesen wrote:> I'm working on changing the MMX implementation to use intrinsics in > all cases, which should stop various optimization passes from creating > MMX instructions that screw up the x87 stack. Right now the MMX > instructions are split between X86InstrMMX.td and X86InstrSSE.td, > presumably on the historical grounds that some of them weren't > introduced until SSE or SSSE3, and require support for that feature to > work. I'm thinking it would be cleaner to keep them all in > X86InstrMMX. Does anyone have an opinion about this? >As long as there's no code duplication to it - have at. -eric
On Sep 8, 2010, at 3:08 PMPDT, Dale Johannesen wrote:> I'm working on changing the MMX implementation to use intrinsics in > all cases, which should stop various optimization passes from > creating MMX instructions that screw up the x87 stack. Right now > the MMX instructions are split between X86InstrMMX.td and > X86InstrSSE.td, presumably on the historical grounds that some of > them weren't introduced until SSE or SSSE3, and require support for > that feature to work. I'm thinking it would be cleaner to keep them > all in X86InstrMMX. Does anyone have an opinion about this?To clarify, by "MMX instruction" I mean anything that puts the chip into MMX mode, so that x87 instructions no longer work. This includes some instructions that also use SSE registers.
On Sep 8, 2010, at 3:08 PM, Dale Johannesen wrote:> I'm working on changing the MMX implementation to use intrinsics in > all cases, which should stop various optimization passes from creating > MMX instructions that screw up the x87 stack. Right now the MMX > instructions are split between X86InstrMMX.td and X86InstrSSE.td, > presumably on the historical grounds that some of them weren't > introduced until SSE or SSSE3, and require support for that feature to > work. I'm thinking it would be cleaner to keep them all in > X86InstrMMX. Does anyone have an opinion about this? >I concur. -bw
On Sep 8, 2010, at 3:08 PM, Dale Johannesen wrote:> I'm working on changing the MMX implementation to use intrinsics in > all cases, which should stop various optimization passes from creating > MMX instructions that screw up the x87 stack. Right now the MMX > instructions are split between X86InstrMMX.td and X86InstrSSE.td, > presumably on the historical grounds that some of them weren't > introduced until SSE or SSSE3, and require support for that feature to > work. I'm thinking it would be cleaner to keep them all in > X86InstrMMX. Does anyone have an opinion about this?Sounds great, please do. The X86 .td files need a reorganization in general, this sounds like a great first step. -Chris