Message ID | AANLkTinK-086rHBJbuEX4LNBf0=fUB0LoW6+Fj7Ch8LF@mail.gmail.com |
---|---|
State | New |
Headers | show |
diff --git a/gcc/config/i386/i386.c b/gcc/config/i386/i386.c index 204211a..4914299 100644 --- a/gcc/config/i386/i386.c +++ b/gcc/config/i386/i386.c @@ -12921,7 +12921,12 @@ ix86_print_operand (FILE *file, rtx x, int code) if (ASSEMBLER_DIALECT == ASM_ATT) putc ('$', file); - fprintf (file, "0x%08lx", (long unsigned int) l); + /* 'q' is only used on pushq which takes 32bit signed extended + immediate. */ + if (code == 'q') + fprintf (file, "%d", (int) l); + else + fprintf (file, "0x%08x", (unsigned int) l); } /* These float cases don't actually occur as immediate operands. */