Bug 11594 - testcase gcc.dg/20020103-1.c fails with "scan-assembler-not LC"
: testcase gcc.dg/20020103-1.c fails with "scan-assembler-not LC"
Status: RESOLVED FIXED
Product: gcc
Classification: Unclassified
Component: target
: 3.3.1
: P2 normal
: ---
Assigned To: Not yet assigned to anyone
: http://gcc.gnu.org/ml/gcc-patches/200...
: patch, wrong-code
:
:
  Show dependency treegraph
 
Reported: 2003-07-19 21:08 UTC by dank
Modified: 2008-12-12 19:37 UTC (History)
5 users (show)

See Also:
Host:
Target: powerpc-unknown-linux-gnu
Build:
Known to work:
Known to fail:
Last reconfirmed: 2005-12-31 20:28:39


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description dank 2003-07-19 21:08:34 UTC
I'm building and testing gcc with http://kegel.com/crosstool
for ppc405 and ppc750.  On those processors, I see the test failure
FAIL: gcc.dg/20020103-1.c scan-assembler-not LC
I've tested both gcc-3.3 (release) and gcc-ss-3_3-20030714, same problem.

This also showed up on the 3.4 branch on powerpc-ibm-aix4.3.3.0; see
http://gcc.gnu.org/ml/gcc-testresults/2003-05/msg01265.html
and on the 3.1 branch on powerpc-unknown-netbsd1.5ZC; see
http://gcc.gnu.org/ml/gcc-testresults/2002-05/msg00770.html
It also shows up in Debian's tests for 3.2.3 and 3.3.
Comment 1 Andrew Pinski 2003-07-19 22:14:57 UTC
I can confirm this in 3.3.1 (20030714), will be trying the mainline soon.
Comment 2 Andrew Pinski 2003-07-19 22:30:05 UTC
It also happens on the mainline (20030719).
Comment 3 Segher Boessenkool 2003-10-17 15:58:19 UTC
The testcase is wrong; the LC's that are in the generated
code have nothing to do with spilling, but just with
loading the addresses for the call to f2.
Comment 5 Janis Johnson 2006-04-18 16:52:11 UTC
As of mainline 20060417 the test is still failing on powerpc-linux, although it
passes for AIX and Darwin.  Until December 2005 when Alan fixed the target
specifier, the test had not been run on powerpc64-linux with -m32.
Comment 6 Jack Howarth 2006-09-20 23:49:20 UTC
Does anyone know why we don't run this test at lp64 on powerpc? I find that on
powerpc-apple-darwin8 the following changes allow...

make check-gcc RUNTESTFLAGS="--target_board=unix'{-m32,-m64}'
dg.exp=20020103-1.*"

to pass at both -m32 and -m64 on Darwin PPC...

Index: gcc.dg/20020103-1.c
===================================================================
--- gcc.dg/20020103-1.c (revision 117095)
+++ gcc.dg/20020103-1.c (working copy)
@@ -1,8 +1,8 @@
 /* Verify that constant equivalences get reloaded properly, either by being
    spilled to the stack, or regenerated, but not dropped to memory.  */
-/* { dg-do compile { target { { i?86-*-* rs6000-*-* alpha*-*-* x86_64-*-* } ||
{ powerpc*-*-* && ilp32 } } } } */
+/* { dg-do compile { target { i?86-*-* rs6000-*-* alpha*-*-* x86_64-*-*
powerpc*-*-* } } } */
 /* { dg-options "-O2 -fpic -fno-omit-frame-pointer
-fno-asynchronous-unwind-tables" } */
-/* { dg-final { scan-assembler-not "LC\[0-9\]" { xfail powerpc*-*-* } } } */
+/* { dg-final { scan-assembler-not "LC\[0-9\]" } } */

 /* Clobber all call-saved registers that can hold a pointer value.  */
 #if defined(__i386__)

Could someone test this on AIX?
Comment 7 Andrew Pinski 2006-09-21 01:06:22 UTC
Subject: Re:  testcase gcc.dg/20020103-1.c fails with "scan-assembler-not LC"

> 
> 
> 
> ------- Comment #6 from howarth at nitro dot med dot uc dot edu  2006-09-20 23:49 -------
> Does anyone know why we don't run this test at lp64 on powerpc? I find that on
> powerpc-apple-darwin8 the following changes allow...
> 
> make check-gcc RUNTESTFLAGS="--target_board=unix'{-m32,-m64}'
> dg.exp=20020103-1.*"
> 
> to pass at both -m32 and -m64 on Darwin PPC...

Yes because AIX uses TOC, just like ppc64-linux so you will get LC for sure.

-- Pinski
Comment 8 Steven Bosscher 2008-02-03 14:57:16 UTC
I don't see this FAIL in any recently reported test results (on the
gcc-testresults mainling list) for powerpc-linux or powerpc64-linux.  Thus,
fixed.
Comment 9 Janis Johnson 2008-02-04 17:53:23 UTC
It doesn't show up as FAIL for powerpc*-*-linux* becaues that check includes an
xfail:

  /* { dg-final { scan-assembler-not "LC\[0-9\]" { xfail powerpc*-*-* } } } */

Reopened.
Comment 10 Steven Bosscher 2008-02-04 18:12:14 UTC
oops, sorry!
Comment 11 Janis Johnson 2008-12-12 19:36:09 UTC
Subject: Bug 11594

Author: janis
Date: Fri Dec 12 19:34:48 2008
New Revision: 142718

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=142718
Log:
    PR target/11594
    * gcc.dg/20020103-1.c: Remove XFAIL for powerpc.

Modified:
    trunk/gcc/testsuite/ChangeLog
    trunk/gcc/testsuite/gcc.dg/20020103-1.c
Comment 12 Janis Johnson 2008-12-12 19:37:32 UTC
Fixed.

From the patch mail:

The scan assembler check in gcc.dg/20020103-1.c is now XPASS for all powerpc
targets reported in the gcc-testresults archive.  It started passing for
powerpc64-unknown-linux-gnu with -m32 sometime between r139537 (2008-08-25) and
r139604 (2008-08-27).  This patch removes the xfail for that check.

The test fails for powerpc64-unknown-linux-gnu with -m64, so I left the
restriction that on powerpc*-*-* it it only run for ilp32.