forked from OSchip/llvm-project
Emit debug info, only if at least one compile unit is seen.
llvm-svn: 62118
This commit is contained in:
parent
6dfeb55897
commit
243b4add9a
|
@ -3596,10 +3596,16 @@ public:
|
||||||
|
|
||||||
/// SetDebugInfo - Create global DIEs and emit initial debug info sections.
|
/// SetDebugInfo - Create global DIEs and emit initial debug info sections.
|
||||||
/// This is inovked by the target AsmPrinter.
|
/// This is inovked by the target AsmPrinter.
|
||||||
void SetDebugInfo() {
|
void SetDebugInfo(MachineModuleInfo *mmi) {
|
||||||
// FIXME - Check if the module has debug info or not.
|
|
||||||
// Create all the compile unit DIEs.
|
// Create all the compile unit DIEs.
|
||||||
ConstructCompileUnits();
|
ConstructCompileUnits();
|
||||||
|
|
||||||
|
if (DW_CUs.empty())
|
||||||
|
return;
|
||||||
|
|
||||||
|
MMI = mmi;
|
||||||
|
shouldEmit = true;
|
||||||
|
|
||||||
// Create DIEs for each of the externally visible global variables.
|
// Create DIEs for each of the externally visible global variables.
|
||||||
ConstructGlobalVariableDIEs();
|
ConstructGlobalVariableDIEs();
|
||||||
|
|
Loading…
Reference in New Issue