You are not logged in.
hm. i cannot trust in skottish's benchmarks. with additional SSE3 support it cannot be slower. i have to doubt that results.
this kind of stuff happens. since i'm going to own my own 64bit machine soon, i'll throw my 23c in here too.
when using -mtune no features not available on -march or if not set CHOST, will be used. on i686 for example i can set:
CFLAGS="-march=i686 -O2 -pipe -mtune=pentium3"
note a pentium2 or amd k6-3 is a i686 but does not come with SSE necessarily. these flags will still optimize for a pentium3 but without using extra instructions not available on plain i686. what happens here is something different. the pentium3 has a few architectural advances by design over the pentium2 for example. like better pipelining etc. to take advantage of this kind of thing, not new instructions are needed.
generally, -msse* seems to be not well supported by gcc. nobody really got the hang of how to use it really and if -like in mplayer - they do ASM instead of regular C code for that very reason. i personally wouldn't enable -msse* at all and not tune for anything that locks out some users. the speed gain is so little, it is simply not worth it.
I recognize that while theory and practice are, in theory, the same, they are, in practice, different. -Mark Mitchell
Offline
We won't change our FLAGS to not loose non sse3 capabable cpus.
FYI: gcc4.2 that is now in testing will need a small additional switch -mtune=generic we will soon have in our pacman package for both architecture for all official packages. for your local FLAGS you can change them to -march=native -mtune=native -O2 -pipe. gcc should autodetect now all supported cpu features
Offline
I'm trying to get a better understanding of how this works:
-mtune=generic
Will that produce all the functions of common hardware (to be utilised where applicable), or will it only produce code that's compatible with all common processors?
I'm wondering whether packages built with said flags will utilise functions such as sse3 if the end users hardware supports it?
And this confuses me a little:
-march=native -mtune=native -O2 -pipe
Is the mtune option required here? The man page says, "specifying -march=cpu-type implies -mtune=cpu-type".
Cheers
Last edited by ahaslam (2007-06-07 18:32:55)
Offline
Athalon 64 3800+, no sse3 here.
Jayson Vaughn
#pacman -R GOP
(1/302) removing John Boehner [#####################] 100%
Offline
I'm trying to get a better understanding of how this works:
-mtune=generic
Will that produce all the functions of common hardware (to be utilised where applicable), or will it only produce code that's compatible with all common processors?
I'm wondering whether packages built with said flags will utilise functions such as sse3 if the end users hardware supports it?
-mtune will never touch the used cpu instructions. it will produce generic optimised code that will run on any common cpu not very much optimised.
And this confuses me a little:
-march=native -mtune=native -O2 -pipe
Is the mtune option required here? The man page says, "specifying -march=cpu-type implies -mtune=cpu-type".
Cheers
-mtune shouldn't be required. but it is safe to leave it there.
for more see section "Target-specific flags" http://www.redhat.com/magazine/011sep05 … gcc/#intro
Offline
Thank you
Offline