Message ID | CAKdteOZQiKqmTo_LgLWzDO5tnhaUmsdTsF7Vn2EBAcs3ZGo6hQ@mail.gmail.com |
---|---|
State | Accepted |
Commit | 69b7b4960f6141dae6ad4ca1665dbadfb7394f1d |
Headers | show |
Series | [testsuite] PR90106 Fix cdce3.c testcase | expand |
On 5/20/19 6:00 AM, Christophe Lyon wrote: > Hi, > > As discussed in the PR, the new cdce3.c test fails on > arm-linux-gnueabi, and passes on arm-linux-gnueabihf. > > On arm-linux-gnueabi, the generated code is: > .arm > .fpu softvfp > .type foo, %function > foo: > b sqrtf > > on arm-liunx-gnueabihf, it is: > .arm > .fpu neon > .type foo, %function > foo: > vcmp.f32 s0, #0 > vmrs APSR_nzcv, FPSCR > vmov.f32 s15, s0 > bmi .L10 > vsqrt.f32 s0, s15 > bx lr > .L10: > b sqrtf > > Actually both generate a tail-call, but only the latter says "function > call is shrink-wrapped into error conditions." in the dumps. > > According to what JunMa says in the PR, it seems we want to restrict > this testcase to hard-float cases, so that's what this small patch > does. > > OK? OK jeff
diff --git a/gcc/testsuite/gcc.dg/cdce3.c b/gcc/testsuite/gcc.dg/cdce3.c index 8a74379..7e85d8a 100644 --- a/gcc/testsuite/gcc.dg/cdce3.c +++ b/gcc/testsuite/gcc.dg/cdce3.c @@ -1,6 +1,7 @@ /* { dg-do compile } */ +/* { dg-require-effective-target hard_float } */ /* { dg-options "-O2 -fmath-errno -fdump-tree-cdce-details -fdump-tree-optimized" } */ -/* { dg-final { scan-tree-dump "cdce3.c:9: \[^\n\r]* function call is shrink-wrapped into error conditions\." "cdce" } } */ +/* { dg-final { scan-tree-dump "cdce3.c:10: \[^\n\r]* function call is shrink-wrapped into error conditions\." "cdce" } } */ /* { dg-final { scan-tree-dump "sqrtf \\(\[^\n\r]*\\); \\\[tail call\\\]" "optimized" } } */ float sqrtf (float);