[llvm-commits] [llvm] r119975 - /llvm/trunk/tools/llvmc/src/Base.td.in

Mikhail Glushenkov foldr at codedgers.com
Mon Nov 22 09:10:09 PST 2010


Author: foldr
Date: Mon Nov 22 11:10:09 2010
New Revision: 119975

URL: http://llvm.org/viewvc/llvm-project?rev=119975&view=rev
Log:
llvmc: Make -march/-mcpu/-mtune behaviour more consistent with gcc.

Modified:
    llvm/trunk/tools/llvmc/src/Base.td.in

Modified: llvm/trunk/tools/llvmc/src/Base.td.in
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/tools/llvmc/src/Base.td.in?rev=119975&r1=119974&r2=119975&view=diff
==============================================================================
--- llvm/trunk/tools/llvmc/src/Base.td.in (original)
+++ llvm/trunk/tools/llvmc/src/Base.td.in Mon Nov 22 11:10:09 2010
@@ -11,7 +11,6 @@
 //
 //===----------------------------------------------------------------------===//
 
-
 // Options
 
 def OptList : OptionList<[
@@ -46,9 +45,9 @@
  (parameter_option "linker",
     (help "Choose linker (possible values: gcc, g++)")),
  (parameter_option "mtune",
-    (help "Target a specific CPU type"), (hidden), (forward_not_split)),
+    (help "Target a specific CPU type"), (forward_not_split)),
  (parameter_option "march",
-    (help "A synonym for -mtune"), (hidden), (forward_not_split)),
+    (help "Architecture to generate code for"), (forward_not_split)),
  (parameter_option "mcpu",
     (help "A deprecated synonym for -mtune"), (hidden), (forward_not_split)),
  (switch_option "mfix-and-continue",
@@ -203,8 +202,8 @@
          (not_empty "D"), (forward "D"),
          (not_empty "arch"), (forward "arch"),
          (not_empty "march"), (forward "march"),
-         (not_empty "mtune"), (forward "mtune"),
          (not_empty "mcpu"), (forward "mcpu"),
+         (not_empty "mtune"), (forward "mtune"),
          (not_empty "m"), (forward "m"),
          (switch_on "mfix-and-continue"), (forward "mfix-and-continue"),
          (switch_on "m32"), (forward "m32"),
@@ -296,9 +295,10 @@
           (switch_on "fPIC"), (append_cmd "-relocation-model=pic"),
           (switch_on "mdynamic-no-pic"),
                      (append_cmd "-relocation-model=dynamic-no-pic"),
-          (not_empty "march"), (forward_as "march", "-mcpu"),
-          (not_empty "mtune"), (forward_as "mtune", "-mcpu"),
+          (not_empty "march"), (forward "march"),
           (not_empty "mcpu"), (forward "mcpu"),
+          (and (not_empty "mtune"), (empty "mcpu")),
+                     (forward_as "mtune", "-mcpu"),
           (not_empty "m"), (forward_transformed_value "m", "ConvertToMAttr"),
           (not_empty "Wllc,"), (forward_value "Wllc,")))
 ]>;





More information about the llvm-commits mailing list