}
/// createGlobalVariableDIE - create global variable DIE.
-void CompileUnit::createGlobalVariableDIE(const MDNode *N) {
- DIGlobalVariable GV(N);
+void CompileUnit::createGlobalVariableDIE(DIGlobalVariable GV) {
// Check for pre-existence.
if (getDIE(GV))
// it is not a static member.
if (!IsStaticMember)
addConstantValue(VariableDIE, CI, isUnsignedDIType(DD, GTy));
- } else if (const ConstantExpr *CE = getMergedGlobalExpr(N->getOperand(11))) {
+ } else if (const ConstantExpr *CE = getMergedGlobalExpr(GV->getOperand(11))) {
addToAccelTable = true;
// GV is a merged global.
DIEBlock *Block = new (DIEValueAllocator) DIEBlock();
DIE *getOrCreateContextDIE(DIScope Context);
/// createGlobalVariableDIE - create global variable DIE.
- void createGlobalVariableDIE(const MDNode *N);
+ void createGlobalVariableDIE(DIGlobalVariable GV);
/// constructContainingTypeDIEs - Construct DIEs for types that contain
/// vtables.
ScopesWithImportedEntities.end(), less_first());
DIArray GVs = CUNode.getGlobalVariables();
for (unsigned i = 0, e = GVs.getNumElements(); i != e; ++i)
- CU->createGlobalVariableDIE(GVs.getElement(i));
+ CU->createGlobalVariableDIE(DIGlobalVariable(GVs.getElement(i)));
DIArray SPs = CUNode.getSubprograms();
for (unsigned i = 0, e = SPs.getNumElements(); i != e; ++i)
constructSubprogramDIE(CU, SPs.getElement(i));