Public Member Functions | |
register_state ()=default | |
virtual | ~register_state ()=default |
register_state (register_state &&) noexcept=default | |
register_state (const register_state &)=default | |
register_state & | operator= (register_state &&) noexcept=default |
register_state & | operator= (const register_state &)=default |
virtual uint64_t | get_ip () const |
virtual register_state & | set_ip (uint64_t value) |
virtual uint64_t | get (uint64_t index) const |
virtual register_state & | set (uint64_t index, uint64_t value) |
virtual void | commit () |
virtual void | commit (uint64_t cfa) |
virtual void | resume () |
virtual uint64_t | max_num_registers () const |
virtual const char * | name (uint64_t index) const |
virtual void | dump () const |
Register State
Defines the state of the registers. When the unwinder first starts, it will get the state of the registers as its first operation. From that point it will locate the FDE associated with the instruction pointer, and unwind the stack. The process of unwinding the stack is to change the register state stored here, which at a minimum changes the instruction pointer and the stack register (but likely also changes other registers). From there the next FDE is located, and the process repeats until the personality function says when to stop
Once the "catch" block is found, the register state can be used to resume into a new CFA by loading the register state.
Definition at line 43 of file registers.h.
|
default |
Default Constructor
|
virtualdefault |
Destructor
|
defaultnoexcept |
Default Move Constructor
|
default |
Default Copy Constructor
|
defaultnoexcept |
Default Move Assignment Operator
|
default |
Default Copy Assignment Operator
|
inlinevirtual |
Get Instruction Pointer
Reimplemented in register_state_intel_x64.
Definition at line 75 of file registers.h.
|
inlinevirtual |
Set Instruction Pointer
Note: the write is staged and must be committed using the commit function
value | the value to set the instruction pointer to |
Reimplemented in register_state_intel_x64.
Definition at line 86 of file registers.h.
|
inlinevirtual |
Get General Purpose Register
index | the general purpose register to get |
Reimplemented in register_state_intel_x64.
Definition at line 94 of file registers.h.
|
inlinevirtual |
Set General Purpose Register
Note: the write is staged and must be committed using the commit function
index | the general purpose register to set |
value | the value to set the general purpose register to |
Reimplemented in register_state_intel_x64.
Definition at line 106 of file registers.h.
|
inlinevirtual |
Commit
Commits any pending changes to the register state
Reimplemented in register_state_intel_x64.
Definition at line 113 of file registers.h.
|
inlinevirtual |
Commit with CFA
Commits any pending changes to the register state, and saves the provided cfa in the stack register
cfa | the canonical frame address to save to the stack register |
Reimplemented in register_state_intel_x64.
Definition at line 123 of file registers.h.
|
inlinevirtual |
Resume
Restores the register state. Note that this function does not return.
Reimplemented in register_state_intel_x64.
Definition at line 130 of file registers.h.
|
inlinevirtual |
Max Number of Registers
Reimplemented in register_state_intel_x64.
Definition at line 138 of file registers.h.
|
inlinevirtual |
Register Name
index | the index of the register to get the name for |
Reimplemented in register_state_intel_x64.
Definition at line 146 of file registers.h.
|
inlinevirtual |
Dump
Prints the value of each register. Make sure that logging is enabled before using this function
Reimplemented in register_state_intel_x64.
Definition at line 154 of file registers.h.