From 20d95bfa29057104b352e5d82699edede8658499 Mon Sep 17 00:00:00 2001 From: Xi Ruoyao Date: Mon, 3 Feb 2025 11:15:22 +0800 Subject: testsuite: Fix up toplevel-asm-1.c for LoongArch Like RISC-V, on LoongArch we don't really support %cN for SYMBOL_REFs even with -fno-pic. gcc/testsuite/ChangeLog: * c-c++-common/toplevel-asm-1.c: Use %cc3 %cc4 instead of %c3 %c4 on LoongArch. --- gcc/testsuite/c-c++-common/toplevel-asm-1.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'gcc') diff --git a/gcc/testsuite/c-c++-common/toplevel-asm-1.c b/gcc/testsuite/c-c++-common/toplevel-asm-1.c index d6766b0..e1687d2 100644 --- a/gcc/testsuite/c-c++-common/toplevel-asm-1.c +++ b/gcc/testsuite/c-c++-common/toplevel-asm-1.c @@ -9,7 +9,7 @@ int v[42]; void foo (void) {} /* Not all targets can use %cN even in non-pic code. */ -#if defined(__riscv) +#if defined(__riscv) || defined(__loongarch__) asm ("# %0 %1 %2 %cc3 %cc4 %5 %% %=" #else asm ("# %0 %1 %2 %c3 %c4 %5 %% %=" -- cgit v1.1