In or1k structs are returned from functions using the memory address
passed in r3.  In the current version of GCC the struct stores changed
from r11 (the return value) to r3 the incoming memory address.  Both of
are valid.

Adjust the test to match what GCC is producing now.

gcc/testsuite/ChangeLog:

        * gcc.target/or1k/return-2.c: Fix test.
---
 gcc/testsuite/gcc.target/or1k/return-2.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/gcc/testsuite/gcc.target/or1k/return-2.c 
b/gcc/testsuite/gcc.target/or1k/return-2.c
index add3720c88e..c072ae23142 100644
--- a/gcc/testsuite/gcc.target/or1k/return-2.c
+++ b/gcc/testsuite/gcc.target/or1k/return-2.c
@@ -16,4 +16,4 @@ struct a getstruct (long aa) {
 /* Ensure our return value is returned on stack.  */
 /* { dg-final { scan-assembler-not "r12," } } */
 /* { dg-final { scan-assembler "l.or\\s+r11, r3, r3" } } */
-/* { dg-final { scan-assembler-times "l.sw\\s+\\d+.r11.," 3 } } */
+/* { dg-final { scan-assembler-times "l.sw\\s+\\d+.r3.," 3 } } */
-- 
2.49.0


Reply via email to