================
@@ -662,10 +662,12 @@ uint32_t Function::GetPrologueByteSize() {
}
}
- const addr_t func_start_file_addr =
- m_range.GetBaseAddress().GetFileAddress();
- const addr_t func_end_file_addr =
- func_start_file_addr + m_range.GetByteSize();
+ AddressRange entry_range;
+ m_block.GetRangeContainingAddress(m_address, entry_range);
+ const addr_t range_start_file_addr = m_address.GetFileAddress();
+ const addr_t range_end_file_addr =
+ entry_range.GetBaseAddress().GetFileAddress() +
+ entry_range.GetByteSize();
----------------
labath wrote:
Yes, because in the most general case, the entry point may not be at the start
of any particular range (either because of a perverse compiler or because the
linker placed two of the ranges next to each other and we have merged them into
one).
I'm going to add a comment about that.
https://github.com/llvm/llvm-project/pull/131597
_______________________________________________
lldb-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits