Changes in directory llvm/include/llvm/CodeGen:

AsmPrinter.h updated: 1.37 -> 1.38
---
Log message:

Split SwitchSection into the SwitchTo{Text|Data}Section functions, to better
support assemblers that distinguish the two.


---
Diffs of the changes:  (+19 -3)

 AsmPrinter.h |   22 +++++++++++++++++++---
 1 files changed, 19 insertions(+), 3 deletions(-)


Index: llvm/include/llvm/CodeGen/AsmPrinter.h
diff -u llvm/include/llvm/CodeGen/AsmPrinter.h:1.37 
llvm/include/llvm/CodeGen/AsmPrinter.h:1.38
--- llvm/include/llvm/CodeGen/AsmPrinter.h:1.37 Tue May  2 00:37:32 2006
+++ llvm/include/llvm/CodeGen/AsmPrinter.h      Mon May  8 23:59:30 2006
@@ -179,16 +179,32 @@
     AsmPrinter(std::ostream &o, TargetMachine &TM);
     
   public:
-    /// SwitchSection - Switch to the specified section of the executable if we
-    /// are not already in it!  If GV is non-null and if the global has an
+    /// SwitchToTextSection - Switch to the specified section of the executable
+    /// if we are not already in it!  If GV is non-null and if the global has 
an
     /// explicitly requested section, we switch to the section indicated for 
the
     /// global instead of NewSection.
     ///
     /// If the new section is an empty string, this method forgets what the
     /// current section is, but does not emit a .section directive.
     ///
-    void SwitchSection(const char *NewSection, const GlobalValue *GV);
+    /// This method is used when about to emit executable code.
+    ///
+    void SwitchToTextSection(const char *NewSection, const GlobalValue *GV);
 
+    /// SwitchToDataSection - Switch to the specified section of the executable
+    /// if we are not already in it!  If GV is non-null and if the global has 
an
+    /// explicitly requested section, we switch to the section indicated for 
the
+    /// global instead of NewSection.
+    ///
+    /// If the new section is an empty string, this method forgets what the
+    /// current section is, but does not emit a .section directive.
+    ///
+    /// This method is used when about to emit data.  For most assemblers, this
+    /// is the same as the SwitchToTextSection method, but not all assemblers
+    /// are the same.
+    ///
+    void SwitchToDataSection(const char *NewSection, const GlobalValue *GV);
+    
     /// getPreferredAlignmentLog - Return the preferred alignment of the
     /// specified global, returned in log form.  This includes an explicitly
     /// requested alignment (if the global has one).



_______________________________________________
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits

Reply via email to