]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
MIPS: Adjust mips16e2 related tests for ifcvt costing changes
authorJie Mei <jie.mei@oss.cipunited.com>
Tue, 4 Jul 2023 09:50:48 +0000 (17:50 +0800)
committerYunQiang Su <yunqiang.su@cipunited.com>
Wed, 5 Jul 2023 01:35:10 +0000 (09:35 +0800)
A mips16e2 related test fails after the ifcvt change. The mips16e2
addition also causes a test for unrelated module to fail.

This patch adjusts branch costs when running the two affected tests.

These tests should not require the -mbranch-cost option, and
this issue needs to be addressed.

gcc/testsuite/ChangeLog:

* gcc.target/mips/mips16e2-cmov.c: Adjust branch cost to
encourage if-conversion.
* gcc.target/mips/movcc-3.c: Same as above.

gcc/testsuite/gcc.target/mips/mips16e2-cmov.c
gcc/testsuite/gcc.target/mips/movcc-3.c

index 6e9dd82ebf39832894305aece93816a1411ab6e9..129ea23b65b19f669fb23660b82c9efef7ece15a 100644 (file)
@@ -1,4 +1,4 @@
-/* { dg-options "-mno-abicalls -mgpopt -G8 -mabi=32 -mips16 -mmips16e2" } */
+/* { dg-options "-mno-abicalls -mgpopt -G8 -mabi=32 -mips16 -mmips16e2 -mbranch-cost=2" } */
 /* { dg-skip-if "code quality test" { *-*-* } { "-O0" } { "" } } */
 
 /* Test MOVN.  */
index 80d44098a3f528f79d365ef19882942ddaa9edbe..569a00423c1adc2e65482f881a03fe6b1ca3add0 100644 (file)
@@ -1,5 +1,5 @@
 /* { dg-do compile } */
-/* { dg-options "(HAS_MOVN) -mhard-float -mbranch-cost=2" } */
+/* { dg-options "(HAS_MOVN) -mhard-float -mbranch-cost=3" } */
 /* { dg-skip-if "code quality test" { *-*-* } { "-O0" "-Os" } { "" } } */
 /* { dg-final { scan-assembler "\tmovt\t" } } */
 /* { dg-final { scan-assembler "\tmovf\t" } } */