From: Jakub Jelinek Date: Tue, 27 Apr 2021 15:50:53 +0000 (+0200) Subject: aarch64: Fix up last commit [PR100200] X-Git-Tag: basepoints/gcc-13~8149 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=1c0c371d0ea297af2e3180c64cd18f2bfce919b1;p=thirdparty%2Fgcc.git aarch64: Fix up last commit [PR100200] Pedantically signed vs. unsigned mismatches in va_arg are only well defined if the value can be represented in both signed and unsigned integer types. 2021-04-27 Jakub Jelinek PR target/100200 * config/aarch64/aarch64.c (aarch64_print_operand): Cast -UINTVAL back to HOST_WIDE_INT. --- diff --git a/gcc/config/aarch64/aarch64.c b/gcc/config/aarch64/aarch64.c index aa148ac9de98..a863af17b5ba 100644 --- a/gcc/config/aarch64/aarch64.c +++ b/gcc/config/aarch64/aarch64.c @@ -10778,7 +10778,7 @@ aarch64_print_operand (FILE *f, rtx x, int code) } if (GET_MODE_CLASS (GET_MODE (x)) == MODE_VECTOR_INT) - asm_fprintf (f, "%wd", -UINTVAL (elt)); + asm_fprintf (f, "%wd", (HOST_WIDE_INT) -UINTVAL (elt)); else if (GET_MODE_CLASS (GET_MODE (x)) == MODE_VECTOR_FLOAT && aarch64_print_vector_float_operand (f, x, true)) ;