[all-commits] [llvm/llvm-project] fae64a: [lldb] Handle deref of register and implicit locat...
David Peixotto via All-commits
all-commits at lists.llvm.org
Tue Dec 2 11:14:10 PST 2025
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: fae64adaa6a69eafb1c5dca0db82cbc48694e3f2
https://github.com/llvm/llvm-project/commit/fae64adaa6a69eafb1c5dca0db82cbc48694e3f2
Author: David Peixotto <peix at meta.com>
Date: 2025-12-02 (Tue, 02 Dec 2025)
Changed paths:
M lldb/source/Expression/DWARFExpression.cpp
M lldb/unittests/Expression/DWARFExpressionTest.cpp
Log Message:
-----------
[lldb] Handle deref of register and implicit locations (#169419)
This commit modifies the dwarf expression evaluator in how we handle the
deref operation for register and implicit locations on the stack. For a
typical memory location a deref operation will read the value from
memory. For register and implicit locations the deref operation will
read the value from the register or its implicit location. In lldb we
eagerly read register and implicit values and push them on the stack so
the deref operation for these becomes a "no-op" that leaves the value on
the stack and updates the tracked location kind.
The motivation for this change is to handle `DW_OP_deref*` operations on
location descriptions as described by the heterogenious debugging
[extensions](https://rocm.docs.amd.com/projects/llvm-project/en/latest/LLVM/llvm/html/AMDGPUDwarfExtensionsForHeterogeneousDebugging.html#a-2-5-4-4-4-register-location-description-operations).
Specifically, for register locations it states
> These operations obtain a register location. To fetch the contents of
> a register, it is necessary to use DW_OP_regval_type, use one of the
> DW_OP_breg* register-based addressing operations, or use DW_OP_deref*
on
> a register location description.
My understanding is that this is the intended behavior from dwarf5 as
well and is not a change in behavior.
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list