[][src]Struct cranelift_simplejit::SimpleJITBackend

pub struct SimpleJITBackend { /* fields omitted */ }

A SimpleJITBackend implements Backend and emits code and data into memory where it can be directly called and accessed.

See the SimpleJITBuilder for a convenient way to construct SimpleJITBackend instances.

Trait Implementations

impl<'simple_jit_backend> Backend for SimpleJITBackend[src]

type Builder = SimpleJITBuilder

A builder for constructing Backend instances.

type CompiledFunction = SimpleJITCompiledFunction

SimpleJIT compiled function and data objects may have outstanding relocations that need to be performed before the memory can be used. These relocations are performed within finalize_function and finalize_data.

type CompiledData = SimpleJITCompiledData

The results of "compiling" a data object.

type FinalizedFunction = *const u8

SimpleJIT emits code and data into memory, and provides raw pointers to them. They are valid for the remainder of the program's life, unless free_memory is used.

type FinalizedData = (*mut u8, usize)

The completed output artifact for a data object, if this is meaningful for the Backend. Read more

type Product = SimpleJITMemoryHandle

SimpleJIT emits code and data into memory as it processes them, so it doesn't need to provide anything after the Module is complete. The handle object that is returned can optionally be used to free allocated memory if required.

fn new(builder: SimpleJITBuilder) -> Self[src]

Create a new SimpleJITBackend.

fn finish(self) -> Self::Product[src]

SimpleJIT emits code and data into memory as it processes them. This method performs no additional processing, but returns a handle which allows freeing the allocated memory. Otherwise said memory is leaked to enable safe handling of the resulting pointers.

This method does not need to be called when access to the memory handle is not required.

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.