nightmorph    09/07/19 02:05:08

  Modified:             gcc-optimization.xml
  Log:
  add some information about -march=native

Revision  Changes    Path
1.16                 xml/htdocs/doc/en/gcc-optimization.xml

file : 
http://sources.gentoo.org/viewcvs.py/gentoo/xml/htdocs/doc/en/gcc-optimization.xml?rev=1.16&view=markup
plain: 
http://sources.gentoo.org/viewcvs.py/gentoo/xml/htdocs/doc/en/gcc-optimization.xml?rev=1.16&content-type=text/plain
diff : 
http://sources.gentoo.org/viewcvs.py/gentoo/xml/htdocs/doc/en/gcc-optimization.xml?r1=1.15&r2=1.16

Index: gcc-optimization.xml
===================================================================
RCS file: /var/cvsroot/gentoo/xml/htdocs/doc/en/gcc-optimization.xml,v
retrieving revision 1.15
retrieving revision 1.16
diff -u -r1.15 -r1.16
--- gcc-optimization.xml        26 Jun 2009 03:33:21 -0000      1.15
+++ gcc-optimization.xml        19 Jul 2009 02:05:08 -0000      1.16
@@ -1,6 +1,6 @@
 <?xml version='1.0' encoding='UTF-8'?>
 <!DOCTYPE guide SYSTEM "/dtd/guide.dtd">
-<!-- $Header: /var/cvsroot/gentoo/xml/htdocs/doc/en/gcc-optimization.xml,v 
1.15 2009/06/26 03:33:21 nightmorph Exp $ -->
+<!-- $Header: /var/cvsroot/gentoo/xml/htdocs/doc/en/gcc-optimization.xml,v 
1.16 2009/07/19 02:05:08 nightmorph Exp $ -->
 
 <guide link="/doc/en/gcc-optimization.xml">
 <title>Compilation Optimization Guide</title>
@@ -19,8 +19,8 @@
 <!-- See http://creativecommons.org/licenses/by-sa/2.5 -->
 <license/>
 
-<version>1.10</version>
-<date>2009-06-25</date>
+<version>1.11</version>
+<date>2009-07-18</date>
 
 <chapter>
 <title>Introduction</title>
@@ -195,6 +195,21 @@
 CXXFLAGS="${CFLAGS}"
 </pre>
 
+<p>
+If you still aren't sure what kind of CPU you have, you may just want to use
+<c>-march=native</c>. When this flag is used, GCC will detect your processor 
and
+automatically set appropriate flags for it. <brite>However, this should not be
+used if you intend to compile packages for a different CPU!</brite>
+</p>
+
+<p>
+So if you're compiling packages on one computer, but intend to run them on a
+different computer (such as when using a fast computer to build for an older,
+slower machine), then <e>do not</e> use <c>-march=native</c>. "Native" means
+that the code produced will run <e>only</e> on that type of CPU. The
+applications built with <c>-march=native</c> on an AMD Athlon 64 CPU will not 
be
+able to run on an old VIA C3 CPU.
+</p>
 
 <p>
 Also available are the <c>-mtune</c> and <c>-mcpu</c> flags. These flags are




Reply via email to