mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-04-08 09:43:20 +00:00
Simplify.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104302 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
4ef6730632
commit
c0c5a26dea
@ -2145,30 +2145,22 @@ void DwarfDebug::collectVariableInfo(const MachineFunction *MF) {
|
||||
if (Processed.count(DV) != 0)
|
||||
continue;
|
||||
|
||||
if (DV.getTag() == dwarf::DW_TAG_arg_variable) {
|
||||
// FIXME Handle inlined subroutine arguments.
|
||||
DbgVariable *ArgVar = new DbgVariable(DV);
|
||||
CurrentFnDbgScope->addVariable(ArgVar);
|
||||
DbgValueStartMap[MInsn] = ArgVar;
|
||||
DbgVariableToDbgInstMap[ArgVar] = MInsn;
|
||||
Processed.insert(DV);
|
||||
continue;
|
||||
}
|
||||
|
||||
DbgScope *Scope = findDbgScope(MInsn);
|
||||
if (!Scope && DV.getTag() == dwarf::DW_TAG_arg_variable)
|
||||
Scope = CurrentFnDbgScope;
|
||||
// If variable scope is not found then skip this variable.
|
||||
if (Scope == 0)
|
||||
if (!Scope)
|
||||
continue;
|
||||
|
||||
Processed.insert(DV);
|
||||
DbgVariable *AbsDbgVariable = findAbstractVariable(DV, MInsn->getDebugLoc());
|
||||
DbgVariable *RegVar = new DbgVariable(DV);
|
||||
DbgValueStartMap[MInsn] = RegVar;
|
||||
DbgVariableToDbgInstMap[RegVar] = MInsn;
|
||||
Scope->addVariable(RegVar);
|
||||
if (AbsDbgVariable) {
|
||||
DbgVariableToDbgInstMap[AbsDbgVariable] = MInsn;
|
||||
VarToAbstractVarMap[RegVar] = AbsDbgVariable;
|
||||
if (DV.getTag() != dwarf::DW_TAG_arg_variable)
|
||||
DbgValueStartMap[MInsn] = RegVar;
|
||||
if (DbgVariable *AbsVar = findAbstractVariable(DV, MInsn->getDebugLoc())) {
|
||||
DbgVariableToDbgInstMap[AbsVar] = MInsn;
|
||||
VarToAbstractVarMap[RegVar] = AbsVar;
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user