diff options
author | Jim Ingham <jingham@apple.com> | 2011-04-16 00:01:13 +0000 |
---|---|---|
committer | Jim Ingham <jingham@apple.com> | 2011-04-16 00:01:13 +0000 |
commit | 78a685aa2d8bbf48f25f2f93d4c0a74652eb0e9b (patch) | |
tree | bccc15a9b0e04bef29c0d2ceeb85a3c355dc9586 /lldb/source/Target/Process.cpp | |
parent | f46b33852c0294f1dba3303c6810902212fe749d (diff) | |
download | bcm5719-llvm-78a685aa2d8bbf48f25f2f93d4c0a74652eb0e9b.tar.gz bcm5719-llvm-78a685aa2d8bbf48f25f2f93d4c0a74652eb0e9b.zip |
Add support for "dynamic values" for C++ classes. This currently only works for "frame var" and for the
expressions that are simple enough to get passed to the "frame var" underpinnings. The parser code will
have to be changed to also query for the dynamic types & offsets as it is looking up variables.
The behavior of "frame var" is controlled in two ways. You can pass "-d {true/false} to the frame var
command to get the dynamic or static value of the variables you are printing.
There's also a general setting:
target.prefer-dynamic-value (boolean) = 'true'
which is consulted if you call "frame var" without supplying a value for the -d option.
llvm-svn: 129623
Diffstat (limited to 'lldb/source/Target/Process.cpp')
-rw-r--r-- | lldb/source/Target/Process.cpp | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/lldb/source/Target/Process.cpp b/lldb/source/Target/Process.cpp index 26d84b968dc..a492e47642d 100644 --- a/lldb/source/Target/Process.cpp +++ b/lldb/source/Target/Process.cpp @@ -1902,6 +1902,12 @@ Process::WriteMemory (addr_t addr, const void *buf, size_t size, Error &error) if (buf == NULL || size == 0) return 0; + + // Need to bump the stop ID after writing so that ValueObjects will know to re-read themselves. + // FUTURE: Doing this should be okay, but if anybody else gets upset about the stop_id changing when + // the target hasn't run, then we will need to add a "memory generation" as well as a stop_id... + m_stop_id++; + // We need to write any data that would go where any current software traps // (enabled software breakpoints) any software traps (breakpoints) that we // may have placed in our tasks memory. @@ -1962,7 +1968,7 @@ Process::WriteMemory (addr_t addr, const void *buf, size_t size, Error &error) ubuf + bytes_written, size - bytes_written, error); - + return bytes_written; } |