rdivacky at freebsd.org
Tue Nov 8 21:32:59 UTC 2011
On Tue, Nov 08, 2011 at 09:23:52PM +0000, Alexander Best wrote:
> On Tue Nov 8 11, Roman Divacky wrote:
> > clang will use "core2" for family=6 and model=15
> > check llvm/lib/Support/Host.cpp
> > what is the problem? The fact that our gcc from the middle-ages
> > does not recognize that?
> actually a few months ago quite a lot of gcc commits happend to add newer
> optimisations (such as core2) to gcc and some commits aimed at modifying gcc,
> so it would make the best -march=native choice there is.
> what's the clang command (similar to gcc -march=native -E -v - </dev/null),
> one can use to check what actual optimisation clang turns "native" into?
clang -### -march=native will show something like
> also there seem to be cross-compilation issues. when people are running i386
> and want to cross-compile for amd64 and put CPUTYPE=core2 (or any other amd64
> cpu) into their make.conf, this gets downgraded by bsd.cpu.mk to prescott.
> see http://www.freebsd.org/cgi/query-pr.cgi?pr=conf/84800
If gcc supports nocona now, the conf/84800 patch is ok. The same goes
with downgrading core2 -> prescott.
I have no idea what gcc supports these days. I think we should just skip
the downgrading completely for clang as it either supports everything or
can be made easily to support what it doesnt.
More information about the freebsd-toolchain