pub struct VcpuSnapshot {
pub id: u32,
pub arch: CpuArch,
pub x86_regs: Option<Registers>,
pub arm64_regs: Option<Arm64Registers>,
pub extra_state: Vec<u8>,
}Expand description
vCPU snapshot state.
Fields§
§id: u32vCPU ID.
arch: CpuArchCPU architecture.
x86_regs: Option<Registers>x86_64 registers (if applicable).
arm64_regs: Option<Arm64Registers>ARM64 registers (if applicable).
extra_state: Vec<u8>Additional architecture-specific state (opaque bytes).
Implementations§
Source§impl VcpuSnapshot
impl VcpuSnapshot
Sourcepub const fn new_arm64(id: u32, regs: Arm64Registers) -> Self
pub const fn new_arm64(id: u32, regs: Arm64Registers) -> Self
Creates a new ARM64 vCPU snapshot.
Sourcepub fn is_placeholder(&self) -> bool
pub fn is_placeholder(&self) -> bool
Returns true if this snapshot contains only default (zeroed) register
state, i.e. it was created as a placeholder and does not represent real
captured vCPU registers.
Trait Implementations§
Source§impl Clone for VcpuSnapshot
impl Clone for VcpuSnapshot
Source§fn clone(&self) -> VcpuSnapshot
fn clone(&self) -> VcpuSnapshot
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for VcpuSnapshot
impl Debug for VcpuSnapshot
Source§impl<'de> Deserialize<'de> for VcpuSnapshot
impl<'de> Deserialize<'de> for VcpuSnapshot
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for VcpuSnapshot
impl RefUnwindSafe for VcpuSnapshot
impl Send for VcpuSnapshot
impl Sync for VcpuSnapshot
impl Unpin for VcpuSnapshot
impl UnsafeUnpin for VcpuSnapshot
impl UnwindSafe for VcpuSnapshot
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more