[llvm-commits] [llvm] r53319 - in /llvm/trunk/lib/Target/X86: X86ATTAsmPrinter.cpp X86TargetAsmInfo.cpp
Anton Korobeynikov
asl at math.spbu.ru
Wed Jul 9 06:28:19 PDT 2008
Author: asl
Date: Wed Jul 9 08:28:19 2008
New Revision: 53319
URL: http://llvm.org/viewvc/llvm-project?rev=53319&view=rev
Log:
Honour text sections
Modified:
llvm/trunk/lib/Target/X86/X86ATTAsmPrinter.cpp
llvm/trunk/lib/Target/X86/X86TargetAsmInfo.cpp
Modified: llvm/trunk/lib/Target/X86/X86ATTAsmPrinter.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/X86/X86ATTAsmPrinter.cpp?rev=53319&r1=53318&r2=53319&view=diff
==============================================================================
--- llvm/trunk/lib/Target/X86/X86ATTAsmPrinter.cpp (original)
+++ llvm/trunk/lib/Target/X86/X86ATTAsmPrinter.cpp Wed Jul 9 08:28:19 2008
@@ -154,10 +154,11 @@
void X86ATTAsmPrinter::emitFunctionHeader(const MachineFunction &MF) {
const Function *F = MF.getFunction();
+ std::string SectionName = TAI->SectionForGlobal(F);
decorateName(CurrentFnName, F);
- SwitchToTextSection(TAI->SectionForGlobal(F).c_str(), F);
+ SwitchToTextSection(SectionName.c_str());
unsigned FnAlign = OptimizeForSize ? 1 : 4;
switch (F->getLinkage()) {
Modified: llvm/trunk/lib/Target/X86/X86TargetAsmInfo.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/X86/X86TargetAsmInfo.cpp?rev=53319&r1=53318&r2=53319&view=diff
==============================================================================
--- llvm/trunk/lib/Target/X86/X86TargetAsmInfo.cpp (original)
+++ llvm/trunk/lib/Target/X86/X86TargetAsmInfo.cpp Wed Jul 9 08:28:19 2008
@@ -433,7 +433,7 @@
return UniqueSectionForGlobal(F, kind);
}
} else if (const GlobalVariable *GVar = dyn_cast<GlobalVariable>(GV)) {
- if (GVar->isWeakForLinker()
+ if (GVar->isWeakForLinker())
return UniqueSectionForGlobal(GVar, kind);
else {
switch (kind) {
More information about the llvm-commits
mailing list