[haiku] Re: Ang: Re: gcc4 hibryd

  • From: Christian Packmann <Christian.Packmann@xxxxxx>
  • To: haiku@xxxxxxxxxxxxx
  • Date: Sun, 08 Mar 2009 15:46:52 +0100

holmqvist.fredrik@xxxxxxxxxxxx - 2009-03-08 15:09 :
(I know mtune and march is basically the same)

No, -march determines the allowed instructions in the generated code. This determines on what kind of CPUs the code can run, e.g. -march=i686 breaks on K-6.

-mtune however only influences the behavior of the peephole optimizer, that is which instruction sequences and instruction ordering are used in the generated code. It doesn't influence program compatibility. This flag can probably have a significant impact on performance, especially when code compiled for modern out-of-order CPUS is run on in-order designs like the Pentium or Atom (the code would probably run quite slow). Your choice of i586 should be fine, as it is identical to the pentium settings. It doesn't perform optimally on modern CPUs, but doesn't hurt the old ones.


Other related posts: