Struct hermit::x86_64::mm::VirtAddr [−][src]
#[repr(transparent)]pub struct VirtAddr(pub u64);
Expand description
A wrapper for a virtual address.
Implementations
impl VAddr
[src]
impl VAddr
[src]pub const fn from_usize(v: usize) -> VAddr
[src]
pub const fn from_usize(v: usize) -> VAddr
[src]Convert from usize
pub fn as_mut_ptr<T>(self) -> *mut T
[src]
pub fn as_mut_ptr<T>(self) -> *mut T
[src]Convert to mutable pointer.
pub fn base_page_offset(self) -> u64
[src]
pub fn base_page_offset(self) -> u64
[src]Offset within the 4 KiB page.
pub fn large_page_offset(self) -> u64
[src]
pub fn large_page_offset(self) -> u64
[src]Offset within the 2 MiB page.
pub fn huge_page_offset(self) -> u64
[src]
pub fn huge_page_offset(self) -> u64
[src]Offset within the 1 GiB page.
pub fn align_down_to_base_page(self) -> VAddr
[src]
pub fn align_down_to_base_page(self) -> VAddr
[src]Return address of nearest 4 KiB page (lower or equal than self).
pub fn align_down_to_large_page(self) -> VAddr
[src]
pub fn align_down_to_large_page(self) -> VAddr
[src]Return address of nearest 2 MiB page (lower or equal than self).
pub fn align_down_to_huge_page(self) -> VAddr
[src]
pub fn align_down_to_huge_page(self) -> VAddr
[src]Return address of nearest 1 GiB page (lower or equal than self).
pub fn align_up_to_base_page(self) -> VAddr
[src]
pub fn align_up_to_base_page(self) -> VAddr
[src]Return address of nearest 4 KiB page (higher or equal than self).
pub fn align_up_to_large_page(self) -> VAddr
[src]
pub fn align_up_to_large_page(self) -> VAddr
[src]Return address of nearest 2 MiB page (higher or equal than self).
pub fn align_up_to_huge_page(self) -> VAddr
[src]
pub fn align_up_to_huge_page(self) -> VAddr
[src]Return address of nearest 1 GiB page (higher or equal than self).
pub fn is_base_page_aligned(self) -> bool
[src]
pub fn is_base_page_aligned(self) -> bool
[src]Is this address aligned to a 4 KiB page?
pub fn is_large_page_aligned(self) -> bool
[src]
pub fn is_large_page_aligned(self) -> bool
[src]Is this address aligned to a 2 MiB page?
pub fn is_huge_page_aligned(self) -> bool
[src]
pub fn is_huge_page_aligned(self) -> bool
[src]Is this address aligned to a 1 GiB page?
Trait Implementations
impl AddAssign<VAddr> for VAddr
[src]
impl AddAssign<VAddr> for VAddr
[src]pub fn add_assign(&mut self, other: VAddr)
[src]
pub fn add_assign(&mut self, other: VAddr)
[src]Performs the +=
operation. Read more
impl AddAssign<u64> for VAddr
[src]
impl AddAssign<u64> for VAddr
[src]pub fn add_assign(&mut self, offset: u64)
[src]
pub fn add_assign(&mut self, offset: u64)
[src]Performs the +=
operation. Read more
impl AddAssign<usize> for VAddr
[src]
impl AddAssign<usize> for VAddr
[src]pub fn add_assign(&mut self, offset: usize)
[src]
pub fn add_assign(&mut self, offset: usize)
[src]Performs the +=
operation. Read more
impl Ord for VAddr
[src]
impl Ord for VAddr
[src]impl PartialOrd<VAddr> for VAddr
[src]
impl PartialOrd<VAddr> for VAddr
[src]pub fn partial_cmp(&self, other: &VAddr) -> Option<Ordering>
[src]
pub fn partial_cmp(&self, other: &VAddr) -> Option<Ordering>
[src]This method returns an ordering between self
and other
values if one exists. Read more
#[must_use]fn lt(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]fn lt(&self, other: &Rhs) -> bool
1.0.0[src]This method tests less than (for self
and other
) and is used by the <
operator. Read more
#[must_use]fn le(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]fn le(&self, other: &Rhs) -> bool
1.0.0[src]This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
impl Copy for VAddr
[src]
impl Eq for VAddr
[src]
impl StructuralEq for VAddr
[src]
impl StructuralPartialEq for VAddr
[src]
Auto Trait Implementations
impl RefUnwindSafe for VAddr
impl Send for VAddr
impl Sync for VAddr
impl Unpin for VAddr
impl UnwindSafe for VAddr
Blanket Implementations
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]pub fn borrow_mut(&mut self) -> &mut T
[src]
pub fn borrow_mut(&mut self) -> &mut T
[src]Mutably borrows from an owned value. Read more
impl<T> ToOwned for T where
T: Clone,
[src]
impl<T> ToOwned for T where
T: Clone,
[src]type Owned = T
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn to_owned(&self) -> T
[src]Creates owned data from borrowed data, usually by cloning. Read more
pub fn clone_into(&self, target: &mut T)
[src]
pub fn clone_into(&self, target: &mut T)
[src]🔬 This is a nightly-only experimental API. (toowned_clone_into
)
recently added
Uses borrowed data to replace owned data, usually by cloning. Read more