[−][src]Struct solana_rbpf::elf::EBpfElf
Elf loader/relocator
Implementations
impl EBpfElf
[src]
pub fn load(bytes: &[u8]) -> Result<Self, ELFError>
[src]
Fully loads an ELF, including validation and relocation
pub fn get_text_bytes(&self) -> Result<(u64, &[u8]), ELFError>
[src]
Get the .text section virtual address and bytes
pub fn get_ro_sections(&self) -> Result<Vec<(u64, &[u8])>, ELFError>
[src]
Get a vector of virtual addresses for each read-only section
pub fn get_entrypoint_instruction_offset(&self) -> Result<usize, ELFError>
[src]
Get the entry point offset into the text section
pub fn lookup_bpf_call(&self, hash: u32) -> Option<&usize>
[src]
Get a symbol's instruction offset
pub fn report_unresolved_symbol(
&self,
insn_offset: usize
) -> Result<(), ELFError>
[src]
&self,
insn_offset: usize
) -> Result<(), ELFError>
Report information on a symbol that failed to be resolved
pub fn fixup_relative_calls(
calls: &mut HashMap<u32, usize>,
elf_bytes: &mut [u8]
) -> Result<(), ELFError>
[src]
calls: &mut HashMap<u32, usize>,
elf_bytes: &mut [u8]
) -> Result<(), ELFError>
Fix-ups relative calls
pub fn validate(elf: &Elf, elf_bytes: &[u8]) -> Result<(), ELFError>
[src]
Validates the ELF
Trait Implementations
impl Debug for EBpfElf
[src]
impl PartialEq<EBpfElf> for EBpfElf
[src]
impl StructuralPartialEq for EBpfElf
[src]
Auto Trait Implementations
impl RefUnwindSafe for EBpfElf
impl Send for EBpfElf
impl Sync for EBpfElf
impl Unpin for EBpfElf
impl UnwindSafe for EBpfElf
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,