Re: How to make IRA not to move an instruction

2010-05-29 Thread Andrew Pinski
This volatile_spec tells the compiler it does not touch any of the registers so ira and reload can insert its instructions in either place. Lying to reload is bad news. Sent from my iPhone On May 29, 2010, at 8:26 AM, "H.J. Lu" wrote: On Fri, May 28, 2010 at 9:08 PM, Vladimir N. Makarov

Re: How to make IRA not to move an instruction

2010-05-29 Thread H.J. Lu
On Fri, May 28, 2010 at 9:08 PM, Vladimir N. Makarov wrote: > On 05/28/2010 12:38 PM, H.J. Lu wrote: >> >> Hi, >> >> I want to generate vzeroupper when I know upper 128bits aren't used. I >> can't find >> a way to mark an pattern which zeros upper 128bits. So I added >> >> ;; Clear the upper 128bi

Re: How to make IRA not to move an instruction

2010-05-28 Thread Vladimir N. Makarov
On 05/28/2010 12:38 PM, H.J. Lu wrote: Hi, I want to generate vzeroupper when I know upper 128bits aren't used. I can't find a way to mark an pattern which zeros upper 128bits. So I added ;; Clear the upper 128bits of AVX registers, equivalent to a NOP. ;; This should be used only when the uppe

Re: How to make IRA not to move an instruction

2010-05-28 Thread H.J. Lu
On Fri, May 28, 2010 at 3:03 PM, Jeff Law wrote: > On 05/28/10 10:38, H.J. Lu wrote: >> >> Hi, >> >> I want to generate vzeroupper when I know upper 128bits aren't used. I >> can't find >> a way to mark an pattern which zeros upper 128bits. So I added >> > > Presumably you can't use a zero_extract

Re: How to make IRA not to move an instruction

2010-05-28 Thread Jeff Law
On 05/28/10 10:38, H.J. Lu wrote: Hi, I want to generate vzeroupper when I know upper 128bits aren't used. I can't find a way to mark an pattern which zeros upper 128bits. So I added Presumably you can't use a zero_extract? [ ... ] before IRA, (insn 2 4 3 2 x.i:9 (set (reg/v:V8SF 59 [ y

How to make IRA not to move an instruction

2010-05-28 Thread H.J. Lu
Hi, I want to generate vzeroupper when I know upper 128bits aren't used. I can't find a way to mark an pattern which zeros upper 128bits. So I added ;; Clear the upper 128bits of AVX registers, equivalent to a NOP. ;; This should be used only when the upper 128bits are unused. (define_insn "avx_v