Don't call RegionInlinedFnEnd if our optimization level isn't -O0.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@72024 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Bill Wendling 2009-05-18 18:17:22 +00:00
parent b17e76d34a
commit 15ffc08267

View File

@ -3929,7 +3929,8 @@ SelectionDAGLowering::visitIntrinsicCall(CallInst &I, unsigned Intrinsic) {
MachineFunction &MF = DAG.getMachineFunction();
DISubprogram Subprogram(cast<GlobalVariable>(REI.getContext()));
if (Subprogram.isNull() || Subprogram.describes(MF.getFunction())) {
if (OptLevel == CodeGenOpt::None ||
Subprogram.isNull() || Subprogram.describes(MF.getFunction())) {
unsigned LabelID =
DW->RecordRegionEnd(cast<GlobalVariable>(REI.getContext()));
DAG.setRoot(DAG.getLabel(ISD::DBG_LABEL, getCurDebugLoc(),