mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-02-07 14:33:15 +00:00
Refactor.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137632 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
59bc4093d5
commit
a098c506a2
@ -401,11 +401,8 @@ DIE *DwarfDebug::constructVariableDIE(DbgVariable *DV, LexicalScope *Scope) {
|
||||
VariableCU->addType(VariableDie, DV->getType());
|
||||
}
|
||||
|
||||
if (Tag == dwarf::DW_TAG_formal_parameter && DV->getType().isArtificial())
|
||||
VariableCU->addUInt(VariableDie, dwarf::DW_AT_artificial,
|
||||
dwarf::DW_FORM_flag, 1);
|
||||
else if (DIVariable(DV->getVariable()).isArtificial())
|
||||
VariableCU->addUInt(VariableDie, dwarf::DW_AT_artificial,
|
||||
if (DV->isArtificial())
|
||||
VariableCU->addUInt(VariableDie, dwarf::DW_AT_artificial,
|
||||
dwarf::DW_FORM_flag, 1);
|
||||
|
||||
if (Scope->isAbstractScope()) {
|
||||
|
@ -143,6 +143,15 @@ public:
|
||||
|
||||
return dwarf::DW_TAG_variable;
|
||||
}
|
||||
/// isArtificial - Return true if DbgVariable is artificial.
|
||||
bool isArtificial() const {
|
||||
if (Var.isArtificial())
|
||||
return true;
|
||||
if (Var.getTag() == dwarf::DW_TAG_arg_variable
|
||||
&& getType().isArtificial())
|
||||
return true;
|
||||
return false;
|
||||
}
|
||||
bool variableHasComplexAddress() const {
|
||||
assert(Var.Verify() && "Invalid complex DbgVariable!");
|
||||
return Var.hasComplexAddress();
|
||||
|
Loading…
x
Reference in New Issue
Block a user