[Bug inline-asm/56405] New: [4.8 Regression] ICE on questionable "m" argument

jakub at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Wed Feb 20 09:28:00 GMT 2013


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

             Bug #: 56405
           Summary: [4.8 Regression] ICE on questionable "m" argument
    Classification: Unclassified
           Product: gcc
           Version: 4.8.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: inline-asm
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: jakub@gcc.gnu.org
            Target: arm-linux-gnueabi


void
foo (void)
{
  asm volatile ("" : "+m" (*(volatile unsigned short *) 0x100001UL));
}

ICEs on arm at -O2 or -Os starting I think with:
2012-03-16  Martin Jambor  <mjambor@suse.cz>

        * expr.c (expand_expr_real_1): Handle misaligned scalar reads from
        memory through MEM_REFs by calling extract_bit_field.
stmt.c is unprepared, when it requests EXPAND_MEMORY, not to get a MEM, but REG
instead.
I wonder whether the kernel code is just a bug in this case, or if it can
actually work properly, especially on strict alignment targets.



More information about the Gcc-bugs mailing list