[Lldb-commits] [lldb] ce1f01b - [lldb][NFC] Add the UnwindPlan method for the header update

Jason Molenda via lldb-commits lldb-commits at lists.llvm.org
Tue Sep 24 15:43:45 PDT 2024


Author: Jason Molenda
Date: 2024-09-24T15:43:34-07:00
New Revision: ce1f01b887ea5945ec3ffb45e05e674804d5d7a7

URL: https://github.com/llvm/llvm-project/commit/ce1f01b887ea5945ec3ffb45e05e674804d5d7a7
DIFF: https://github.com/llvm/llvm-project/commit/ce1f01b887ea5945ec3ffb45e05e674804d5d7a7.diff

LOG: [lldb][NFC] Add the UnwindPlan method for the header update

In 206408732bca2ef464732a39c8319d47c8a1dbea I updated the
UnwindPlan header to include a new method, but didn't add
the actual implementation.  Fix that.

Added: 
    

Modified: 
    lldb/source/Symbol/UnwindPlan.cpp

Removed: 
    


################################################################################
diff  --git a/lldb/source/Symbol/UnwindPlan.cpp b/lldb/source/Symbol/UnwindPlan.cpp
index b5a9aa2094f54d..a06e7cfd7f5446 100644
--- a/lldb/source/Symbol/UnwindPlan.cpp
+++ b/lldb/source/Symbol/UnwindPlan.cpp
@@ -354,6 +354,17 @@ bool UnwindPlan::Row::SetRegisterLocationToSame(uint32_t reg_num,
   return true;
 }
 
+bool UnwindPlan::Row::SetRegisterLocationToIsDWARFExpression(
+    uint32_t reg_num, const uint8_t *opcodes, uint32_t len, bool can_replace) {
+  if (!can_replace &&
+      m_register_locations.find(reg_num) != m_register_locations.end())
+    return false;
+  AbstractRegisterLocation reg_loc;
+  reg_loc.SetIsDWARFExpression(opcodes, len);
+  m_register_locations[reg_num] = reg_loc;
+  return true;
+}
+
 bool UnwindPlan::Row::SetRegisterLocationToIsConstant(uint32_t reg_num,
                                                       uint64_t constant,
                                                       bool can_replace) {


        


More information about the lldb-commits mailing list