This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] Fix PR middle-end/26306


> My beef with AGGREGATE_TYPE_P is that I can't see any reason that an 
> SImode "struct S { int i; }" should be treated differently from plain 
> "int i".  Even accepting the arguments about hardware registers, etc., I 
> would still have a hard time explaining why the struct should behave 
> differently from the scalar.

But that's not the only way to make an SImode struct!  What about a struct
of four chars with an alignment of 32 specified.  That's also often SImode.
Should a volatile reference to it produce one SImode reference or four
QImode references?  More importantly, do we really want to be in the business
of answering that question?

> Even under that argument, AGGREGATE_TYPE_P still isn't the right thing, 
> since, IIUC, what we tested before was BLKmode.  Shouldn't the test be 
> using that instead, if our goal is to replicate the old semantics?

We did test BLKmode previously and I agree that would be the ideal test for
that reason even given my comment above.  The question is whether it would be
enough to fix the ICE in question, specifically if there's a GIMPLE-level
distinction between aggregates and scalars.  Eric: does just a BLKmode test
work?


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]