S/390: -march= and -mcpu= options

Richard Earnshaw rearnsha@arm.com
Tue Jan 7 12:09:00 GMT 2003


> On Dec 23, 2002, Ulrich Weigand <weigand@immd1.informatik.uni-erlangen.de> wrote:
> 
> >> Second, the people who participated in the earlier discussion
> >> agreed that there should be a shorthand.
> 
> > Why shouldn't -march=z900 be enough?
> 
> It should.  IMHO, any sane implementation of -march/-mtune should tune
> for the specified arch unless an -mtune argument is present, which
> renders -mcpu (which is an alias for -march -mtune) totally useless.
> 
> The only exception I can think of is in case the default tuning is
> something actually more recent than the default arch, in which case
> someone might want to downgrade the arch without downgrading tuning.
> This probably happens seldom enough, if ever, that arranging for
> -march to be the -mtune default is perfectly reasonable.
> 

The problem here is that tuning for an architecture (ie an abstract ISA) 
can be meaningless.  There can be multiple implementations of an ISA with 
different trade-offs.  You just can't guess and give good results.

R.



More information about the Gcc-patches mailing list