mirror of
https://review.haiku-os.org/haiku
synced 2025-01-31 10:47:14 +01:00
Debugger: Fix program counter handling issue.
- For DWARF4, lowpc/highpc can be specified as constants in addition to addresses. Furthermore, they can also be specified such that highpc is a relative offset from lowpc rather than an absolute address. We weren't handling this case, which gcc4.8 is now using when emitting version 4 debug information. Fixes another part of #10659. There still remains a problem with regards to class/structure variables not showing up in the local variables view.
This commit is contained in:
parent
982b4e9809
commit
3414d0b64d
@ -1,6 +1,6 @@
|
||||
/*
|
||||
* Copyright 2009-2012, Ingo Weinhold, ingo_weinhold@gmx.de.
|
||||
* Copyright 2012-2013, Rene Gollent, rene@gollent.com.
|
||||
* Copyright 2012-2014, Rene Gollent, rene@gollent.com.
|
||||
* Distributed under the terms of the MIT License.
|
||||
*/
|
||||
|
||||
@ -351,8 +351,10 @@ DwarfImageDebugInfo::GetFunctions(const BObjectList<SymbolInfo>& symbols,
|
||||
if (rangeList == NULL) {
|
||||
target_addr_t lowPC = subprogramEntry->LowPC();
|
||||
target_addr_t highPC = subprogramEntry->HighPC();
|
||||
if (lowPC >= highPC)
|
||||
if (lowPC == highPC)
|
||||
continue;
|
||||
else if (highPC < lowPC)
|
||||
highPC += lowPC;
|
||||
|
||||
rangeList = new(std::nothrow) TargetAddressRangeList(
|
||||
TargetAddressRange(lowPC, highPC - lowPC));
|
||||
|
@ -1,6 +1,6 @@
|
||||
/*
|
||||
* Copyright 2009, Ingo Weinhold, ingo_weinhold@gmx.de.
|
||||
* Copyright 2013, Rene Gollent, rene@gollent.com.
|
||||
* Copyright 2013-2014, Rene Gollent, rene@gollent.com.
|
||||
* Distributed under the terms of the MIT License.
|
||||
*/
|
||||
|
||||
@ -49,8 +49,8 @@ static const attribute_name_info_entry kAttributeNameInfos[] = {
|
||||
{ ENTRY(bit_offset), AC_BLOCK | AC_CONSTANT | AC_REFERENCE },
|
||||
{ ENTRY(bit_size), AC_BLOCK | AC_CONSTANT | AC_REFERENCE },
|
||||
{ ENTRY(stmt_list), AC_LINEPTR },
|
||||
{ ENTRY(low_pc), AC_ADDRESS },
|
||||
{ ENTRY(high_pc), AC_ADDRESS },
|
||||
{ ENTRY(low_pc), AC_ADDRESS | AC_CONSTANT | AC_REFERENCE },
|
||||
{ ENTRY(high_pc), AC_ADDRESS | AC_CONSTANT | AC_REFERENCE },
|
||||
{ ENTRY(language), AC_CONSTANT },
|
||||
{ ENTRY(discr), AC_REFERENCE },
|
||||
{ ENTRY(discr_value), AC_CONSTANT },
|
||||
|
Loading…
x
Reference in New Issue
Block a user