mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-25 13:24:46 +00:00
DebugInfo: Gut DIVariable and DIGlobalVariable
Gut all the non-pointer API from the variable wrappers, except an implicit conversion from `DIGlobalVariable` to `DIDescriptor`. Note that if you're updating out-of-tree code, `DIVariable` wraps `MDLocalVariable` (`MDVariable` is a common base class shared with `MDGlobalVariable`). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@234840 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -335,7 +335,7 @@ bool StripDeadDebugInfo::runOnModule(Module &M) {
|
||||
|
||||
// If the global variable referenced by DIG is not null, the global
|
||||
// variable is live.
|
||||
if (DIG.getConstant())
|
||||
if (DIG->getVariable())
|
||||
LiveGlobalVariables.push_back(DIG);
|
||||
else
|
||||
GlobalVariableChange = true;
|
||||
@@ -350,7 +350,7 @@ bool StripDeadDebugInfo::runOnModule(Module &M) {
|
||||
}
|
||||
|
||||
if (GlobalVariableChange) {
|
||||
DIC.replaceGlobalVariables(DIArray(MDNode::get(C, LiveGlobalVariables)));
|
||||
DIC.replaceGlobalVariables(MDTuple::get(C, LiveGlobalVariables));
|
||||
Changed = true;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user