pub enum LowLevelILSSARegisterKind<R: ArchReg> {
Full(LowLevelILSSARegister<R>),
Partial {
full_reg: LowLevelILSSARegister<R>,
partial_reg: CoreRegister,
},
}Expand description
The kind of SSA register.
An SSA register can exist in two states:
- Full, e.g.
eaxon x86 - Partial, e.g.
alon x86
If you intend to query for the ssa uses or definitions you must retrieve the physical register
using the function LowLevelILSSARegisterKind::physical_reg which will give you the actual
LowLevelILSSARegister.
Variants§
Full(LowLevelILSSARegister<R>)
A full register is one that is not aliasing another, such as eax on x86 or rax on x86_64.
Partial
Fields
full_reg: LowLevelILSSARegister<R>This is the non-aliased register.
This register is what is used for dataflow, otherwise the backing storage of aliased registers
like al on x86 would contain separate value information from the physical register eax.
NOTE: While this is a LowLevelILSSARegister temporary registers are not allowed in partial
assignments, so this will always be an actual architecture register.
partial_reg: CoreRegisterThis is the aliased register.
On x86 if the register al is used that would be considered a partial register, with the
full register eax being used as the backing storage.
Implementations§
source§impl<R: ArchReg> LowLevelILSSARegisterKind<R>
impl<R: ArchReg> LowLevelILSSARegisterKind<R>
pub fn new_full(kind: LowLevelILRegisterKind<R>, version: u32) -> Self
pub fn new_partial( full_reg: LowLevelILRegisterKind<R>, version: u32, partial_reg: CoreRegister, ) -> Self
sourcepub fn physical_reg(&self) -> LowLevelILSSARegister<R>
pub fn physical_reg(&self) -> LowLevelILSSARegister<R>
This is the non-aliased register used. This should be called when you intend to actually query for SSA dataflow information, as a partial register is prohibited from being used.
§Example
On x86 al in the LLIL SSA will have a physical register of eax.
Trait Implementations§
source§impl<R: ArchReg> AsRef<LowLevelILSSARegister<R>> for LowLevelILSSARegisterKind<R>
impl<R: ArchReg> AsRef<LowLevelILSSARegister<R>> for LowLevelILSSARegisterKind<R>
source§fn as_ref(&self) -> &LowLevelILSSARegister<R>
fn as_ref(&self) -> &LowLevelILSSARegister<R>
source§impl<R: Clone + ArchReg> Clone for LowLevelILSSARegisterKind<R>
impl<R: Clone + ArchReg> Clone for LowLevelILSSARegisterKind<R>
source§fn clone(&self) -> LowLevelILSSARegisterKind<R>
fn clone(&self) -> LowLevelILSSARegisterKind<R>
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more