mirror of
https://github.com/wolfpld/tracy
synced 2025-04-30 12:53:51 +00:00
Filter invalid jumps.
This commit is contained in:
parent
ea00efa857
commit
421f0895b7
@ -222,6 +222,9 @@ bool SourceView::Disassemble( uint64_t symAddr, const Worker& worker )
|
||||
break;
|
||||
}
|
||||
if( jumpAddr >= symAddr && jumpAddr < symAddr + len )
|
||||
{
|
||||
auto fit = std::lower_bound( insn, insn+cnt, jumpAddr, []( const auto& l, const auto& r ) { return l.address < r; } );
|
||||
if( fit != insn+cnt && fit->address == jumpAddr )
|
||||
{
|
||||
const auto min = std::min( jumpAddr, op.address );
|
||||
const auto max = std::max( jumpAddr, op.address );
|
||||
@ -238,6 +241,11 @@ bool SourceView::Disassemble( uint64_t symAddr, const Worker& worker )
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
jumpAddr = 0;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
m_jumpOut.emplace( op.address );
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user