Use instruction itinerary to determine what instructions are 'cheap'.
[oota-llvm.git] / include / llvm / CodeGen / TargetLoweringObjectFileImpl.h
index a9cbe3963cdeeebe95b48408fa1d2fc46728366c..d8f037385957e9f51644cf3afd1779dd45d7b932 100644 (file)
@@ -51,11 +51,6 @@ protected:
   const MCSection *MergeableConst4Section;
   const MCSection *MergeableConst8Section;
   const MCSection *MergeableConst16Section;
-
-protected:
-  const MCSection *getELFSection(StringRef Section, unsigned Type,
-                                 unsigned Flags, SectionKind Kind,
-                                 bool IsExplicit = false) const;
 public:
   TargetLoweringObjectFileELF() {}
   ~TargetLoweringObjectFileELF() {}
@@ -89,11 +84,27 @@ public:
 
 
 class TargetLoweringObjectFileMachO : public TargetLoweringObjectFile {
+  /// TLSDataSection - Section for thread local data.
+  ///
+  const MCSection *TLSDataSection;        // Defaults to ".tdata".
+
+  /// TLSBSSSection - Section for thread local uninitialized data.
+  ///
+  const MCSection *TLSBSSSection;         // Defaults to ".tbss".
+  
+  /// TLSTLVSection - Section for thread local structure infomation.
+  /// Contains the source code name of the variable, visibility and a pointer
+  /// to the initial value (.tdata or .tbss).
+  const MCSection *TLSTLVSection;         // Defaults to ".tlv".
+  
+  /// TLSThreadInitSection - Section for thread local data initialization
+  /// functions.
+  const MCSection *TLSThreadInitSection;  // Defaults to ".thread_init_func".
+  
   const MCSection *CStringSection;
   const MCSection *UStringSection;
   const MCSection *TextCoalSection;
   const MCSection *ConstTextCoalSection;
-  const MCSection *ConstDataCoalSection;
   const MCSection *ConstDataSection;
   const MCSection *DataCoalSection;
   const MCSection *DataCommonSection;
@@ -166,13 +177,15 @@ public:
 
 
 class TargetLoweringObjectFileCOFF : public TargetLoweringObjectFile {
-  mutable void *UniquingMap;
+  const MCSection *DrectveSection;
 public:
-  TargetLoweringObjectFileCOFF() : UniquingMap(0) {}
-  ~TargetLoweringObjectFileCOFF();
+  TargetLoweringObjectFileCOFF() {}
+  ~TargetLoweringObjectFileCOFF() {}
 
   virtual void Initialize(MCContext &Ctx, const TargetMachine &TM);
 
+  virtual const MCSection *getDrectveSection() const { return DrectveSection; }
+
   virtual const MCSection *
   getExplicitSectionGlobal(const GlobalValue *GV, SectionKind Kind,
                            Mangler *Mang, const TargetMachine &TM) const;
@@ -180,11 +193,6 @@ public:
   virtual const MCSection *
   SelectSectionForGlobal(const GlobalValue *GV, SectionKind Kind,
                          Mangler *Mang, const TargetMachine &TM) const;
-
-  /// getCOFFSection - Return the MCSection for the specified COFF section.
-  /// FIXME: Switch this to a semantic view eventually.
-  const MCSection *getCOFFSection(StringRef Name, bool isDirective,
-                                  SectionKind K) const;
 };
 
 } // end namespace llvm