aboutsummaryrefslogtreecommitdiff
path: root/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
diff options
context:
space:
mode:
authorBill Wendling <isanbard@gmail.com>2009-02-13 02:01:04 +0000
committerBill Wendling <isanbard@gmail.com>2009-02-13 02:01:04 +0000
commit54fc7d67146b2b95ae2d1c93ed59008d4338d8c8 (patch)
tree6bb0963b8caa315bb7c8928111901d4a93a886c1 /lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
parentbc511725f08c45984be6ff47d069c3773a2f2eb0 (diff)
Turn off the old way of handling debug information in the code generator. Use
the new way, where all of the information is passed on SDNodes and machine instructions. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@64427 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/SelectionDAG/LegalizeDAG.cpp')
-rw-r--r--lib/CodeGen/SelectionDAG/LegalizeDAG.cpp33
1 files changed, 2 insertions, 31 deletions
diff --git a/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp b/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
index e5a30c88be..8cba55fdb0 100644
--- a/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
+++ b/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
@@ -1274,38 +1274,9 @@ SDValue SelectionDAGLegalize::LegalizeOp(SDValue Op) {
switch (TLI.getOperationAction(ISD::DBG_STOPPOINT, MVT::Other)) {
case TargetLowering::Promote:
default: assert(0 && "This action is not supported yet!");
- case TargetLowering::Expand: {
- DwarfWriter *DW = DAG.getDwarfWriter();
- bool useDEBUG_LOC = TLI.isOperationLegalOrCustom(ISD::DEBUG_LOC,
- MVT::Other);
- bool useLABEL = TLI.isOperationLegalOrCustom(ISD::DBG_LABEL, MVT::Other);
-
- const DbgStopPointSDNode *DSP = cast<DbgStopPointSDNode>(Node);
- GlobalVariable *CU_GV = cast<GlobalVariable>(DSP->getCompileUnit());
- if (DW && (useDEBUG_LOC || useLABEL) && !CU_GV->isDeclaration()) {
- DICompileUnit CU(cast<GlobalVariable>(DSP->getCompileUnit()));
- unsigned SrcFile = DW->RecordSource(CU.getDirectory(),
- CU.getFilename());
-
- unsigned Line = DSP->getLine();
- unsigned Col = DSP->getColumn();
-
- // A bit self-referential to have DebugLoc on Debug_Loc nodes, but
- // it won't hurt anything.
- if (useDEBUG_LOC) {
- SDValue Ops[] = { Tmp1, DAG.getConstant(Line, MVT::i32),
- DAG.getConstant(Col, MVT::i32),
- DAG.getConstant(SrcFile, MVT::i32) };
- Result = DAG.getNode(ISD::DEBUG_LOC, dl, MVT::Other, Ops, 4);
- } else {
- unsigned ID = DW->RecordSourceLine(Line, Col, SrcFile);
- Result = DAG.getLabel(ISD::DBG_LABEL, dl, Tmp1, ID);
- }
- } else {
- Result = Tmp1; // chain
- }
+ case TargetLowering::Expand:
+ Result = Tmp1; // chain
break;
- }
case TargetLowering::Legal: {
LegalizeAction Action = getTypeAction(Node->getOperand(1).getValueType());
if (Action == Legal && Tmp1 == Node->getOperand(0))