[lldb-dev] [Bug 49941] New: register commands require a frame unconditionally
via lldb-dev
lldb-dev at lists.llvm.org
Mon Apr 12 16:04:34 PDT 2021
https://bugs.llvm.org/show_bug.cgi?id=49941
Bug ID: 49941
Summary: register commands require a frame unconditionally
Product: lldb
Version: unspecified
Hardware: PC
OS: Linux
Status: NEW
Severity: normal
Priority: P
Component: All Bugs
Assignee: lldb-dev at lists.llvm.org
Reporter: llvm at jade.fyi
CC: jdevlieghere at apple.com, llvm-bugs at lists.llvm.org
I've been trying out lldb as a replacement for gdb for working on my operating
system, which I develop on qemu with a gdbstub. Part of this involves debugging
code that is run before the initialization of the stack, in early startup code
and exception handlers.
Here is an example thing that can go wrong:
```
(lldb) register write t0 123
error: invalid frame
```
The `register read` command is also affected by this issue. It appears that the
cause of it is that a bunch of the commands in `CommandObjectRegister.cpp` are
defined as `eCommandRequiresFrame` when they should handle there not being a
frame present with slightly degraded functionality. It's not that they don't
require a frame at all though: `ExecutionContext::GetRegisterContext` needs a
frame to work, but it should be skipped if one is unavailable, which it is not
currently.
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/lldb-dev/attachments/20210412/2381494c/attachment.html>
More information about the lldb-dev
mailing list