This is the mail archive of the gcc@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: How long should -O1 compiles take?


Jeff Law wrote:

> It's meant to optimize, but use less time/memory than -On for n > 1.

I'm wondering whether this actually affects decisions about what goes
into -O1.  Here are some compile times for a file that contains one
large procedure as an automatically-generated finite-state machine;
flags were -O1 -mcpu=ultrasparc -fPIC on an UltraSPARC 250.

	today's gcc-2.96	gcc-2.95.1	egcs-1.1.2

parse: 		5.580000 	5.460000	5.380000
integration: 	0.000000 	0.000000	0.000000
jump: 		3.050000 	3.000000	3.320000
cse: 		2.950000 	2.810000	4.580000
gcse: 		0.000000 	0.000000	0.000000
loop: 		0.010000 	0.010000	0.020000
cse2: 		0.000000 	0.000000	0.000000
branch-prob: 	0.000000 	0.000000	0.000000
flow: 	      176.880000      177.050000       38.220000
combine: 	2.650000 	2.410000	2.360000
regmove: 	0.000000 	0.000000	0.000000
sched: 		0.000000 	0.000000	0.000000
local-alloc: 	1.550000 	1.440000	1.360000
global-alloc:  89.310000      102.680000	2.450000
flow2:        177.160000      176.380000	N/A
sched2: 	0.000000 	0.000000	0.000000
dbranch: 	1.440000 	1.330000	0.820000
shorten-branch: 0.120000 	0.110000	0.130000
stack-reg: 	0.000000 	0.000000	0.000000
final: 		4.130000 	4.000000	0.700000
varconst: 	0.020000 	0.010000	0.040000
symout: 	0.000000 	0.000000	0.000000
dump: 		0.000000 	0.000000	0.000000
gc: 		0.000000 	N/A		N/A

user	      464.64u	      476.67u	       55.75u
system		2.43s		2.19s		5.31s
Total:       7:47.49	     8:00.20	     1:01.59

Is the global register allocation that much better in gcc-2.96 that it
should take 89 seconds now instead of 2.45 seconds as in egcs-1.1.2?
Or is flow analysis/control so much better that gcc should be spending
353 seconds on it rather than 38 seconds?  (I tried -fno-thread-jumps in
gcc-2.95.1 to try to reduce the compile time, but instead it increased
to 478.56u.)

Saying that it takes less time/memory than -On for n>1 doesn't seem to
be saying much.

Brad Lucier


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