diff options
author | Johannes Stoelp <johannes.stoelp@gmail.com> | 2023-12-07 23:00:09 +0100 |
---|---|---|
committer | Johannes Stoelp <johannes.stoelp@gmail.com> | 2023-12-07 23:00:09 +0100 |
commit | f4a9fdb3357ce1a2dfc12cbb0fee6b915bc810c4 (patch) | |
tree | f250376867477ac309d9fed4333224efe2d3969d /examples | |
parent | 647e3646c2f686ce236059b935336c43c8a9a074 (diff) | |
download | juicebox-asm-f4a9fdb3357ce1a2dfc12cbb0fee6b915bc810c4.tar.gz juicebox-asm-f4a9fdb3357ce1a2dfc12cbb0fee6b915bc810c4.zip |
remove prelude
Diffstat (limited to 'examples')
-rw-r--r-- | examples/add.rs | 4 | ||||
-rw-r--r-- | examples/fib.rs | 3 | ||||
-rw-r--r-- | examples/tiny_vm.rs | 3 |
3 files changed, 6 insertions, 4 deletions
diff --git a/examples/add.rs b/examples/add.rs index 6935803..687d205 100644 --- a/examples/add.rs +++ b/examples/add.rs @@ -6,9 +6,9 @@ #[cfg(not(any(target_arch = "x86_64", target_os = "linux")))] compile_error!("Only supported on x86_64 with SystemV abi"); -use juicebox_asm::prelude::*; +use juicebox_asm::insn::*; use juicebox_asm::Runtime; -use Reg64::*; +use juicebox_asm::{Asm, Imm64, Reg64::*}; extern "C" fn add(a: u32, b: u32) -> u32 { a + b diff --git a/examples/fib.rs b/examples/fib.rs index e523b9d..c7505bb 100644 --- a/examples/fib.rs +++ b/examples/fib.rs @@ -3,8 +3,9 @@ //! Jit compile a function at runtime (generate native host code) to compute the fibonacci sequence //! to demonstrate the [`juicebox_asm`] crate. -use juicebox_asm::prelude::*; +use juicebox_asm::insn::*; use juicebox_asm::Runtime; +use juicebox_asm::{Asm, Imm64, Label, Reg64}; const fn fib_rs(n: u64) -> u64 { match n { diff --git a/examples/tiny_vm.rs b/examples/tiny_vm.rs index 51a8d44..bdeb202 100644 --- a/examples/tiny_vm.rs +++ b/examples/tiny_vm.rs @@ -39,8 +39,9 @@ #[cfg(not(any(target_arch = "x86_64", target_os = "linux")))] compile_error!("Only supported on x86_64 with SystemV abi"); -use juicebox_asm::prelude::*; +use juicebox_asm::insn::*; use juicebox_asm::Runtime; +use juicebox_asm::{Asm, Imm16, Imm64, Label, MemOp, Reg16, Reg64}; /// A guest physical address. pub struct PhysAddr(pub u16); |