This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: gcc.c-torture/compile/20001226-1.c Times Out on Irix


On Fri, Dec 29, 2000 at 06:23:06PM -0800, Geoff Keating wrote:
> > Date: Fri, 29 Dec 2000 14:30:37 -0800
> > From: Jeffrey Oldham <oldham@codesourcery.com>
> > Cc: Jeffrey Oldham <oldham@codesourcery.com>
> 
> > > Why so slow?  It takes only 40 seconds on my powerpc-linux native
> > > machine.
> > 
> > Here are user compilation times (seconds) for native i686-pc-linux-gnu
> > and mips-sgi-irix6.5 gcc compilers built with CFLAGS=-g.
> > 
> > 	 i686 Linux	MIPS Irix
> > 4096	 123.91		594.98 (-O1)	original testcase
> > 512	   1.64		  9.59 (-O1)	testcase modified to use C512, not C4096
> > 512			 15.00 (-O3)
> > 
> > The "512" modification has a preprocessed function body requiring
> > 36225 bytes, which is larger than the 32K size you mentioned.  Would
> > you modify the testcase so it will not cause erroneous test failures
> > for slow machines?
> 
> 32K of object code, not 32K of preprocessed data.  To be precise, it
> needs a little more than 32K between the first goto and the first
> label.  On systems where the compare/branch/branch sequence takes
> about 12 bytes, 2048 is just a little too small.
> 
> I found it very interesting to compare this testcase with different
> compiler versions.  Here's what I found, on x86-linux (Red Hat Linux
> 7):
> 
> kgcc (2.91.66), -O2:
>    82.84 in jump, ~100 total.
> native, current CVS, -O1:
>    60.17, 39.87 in global-alloc.
> native, current CVS, -O2: 
>    75.18 total, 12.73 in jump and 26.06 in global-alloc.
> cross to powerpc-eabisim, current CVS, -O1:
>    38.47 total, 10.83 in jump, 9.27 in combine.
> cross to powerpc-eabisim, current CVS, -O2:
>    76.55 total, 15.84 in jump, 14.37 in GCSE, 19.74 in sched+sched2
> cross to mips-elf, current CVS, -O1:
>    494.20 total, 461.86 in delayed-branch
> cross to mips-elf, current CVS, -O2:
>    459.66 total, 363.61 in delayed-branch
> cross to mips-elf, current CVS, -O2 -fno-delayed-branch:
>    94.90 total, 16.06 jump, 16.00 GCSE, 23.62 sched+sched2
> 
> sparc native, based on CVS of some time ago, -O1:
>    412.65 total, 396.57 in delayed-branch
> sparc native, based on CVS of some time ago, -O2 -fno-delayed-branch:
>    82.74 total, 12.39 jump, 12.78 GCSE, 36.78 sched+sched2
> 
> I can change the testcase so that it uses -fno-delayed-branch, but I
> would suggest that someone needs to look at the delayed-branch code to
> see why it is being so inefficient.

Yes, would you please add "-fno-delayed-branch" to the testcase.  With
this flag, -O3 compilation on my Irix box took just over two minutes.

Thanks,
Jeffrey D. Oldham
oldham@codesourcery.com

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]