Allow unimplemented registers to appear in DWARF
The presence of such a register — eg. rcx, which is actually used in CFA on a few lines of libgcc_s.so on my system — will yield an assert(0) in the produced code, but will at least not fail to compile alltogether.
This commit is contained in:
parent
31f811eca4
commit
ff0f8c90df
1 changed files with 23 additions and 18 deletions
|
@ -84,6 +84,7 @@ SimpleDwarf::DwRegister DwarfReader::read_register(
|
|||
{
|
||||
SimpleDwarf::DwRegister output;
|
||||
|
||||
try {
|
||||
switch(reg.k) {
|
||||
case core::FrameSection::register_def::REGISTER:
|
||||
output.type = SimpleDwarf::DwRegister::REG_REGISTER;
|
||||
|
@ -106,6 +107,10 @@ SimpleDwarf::DwRegister DwarfReader::read_register(
|
|||
output.type = SimpleDwarf::DwRegister::REG_NOT_IMPLEMENTED;
|
||||
break;
|
||||
}
|
||||
}
|
||||
catch(const UnsupportedRegister& e) {
|
||||
output.type = SimpleDwarf::DwRegister::REG_NOT_IMPLEMENTED;
|
||||
}
|
||||
|
||||
return output;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue