[Lldb-commits] [lldb] [lldb] Slide eh_frame unwind plan if it doesn't begin at function boundary (PR #135333)
Pavel Labath via lldb-commits
lldb-commits at lists.llvm.org
Fri Apr 11 02:06:37 PDT 2025
================
@@ -474,7 +474,7 @@ bool UnwindPlan::PlanValidAtAddress(Address addr) const {
// If the 0th Row of unwind instructions is missing, or if it doesn't provide
// a register to use to find the Canonical Frame Address, this is not a valid
// UnwindPlan.
- const Row *row0 = GetRowForFunctionOffset(0);
+ const Row *row0 = GetRowAtIndex(0);
----------------
labath wrote:
This actually changes code back to the state before I started messing with it (#127661). In that patch, I changed it to use `GetRowForFunctionOffset` because I thought it better captures the original intent of the code ("check the value of CFA at function entry").
I still sort of think that, but now I also think that check is too strict (just because we don't have a CFA at offset zero, it doesn't mean we won't have it at some other offset). So this goes back to checking the first row (whatever it's offset), but I'm also open to other options (checking that *any* row contains the CFA, or maybe removing the check entirely -- just checking that *a* row exists)
https://github.com/llvm/llvm-project/pull/135333
More information about the lldb-commits
mailing list