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]
Other format: [Raw text]

Re: PATCH: Add --with-arch=cpu (Re: Should gcc configurted for CPU to generate code for CPU by default?)


On Fri, Jul 19, 2002 at 02:15:49PM -0400, Daniel Jacobowitz wrote:
> 
> Right now, we have a handful of architectures that support --with-cpu=. 
> They all do it in different ways.  Most don't recognize it at all. 
> What I am suggesting is that the driver (gcc.c) should recognize
> -march= and -mcpu= if TARGET_{ARCH,CPU}_DEFAULT are defined.  The only
> thing it should do with them is supply one if none is present.  The
> backend handles the rest, as before.
 

I agree it is not a bad idea. However, different platforms have
different treatments for TARGET_{ARCH,CPU}_DEFAULT. Some of them treat
them as bit masks, while others treat them as indexes. Unify them or
not belongs to a different discussion.

While we are on this topic, we have -march, -mcpu and -mtune for
different backends. They may not have the same meaning even when the
option name is the same. It is particularly true for -mcpu. I don't
see if we can unify them without breaking backward compatibility.


H.J.


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