diff options
| -rw-r--r-- | lldb/test/lldbutil.py | 24 |
1 files changed, 21 insertions, 3 deletions
diff --git a/lldb/test/lldbutil.py b/lldb/test/lldbutil.py index 114f637b03c..da5ecc3e736 100644 --- a/lldb/test/lldbutil.py +++ b/lldb/test/lldbutil.py @@ -442,20 +442,38 @@ def get_registers(frame, kind): def get_GPRs(frame): """Returns the general purpose registers of the frame as an SBValue. - The returned SBValue object is iterable. + The returned SBValue object is iterable. An example: + ... + from lldbutil import get_GPRs + regs = get_GPRs(frame) + for reg in regs: + print "%s => %s" % (reg.GetName(), reg.GetValue()) + ... """ return get_registers(frame, "general purpose") def get_FPRs(frame): """Returns the floating point registers of the frame as an SBValue. - The returned SBValue object is iterable. + The returned SBValue object is iterable. An example: + ... + from lldbutil import get_FPRs + regs = get_FPRs(frame) + for reg in regs: + print "%s => %s" % (reg.GetName(), reg.GetValue()) + ... """ return get_registers(frame, "floating point") def get_ESRs(frame): """Returns the exception state registers of the frame as an SBValue. - The returned SBValue object is iterable. + The returned SBValue object is iterable. An example: + ... + from lldbutil import get_ESRs + regs = get_ESRs(frame) + for reg in regs: + print "%s => %s" % (reg.GetName(), reg.GetValue()) + ... """ return get_registers(frame, "exception state") |

