make PIC vs DynamicNoPIC be explicit in PICStyles.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@75275 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Target/X86/X86Subtarget.h b/lib/Target/X86/X86Subtarget.h
index 6509f04..9bba940 100644
--- a/lib/Target/X86/X86Subtarget.h
+++ b/lib/Target/X86/X86Subtarget.h
@@ -26,10 +26,11 @@
 /// 
 namespace PICStyles {
 enum Style {
-  Stub,   // Used on i386-darwin
-  GOT,    // Used on many 32-bit unices.
-  RIPRel, // Used on X86-64 when not in -static mode.
-  None    // Set when in -static mode (not PIC or DynamicNoPIC mode).
+  StubPIC,          // Used on i386-darwin in -fPIC mode.
+  StubDynamicNoPIC, // Used on i386-darwin in -mdynamic-no-pic mode.
+  GOT,              // Used on many 32-bit unices in -fPIC mode.
+  RIPRel,           // Used on X86-64 when not in -static mode.
+  None              // Set when in -static mode (not PIC or DynamicNoPIC mode).
 };
 }
 
@@ -186,9 +187,16 @@
   bool isPICStyleGOT() const { return PICStyle == PICStyles::GOT; }
   bool isPICStyleRIPRel() const { return PICStyle == PICStyles::RIPRel; }
 
-  bool isPICStyleStubPIC(const TargetMachine &TM) const;
-  bool isPICStyleStubNoDynamic(const TargetMachine &TM) const;
-  bool isPICStyleStubAny() const { return PICStyle == PICStyles::Stub; }
+  bool isPICStyleStubPIC(const TargetMachine &TM) const {
+    return PICStyle == PICStyles::StubPIC;
+  }
+
+  bool isPICStyleStubNoDynamic(const TargetMachine &TM) const {
+    return PICStyle == PICStyles::StubDynamicNoPIC;
+  }
+  bool isPICStyleStubAny() const {
+    return PICStyle == PICStyles::StubDynamicNoPIC ||
+           PICStyle == PICStyles::StubPIC; }
   
   /// getDarwinVers - Return the darwin version number, 8 = Tiger, 9 = Leopard,
   /// 10 = Snow Leopard, etc.