Re: gcc-4.5/4.4: Bug in .subreg1 pass?

2011-03-01 Thread Denis Chertykov
2011/2/28 Georg-Johann Lay : > Denis Chertykov schrieb: >> >> 2011/2/26 Georg-Johann Lay : >> >>> Ok, this is the patch I meant: >>> >>> http://gcc.gnu.org/viewcvs?view=revision&revision=86842 >>> >>> it allows just Pmode in r29:r28 because of some spill failures in PR15417 >>> and PR12017. >> >> I

Re: gcc-4.5/4.4: Bug in .subreg1 pass?

2011-02-28 Thread Georg-Johann Lay
Denis Chertykov schrieb: 2011/2/26 Georg-Johann Lay : Ok, this is the patch I meant: http://gcc.gnu.org/viewcvs?view=revision&revision=86842 it allows just Pmode in r29:r28 because of some spill failures in PR15417 and PR12017. It was a stupid workaround. I think that the problem exists any

Re: gcc-4.5/4.4: Bug in .subreg1 pass?

2011-02-27 Thread Denis Chertykov
2011/2/26 Georg-Johann Lay : > Georg-Johann Lay schrieb: >> >> Denis Chertykov schrieb: >> >>> 2011/2/26 Georg Johann Lay >>> Eric Botcazou schrieb: >> What does "word" mean here? Is it a 32-bit entity or is it according >> to >> word_mode which is QImode for avr? > >

Re: gcc-4.5/4.4: Bug in .subreg1 pass?

2011-02-26 Thread Georg-Johann Lay
Georg-Johann Lay schrieb: Denis Chertykov schrieb: 2011/2/26 Georg Johann Lay Eric Botcazou schrieb: What does "word" mean here? Is it a 32-bit entity or is it according to word_mode which is QImode for avr? The latter, it is machine-dependent. So the same should be true for QI-sub

Re: gcc-4.5/4.4: Bug in .subreg1 pass?

2011-02-26 Thread Paolo Bonzini
On 02/24/2011 06:04 PM, Michael Matz wrote: Funny. As far back as I remember we consistently said that bits of the same word, but outside the subreg are left with undefined values after storing into the subreg, except if wrapped with a strict_low_part. In fact that's the whole point of strict_l

Re: gcc-4.5/4.4: Bug in .subreg1 pass?

2011-02-26 Thread Georg-Johann Lay
Georg-Johann Lay schrieb: Denis Chertykov schrieb: 2011/2/26 Georg Johann Lay Eric Botcazou schrieb: What does "word" mean here? Is it a 32-bit entity or is it according to word_mode which is QImode for avr? The latter, it is machine-dependent. So the same should be true for QI-sub

Re: gcc-4.5/4.4: Bug in .subreg1 pass?

2011-02-26 Thread Georg-Johann Lay
Denis Chertykov schrieb: 2011/2/26 Georg Johann Lay Eric Botcazou schrieb: What does "word" mean here? Is it a 32-bit entity or is it according to word_mode which is QImode for avr? The latter, it is machine-dependent. So the same should be true for QI-subregs of scalar modes if UNITS_

Re: gcc-4.5/4.4: Bug in .subreg1 pass?

2011-02-26 Thread Denis Chertykov
2011/2/26 Georg Johann Lay > > Eric Botcazou schrieb: >>> >>> What does "word" mean here? Is it a 32-bit entity or is it according to >>> word_mode which is QImode for avr? >> >> The latter, it is machine-dependent. >> >> >>> So the same should be true for QI-subregs of scalar modes if >>> UNITS_P

Re: gcc-4.5/4.4: Bug in .subreg1 pass?

2011-02-25 Thread Georg Johann Lay
Eric Botcazou schrieb: What does "word" mean here? Is it a 32-bit entity or is it according to word_mode which is QImode for avr? The latter, it is machine-dependent. So the same should be true for QI-subregs of scalar modes if UNITS_PER_WORT = 1. Right? Right. Thanks for that definite c

Re: gcc-4.5/4.4: Bug in .subreg1 pass?

2011-02-25 Thread Eric Botcazou
> What does "word" mean here? Is it a 32-bit entity or is it according to > word_mode which is QImode for avr? The latter, it is machine-dependent. > So the same should be true for QI-subregs of scalar modes if > UNITS_PER_WORT = 1. Right? Right. -- Eric Botcazou

Re: gcc-4.5/4.4: Bug in .subreg1 pass?

2011-02-25 Thread Georg Johann Lay
Paul Koning schrieb: On Feb 24, 2011, at 12:46 PM, Eric Botcazou wrote: Maybe the misunderstanding occurs when the mode of the subreg is less than word_size? It would certainly make sense that a subreg write of less than word_size leaves the bits undefined. ie, if word_size is SImode and we

Re: gcc-4.5/4.4: Bug in .subreg1 pass?

2011-02-24 Thread Paul Koning
On Feb 24, 2011, at 12:46 PM, Eric Botcazou wrote: >> Maybe the misunderstanding occurs when the mode of the subreg is less >> than word_size? It would certainly make sense that a subreg write of >> less than word_size leaves the bits undefined. >> >> ie, if word_size is SImode and we had a wri

Re: gcc-4.5/4.4: Bug in .subreg1 pass?

2011-02-24 Thread Eric Botcazou
> Maybe the misunderstanding occurs when the mode of the subreg is less > than word_size? It would certainly make sense that a subreg write of > less than word_size leaves the bits undefined. > > ie, if word_size is SImode and we had a write to > > (subreg:HI (reg:SI) 0) > > Then the upper bits ar

Re: gcc-4.5/4.4: Bug in .subreg1 pass?

2011-02-24 Thread Jeff Law
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 02/24/11 10:04, Michael Matz wrote: > > Funny. As far back as I remember we consistently said that bits of the > same word, but outside the subreg are left with undefined values after > storing into the subreg, except if wrapped with a strict_lo

Re: gcc-4.5/4.4: Bug in .subreg1 pass?

2011-02-24 Thread Michael Matz
Hi, On Thu, 24 Feb 2011, Jeff Law wrote: > > Target avr suffers from similar problems in 4.3, 4.4 and 4.6 which are > > all reported against avr backend, not against middleend/rtl optimizers. > insn 33 and 34 are fine. 33 sets the high part of the HImode register > to the result of the call to f

Re: gcc-4.5/4.4: Bug in .subreg1 pass?

2011-02-24 Thread Jeff Law
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 02/24/11 07:05, Georg-Johann Lay wrote: > Hi, I am trying to track down/fix PR target/45291. The problem is that > pass .subreg1 generates invalid subregs. > > According to internals "10.8 Registers and Memory, Normal Subregs" > a normal (non-parad

gcc-4.5/4.4: Bug in .subreg1 pass?

2011-02-24 Thread Georg-Johann Lay
Hi, I am trying to track down/fix PR target/45291. The problem is that pass .subreg1 generates invalid subregs. According to internals "10.8 Registers and Memory, Normal Subregs" a normal (non-paradoxical) subreg as Lvalue sets the specifyed subreg and leaves the remaining part of the target word