diff options
author | rdivacky <rdivacky@FreeBSD.org> | 2010-04-03 07:51:10 +0000 |
---|---|---|
committer | rdivacky <rdivacky@FreeBSD.org> | 2010-04-03 07:51:10 +0000 |
commit | 62cc576dca6a6aa62c0424f0a1e93a0a679d4c8a (patch) | |
tree | ba3309de92b14839b2ca6ca0c6d3b39714f95d4c /lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp | |
parent | 20e856b2a58d12231aa42d5d13888b15ac03e5a4 (diff) | |
download | FreeBSD-src-62cc576dca6a6aa62c0424f0a1e93a0a679d4c8a.zip FreeBSD-src-62cc576dca6a6aa62c0424f0a1e93a0a679d4c8a.tar.gz |
Update LLVM to r100285.
Diffstat (limited to 'lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp')
-rw-r--r-- | lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp | 17 |
1 files changed, 7 insertions, 10 deletions
diff --git a/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp b/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp index ea96b21..d54566b 100644 --- a/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp +++ b/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp @@ -368,28 +368,25 @@ bool SelectionDAGISel::runOnMachineFunction(MachineFunction &mf) { /// attached with this instruction. static void SetDebugLoc(Instruction *I, SelectionDAGBuilder *SDB, FastISel *FastIS, MachineFunction *MF) { - MDNode *Dbg = I->getDbgMetadata(); - if (Dbg == 0) return; + DebugLoc DL = I->getDebugLoc(); + if (DL.isUnknown()) return; - DILocation DILoc(Dbg); - DebugLoc Loc = ExtractDebugLocation(DILoc, MF->getDebugLocInfo()); - - SDB->setCurDebugLoc(Loc); + SDB->setCurDebugLoc(DL); if (FastIS) - FastIS->setCurDebugLoc(Loc); + FastIS->setCurDebugLoc(DL); // If the function doesn't have a default debug location yet, set // it. This is kind of a hack. if (MF->getDefaultDebugLoc().isUnknown()) - MF->setDefaultDebugLoc(Loc); + MF->setDefaultDebugLoc(DL); } /// ResetDebugLoc - Set MF's and SDB's DebugLocs to Unknown. static void ResetDebugLoc(SelectionDAGBuilder *SDB, FastISel *FastIS) { - SDB->setCurDebugLoc(DebugLoc::getUnknownLoc()); + SDB->setCurDebugLoc(DebugLoc()); if (FastIS) - FastIS->setCurDebugLoc(DebugLoc::getUnknownLoc()); + FastIS->setCurDebugLoc(DebugLoc()); } void SelectionDAGISel::SelectBasicBlock(BasicBlock *LLVMBB, |