Ported to new debug information format introduced in llvm 2.7

This commit is contained in:
Alexey Prokhin 2010-10-30 20:57:32 +04:00
parent 24c92d3a7c
commit d0c7a5a3cb
5 changed files with 113 additions and 426 deletions

View file

@ -864,11 +864,7 @@ void DtoConstInitGlobal(VarDeclaration* vd)
#ifndef DISABLE_DEBUG_INFO
// do debug info
if (global.params.symdebug)
{
LLGlobalVariable* gv = DtoDwarfGlobalVariable(gvar, vd).getGV();
// keep a reference so GDCE doesn't delete it !
gIR->usedArray.push_back(llvm::ConstantExpr::getBitCast(gv, getVoidPtrType()));
}
DtoDwarfGlobalVariable(gvar, vd);
#endif
}
}