Message ID | A614194ED15B4844BC4C9FB7F21FCD927045654A@hhmail02.hh.imgtec.org |
---|---|
State | New |
Headers | show |
Toma Tabacu <Toma.Tabacu@imgtec.com> writes: > pr68273.c currently fails when targeting MIPS64 with the n64 ABI. > This is because it is checking for some registers in SImode, but, because of > n64, they will actually be in DImode. > > This patch restricts matching for SImode registers to ilp32 targets and adds > matching for DImode registers for lp64 targets. > This makes sure that the test is run on as many targets as possible, compared > to the alternative of adding -mabi=32 to the test options. > > I haven't checked to see what happens with eabi or o64, though. > > Does this approach work ? Or should I just make separate tests for o32, n32 and > n64, each one using -mabi=* as a test option to force an ABI ? I'm happy with this approach. As long as it works for o32/n32/n64 that is sufficient right now. If anyone starts to build and run the testsuite regularly for default eabi/o64 then tests can be fixed which will involve much more than just this one. > Tested with mips-mti-elf. > > Regards, > Toma > > gcc/testsuite/ > > * gcc.target/mips/pr68273.c (dg-final): Match SImode registers only for > ilp32 targets and match DImode registers for lp64 targets. OK, thanks. Matthew
> From: Matthew Fortune > > > > gcc/testsuite/ > > > > * gcc.target/mips/pr68273.c (dg-final): Match SImode registers only for > > ilp32 targets and match DImode registers for lp64 targets. > > OK, thanks. > > Matthew Committed as r245874. Thanks, Toma
diff --git a/gcc/testsuite/gcc.target/mips/pr68273.c b/gcc/testsuite/gcc.target/mips/pr68273.c index cbe81e1..ce8ca93 100644 --- a/gcc/testsuite/gcc.target/mips/pr68273.c +++ b/gcc/testsuite/gcc.target/mips/pr68273.c @@ -75,5 +75,8 @@ op (Node q) } -/* { dg-final { scan-rtl-dump-times "\\\(set \\\(reg:SI 5 \\\$5\\\)" 2 "expand" } } */ -/* { dg-final { scan-rtl-dump-times "\\\(set \\\(reg:SI 6 \\\$6\\\)" 1 "expand" } } */ +/* { dg-final { scan-rtl-dump-times "\\\(set \\\(reg:SI 5 \\\$5\\\)" 2 "expand" { target { ilp32 } } } } */ +/* { dg-final { scan-rtl-dump-times "\\\(set \\\(reg:SI 6 \\\$6\\\)" 1 "expand" { target { ilp32 } } } } */ + +/* { dg-final { scan-rtl-dump-times "\\\(set \\\(reg:DI 5 \\\$5\\\)" 2 "expand" { target { lp64 } } } } */ +/* { dg-final { scan-rtl-dump-times "\\\(set \\\(reg:DI 6 \\\$6\\\)" 1 "expand" { target { lp64 } } } } */