aboutsummaryrefslogtreecommitdiff
path: root/lib/Target/PIC16/PIC16MemSelOpt.cpp
diff options
context:
space:
mode:
authorSanjiv Gupta <sanjiv.gupta@microchip.com>2009-10-24 18:19:41 +0000
committerSanjiv Gupta <sanjiv.gupta@microchip.com>2009-10-24 18:19:41 +0000
commitecb28f2b49e0f0538a1d147c4742b04c90ccd3ad (patch)
tree503094f9a3c9470f724723c75d2bed3c61a7581e /lib/Target/PIC16/PIC16MemSelOpt.cpp
parent209e6c69d9f87a07cc840e20344b55982762f3ba (diff)
Revert back 85006 for now as it breaks PIC16 tests.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85008 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Target/PIC16/PIC16MemSelOpt.cpp')
-rw-r--r--lib/Target/PIC16/PIC16MemSelOpt.cpp8
1 files changed, 2 insertions, 6 deletions
diff --git a/lib/Target/PIC16/PIC16MemSelOpt.cpp b/lib/Target/PIC16/PIC16MemSelOpt.cpp
index 93ccdd2491..a97dc35b13 100644
--- a/lib/Target/PIC16/PIC16MemSelOpt.cpp
+++ b/lib/Target/PIC16/PIC16MemSelOpt.cpp
@@ -144,7 +144,7 @@ bool MemSelOpt::processInstruction(MachineInstr *MI) {
}
// Get the section name(NewBank) for MemOp.
- // This assumes that the section names for globals are already set by
+ // This assumes that the section names for globals are laready set by
// AsmPrinter->doInitialization.
std::string NewBank = CurBank;
if (Op.getType() == MachineOperand::MO_GlobalAddress &&
@@ -156,11 +156,7 @@ bool MemSelOpt::processInstruction(MachineInstr *MI) {
std::string Sym = Op.getSymbolName();
NewBank = PAN::getSectionNameForSym(Sym);
}
-
- // If the section is shared section, do not emit banksel.
- if (NewBank == PAN::getSharedUDataSectionName())
- return Changed;
-
+
// If the previous and new section names are same, we don't need to
// emit banksel.
if (NewBank.compare(CurBank) != 0 ) {