Module jit_alloc

Source
Expand description

Abstractions around allocators that provide dual-mapped memory with XOR protection rules (one RW view and one RX view) suitable for emitting code at runtime.

Meant to be an abstraction over the jit-allocator crate’s API so that it can be swapped with user-provided allocators.

See the JitAlloc trait for more information.

Macros§

global_jit_allocglobal_jit_alloc and non-default_jit_alloc
Defines a global JitAlloc implementation which GlobalJitAlloc will defer to.

Structs§

GlobalJitAllocglobal_jit_alloc
The default, global JIT allocator.
JitAllocError
Anonymous error that may be returned by JitAlloc implementations when JitAlloc::alloc or JitAlloc::release fail.
ThreadJitAllocstd and default_jit_alloc
Marker type providing access to a thread-local JIT allocator.

Enums§

ProtectJitAccess
Values to use with JitAlloc::protect_jit_memory.

Traits§

JitAlloc
Generic allocator providing virtual memory suitable for emitting code at runtime.