romcc -O and -O2

Eric W. Biederman ebiederman at lnxi.com
Sun Mar 28 17:19:01 CEST 2004


ebiederman at lnxi.com (Eric W. Biederman) writes:

> YhLu <YhLu at tyan.com> writes:
> 
> > Eric,
> > 
> > What's the difference of -O and -O2? t seems -O2 can produce small code for
> > auto.c.
> 
> The set of optimizations performed.  Essentially the difference
> -O2 performs conditional constant propagation.  
> 
> Historically there have been some bugs with -02, but they should not apply
> at this point.

Also it is worth nothing that all of my optimizations are either to reduce
register pressure or to reduce code size.  In general less code needs fewer
registers.  There is an exception in the case of function calls, to functions
that are called more than once, because you need to remember you
return address somewhere, and that takes a register.

Eric



More information about the coreboot mailing list