]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
asm-hard-reg-2.c: Use long long on z to trigger RA error
authorH.J. Lu <hjl.tools@gmail.com>
Sat, 9 Aug 2025 21:00:47 +0000 (14:00 -0700)
committerH.J. Lu <hjl.tools@gmail.com>
Sat, 9 Aug 2025 21:00:47 +0000 (14:00 -0700)
Use long long on z to trigger

error: 'asm' operand has impossible constraints or there are not enough registers

for -m32 on asm statements like:

  __asm__ __volatile__ ("" : "=A" (z), "={rax}" (y));

PR testsuite/121205
* gcc.target/i386/asm-hard-reg-2.c (z): Use long long for -m32
to trigger RA error.

Signed-off-by: H.J. Lu <hjl.tools@gmail.com>
gcc/testsuite/gcc.target/i386/asm-hard-reg-2.c

index b35cf53c5cc0fbcf36156c974e7a2cc3cd002d7e..756f6f8c412468c95e3153ba7af21eb485eda7b5 100644 (file)
@@ -8,7 +8,7 @@ test (void)
 #ifdef __x86_64__
   int z __attribute__ ((mode (TI)));
 #else
-  long z;
+  long long z;
 #endif
 
   __asm__ __volatile__ ("" : "=A" (z), "={rbx}" (y));