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

llvm-svn: 72024
This commit is contained in:
Bill Wendling 2009-05-18 18:17:22 +00:00
parent ae8a483328
commit 3f41e5ca13

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(),