[Bug middle-end/51895] [4.7 Regression] ICE in simplify_subreg

jakub at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Thu Jan 19 13:32:00 GMT 2012


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51895

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |ebotcazou at gcc dot
                   |                            |gnu.org

--- Comment #7 from Jakub Jelinek <jakub at gcc dot gnu.org> 2012-01-19 13:11:13 UTC ---
(In reply to comment #6)
> > Untested patch that attempts to fix BLKmode MEM_REF expansion with
> > non-DECL_ADDRESSABLE non-BLKmode base.  It creates abysmal code, so IMNSHO
> > eipa_sra should be fixed not to do this.
> 
> Hm, can't we do better using extract_bit_field?  I mean, it definitely
> should work to do any BIT_FIELD_REF on an rvalue, even if it is a register.
> The patch from comment #1 doesn't look completely wrong, it just seems that
> the caller should have catered for using the mode of the reg.  The docs
> of operand_subword also say 'MODE is the mode of OP in case it is a CONST_INT'
> so MODE should be irrelevant if REG_P (op) ...
> 
> Seems to be a tricky area, but using a stack temporary looks like overkill.

We don't have BLKmode pseudos, the only thing that can be BLKmode is MEM.  So
I'm afraid we can't avoid that.  E.g. VIEW_CONVERT_EXPR of a TImode value to
BLKmode value would be expanded by spilling the TImode value to a stack
temporary and adjust_address it to BLKmode too.



More information about the Gcc-bugs mailing list