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: unassig...@gcc.gnu.org

        ReportedBy: ja...@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  <mjam...@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.

Reply via email to