More x86 target feature support.
 - Apologies for the extremely gross code duplication, I want to get
   this working and then decide how to get this information out of the
   back end.

 - This replaces -m[no-]sse4[12] by -m[no-]sse4, it appears gcc
   doesn't distinguish them?

 - -msse, etc. now properly disable/enable related features.

 - Don't always define __SSE3__...

 - The main missing functionality bit here is that we don't initialize
   the features based on the CPU for all -march options.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@71117 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/tools/clang-cc/clang-cc.cpp b/tools/clang-cc/clang-cc.cpp
index cdb606c..3282c19 100644
--- a/tools/clang-cc/clang-cc.cpp
+++ b/tools/clang-cc/clang-cc.cpp
@@ -1426,17 +1426,11 @@
               Name);
       exit(1);
     }
-
-    llvm::StringMap<bool>::iterator it = Features.find(Name + 1);
-    if (it == Features.end()) {
-      fprintf(stderr, "error: clang-cc: invalid target feature string: %s\n", 
-              Name);
+    if (!Target->setFeatureEnabled(Features, Name + 1, (Name[0] == '+'))) {
+      fprintf(stderr, "error: clang-cc: invalid target feature name: %s\n", 
+              Name + 1);
       exit(1);
     }
-
-    // FIXME: Actually, we need to apply all the features implied by
-    // this feature.
-    it->second = (Name[0] == '+');
   }
 }