aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorjohannst <johannst@users.noreply.github.com>2024-12-11 22:02:16 +0000
committerjohannst <johannst@users.noreply.github.com>2024-12-11 22:02:16 +0000
commit741d915aed07eb4ea265d8e90cf64e8ca6552ddc (patch)
treec88fa3add489da750a152dd0817ddedf26bf0379
parent9ebb4b9d82decbd9e8ea901e6d240e1af9f190b3 (diff)
downloadjuicebox-asm-741d915aed07eb4ea265d8e90cf64e8ca6552ddc.tar.gz
juicebox-asm-741d915aed07eb4ea265d8e90cf64e8ca6552ddc.zip
deploy: a403a7255190f65ea73ccaf382ec7af1a98b94ad
-rw-r--r--crates.js4
-rw-r--r--gen/all.html1
-rw-r--r--gen/index.html4
-rw-r--r--gen/sidebar-items.js1
-rw-r--r--search-index.js4
-rw-r--r--search.desc/gen/gen-desc-0-.js1
-rw-r--r--src-files.js4
-rw-r--r--src/gen/gen.rs.html91
8 files changed, 6 insertions, 104 deletions
diff --git a/crates.js b/crates.js
index 11e0064..63a44e3 100644
--- a/crates.js
+++ b/crates.js
@@ -1,2 +1,2 @@
-window.ALL_CRATES = ["add","bf","fib","gen","juicebox_asm","tiny_vm"];
-//{"start":21,"fragment_lengths":[5,5,6,6,15,10]} \ No newline at end of file
+window.ALL_CRATES = ["add","bf","fib","juicebox_asm","tiny_vm"];
+//{"start":21,"fragment_lengths":[5,5,6,15,10]} \ No newline at end of file
diff --git a/gen/all.html b/gen/all.html
deleted file mode 100644
index 1e0c258..0000000
--- a/gen/all.html
+++ /dev/null
@@ -1 +0,0 @@
-<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><meta name="generator" content="rustdoc"><meta name="description" content="List of all items in this crate"><title>List of all items in this crate</title><script>if(window.location.protocol!=="file:")document.head.insertAdjacentHTML("beforeend","SourceSerif4-Regular-46f98efaafac5295.ttf.woff2,FiraSans-Regular-018c141bf0843ffd.woff2,FiraSans-Medium-8f9a781e4970d388.woff2,SourceCodePro-Regular-562dcc5011b6de7d.ttf.woff2,SourceCodePro-Semibold-d899c5a5c4aeb14a.ttf.woff2".split(",").map(f=>`<link rel="preload" as="font" type="font/woff2" crossorigin href="../static.files/${f}">`).join(""))</script><link rel="stylesheet" href="../static.files/normalize-76eba96aa4d2e634.css"><link rel="stylesheet" href="../static.files/rustdoc-b0742ba02757f159.css"><meta name="rustdoc-vars" data-root-path="../" data-static-root-path="../static.files/" data-current-crate="gen" data-themes="" data-resource-suffix="" data-rustdoc-version="1.83.0 (90b35a623 2024-11-26)" data-channel="1.83.0" data-search-js="search-f0d225181b97f9a4.js" data-settings-js="settings-805db61a62df4bd2.js" ><script src="../static.files/storage-1d39b6787ed640ff.js"></script><script defer src="../static.files/main-f070b9041d14864c.js"></script><noscript><link rel="stylesheet" href="../static.files/noscript-0111fcff984fae8f.css"></noscript><link rel="alternate icon" type="image/png" href="../static.files/favicon-32x32-422f7d1d52889060.png"><link rel="icon" type="image/svg+xml" href="../static.files/favicon-2c020d218678b618.svg"></head><body class="rustdoc mod sys"><!--[if lte IE 11]><div class="warning">This old browser is unsupported and will most likely display funky things.</div><![endif]--><nav class="mobile-topbar"><button class="sidebar-menu-toggle" title="show sidebar"></button></nav><nav class="sidebar"><div class="sidebar-crate"><h2><a href="../gen/index.html">gen</a><span class="version">0.1.0</span></h2></div><div class="sidebar-elems"><div id="rustdoc-modnav"></div></div></nav><div class="sidebar-resizer"></div><main><div class="width-limiter"><rustdoc-search></rustdoc-search><section id="main-content" class="content"><h1>List of all items</h1></section></div></main></body></html> \ No newline at end of file
diff --git a/gen/index.html b/gen/index.html
deleted file mode 100644
index df51ecc..0000000
--- a/gen/index.html
+++ /dev/null
@@ -1,4 +0,0 @@
-<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><meta name="generator" content="rustdoc"><meta name="description" content="Add example."><title>gen - Rust</title><script>if(window.location.protocol!=="file:")document.head.insertAdjacentHTML("beforeend","SourceSerif4-Regular-46f98efaafac5295.ttf.woff2,FiraSans-Regular-018c141bf0843ffd.woff2,FiraSans-Medium-8f9a781e4970d388.woff2,SourceCodePro-Regular-562dcc5011b6de7d.ttf.woff2,SourceCodePro-Semibold-d899c5a5c4aeb14a.ttf.woff2".split(",").map(f=>`<link rel="preload" as="font" type="font/woff2" crossorigin href="../static.files/${f}">`).join(""))</script><link rel="stylesheet" href="../static.files/normalize-76eba96aa4d2e634.css"><link rel="stylesheet" href="../static.files/rustdoc-b0742ba02757f159.css"><meta name="rustdoc-vars" data-root-path="../" data-static-root-path="../static.files/" data-current-crate="gen" data-themes="" data-resource-suffix="" data-rustdoc-version="1.83.0 (90b35a623 2024-11-26)" data-channel="1.83.0" data-search-js="search-f0d225181b97f9a4.js" data-settings-js="settings-805db61a62df4bd2.js" ><script src="../static.files/storage-1d39b6787ed640ff.js"></script><script defer src="../crates.js"></script><script defer src="../static.files/main-f070b9041d14864c.js"></script><noscript><link rel="stylesheet" href="../static.files/noscript-0111fcff984fae8f.css"></noscript><link rel="alternate icon" type="image/png" href="../static.files/favicon-32x32-422f7d1d52889060.png"><link rel="icon" type="image/svg+xml" href="../static.files/favicon-2c020d218678b618.svg"></head><body class="rustdoc mod crate"><!--[if lte IE 11]><div class="warning">This old browser is unsupported and will most likely display funky things.</div><![endif]--><nav class="mobile-topbar"><button class="sidebar-menu-toggle" title="show sidebar"></button></nav><nav class="sidebar"><div class="sidebar-crate"><h2><a href="../gen/index.html">gen</a><span class="version">0.1.0</span></h2></div><div class="sidebar-elems"><ul class="block"><li><a id="all-types" href="all.html">All Items</a></li></ul><div id="rustdoc-modnav"></div></div></nav><div class="sidebar-resizer"></div><main><div class="width-limiter"><rustdoc-search></rustdoc-search><section id="main-content" class="content"><div class="main-heading"><h1>Crate <span>gen</span><button id="copy-path" title="Copy item path to clipboard">Copy item path</button></h1><rustdoc-toolbar></rustdoc-toolbar><span class="sub-heading"><a class="src" href="../src/gen/gen.rs.html#1-45">source</a> </span></div><details class="toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>Add example.</p>
-<p>Jit compile a function at runtime (generate native host code) which calls a function defined in
-the example based on the SystemV abi to demonstrate the <a href="../juicebox_asm/index.html" title="mod juicebox_asm"><code>juicebox_asm</code></a> crate.</p>
-</div></details></section></div></main></body></html> \ No newline at end of file
diff --git a/gen/sidebar-items.js b/gen/sidebar-items.js
deleted file mode 100644
index 5244ce0..0000000
--- a/gen/sidebar-items.js
+++ /dev/null
@@ -1 +0,0 @@
-window.SIDEBAR_ITEMS = {}; \ No newline at end of file
diff --git a/search-index.js b/search-index.js
index 618b125..1c0986a 100644
--- a/search-index.js
+++ b/search-index.js
@@ -1,4 +1,4 @@
-var searchIndex = new Map(JSON.parse('[["add",{"t":"","n":[],"q":[],"i":"","f":"","D":"b","p":[],"r":[],"b":[],"c":"OjAAAAAAAAA=","e":"OjAAAAAAAAA="}],["bf",{"t":"","n":[],"q":[],"i":"","f":"","D":"b","p":[],"r":[],"b":[],"c":"OjAAAAAAAAA=","e":"OjAAAAAAAAA="}],["fib",{"t":"","n":[],"q":[],"i":"","f":"","D":"b","p":[],"r":[],"b":[],"c":"OjAAAAAAAAA=","e":"OjAAAAAAAAA="}],["gen",{"t":"","n":[],"q":[],"i":"","f":"","D":"b","p":[],"r":[],"b":[],"c":"OjAAAAAAAAA=","e":"OjAAAAAAAAA="}],["juicebox_asm",{"t":"FFFFFPPPFGFFFFGGGGFNNNNNNNNPPPPNPNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNPPPNPPNNNNNNNNNNNNNNNNNNNPNNNNNNPPPPNNNPPPPPPPPPNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNCNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPNPPPPPPNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNKKKKKKKKKKKKKKKKMMMMMMMMMMMMMMMM","n":["Asm","Imm16","Imm32","Imm64","Imm8","Indirect","IndirectBaseIndex","IndirectDisp","Label","MemOp","MemOp16","MemOp32","MemOp64","MemOp8","Reg16","Reg32","Reg64","Reg8","Runtime","add","","","","","","","add_code","ah","al","ax","bh","bind","bl","borrow","","","","","","","","","","","","","","","","borrow_mut","","","","","","","","","","","","","","","","bp","bpl","bx","call","ch","cl","clone","","","","","clone_into","","","","","clone_to_uninit","","","","","cmovnz","cmovz","cmp","","cx","dec","","","","","","dh","di","dil","dl","drop","","dump","dx","eax","ebp","ebx","ecx","edi","edx","esi","esp","from","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","inc","","","","","","insn","into","","","","","","","","","","","","","","","","into_code","jmp","jnz","jz","mov","","","","","","","","","","","","","","","","","new","","","nop","pop","","push","","r10","r10d","r10l","r10w","r11","r11d","r11l","r11w","r12","r12d","r12l","r12w","r13","r13d","r13l","r13w","r14","r14d","r14l","r14w","r15","r15d","r15l","r15w","r8","r8d","r8l","r8w","r9","r9d","r9l","r9w","rax","rbp","rbx","rcx","rdi","rdx","ret","rsi","rsp","si","sil","sp","spl","sub","","test","","","to_owned","","","","","try_from","","","","","","","","","","","","","","","","try_into","","","","","","","","","","","","","","","","type_id","","","","","","","","","","","","","","","","with_profile","xor","Add","Call","Cmovnz","Cmovz","Cmp","Dec","Inc","Jmp","Jnz","Jz","Mov","Pop","Push","Sub","Test","Xor","add","call","cmovnz","cmovz","cmp","dec","inc","jmp","jnz","jz","mov","pop","push","sub","test","xor"],"q":[[0,"juicebox_asm"],[312,"juicebox_asm::insn"],[344,"juicebox_asm::asm"],[345,"juicebox_asm::reg"],[346,"juicebox_asm::imm"],[347,"juicebox_asm::rt"],[348,"core::convert"],[349,"juicebox_asm::label"],[350,"alloc::vec"],[351,"core::result"],[352,"core::any"]],"i":"`````l00```````````d000000AfB`0Ab1313An3A`nC`CfhAd78;BhBdBfBb>:=987654;<?3210;<;><<54;<?54;<?54;<?>>>>;>>>>>><;<<:==;44444444>:=9998888877777776666666666654;<?33221100>>>>>>`>:=987654;<?3210>>>>>>>>>>>>>>>>>>>>>>:=>>>>>54<;54<;54<;54<;54<;54<;54<;54<;555555>55;<;<>>>>>54;<?>:=987654;<?3210>:=987654;<?3210>:=987654;<?3210=>````````````````DfDhDjDlDnE`EbEdEfEhEjElEnF`FbFd","f":"```````````````````{{{f{bd}}hh}j}{{{f{bd}}hl}j}{{{f{bd}}ln}j}{{{f{bd}}lA`}j}{{{f{bd}}lAb}j}{{{f{bd}}lh}j}{{{f{bd}}AdAd}j}{{{f{bAf}}c}e{{Al{{Aj{Ah}}}}}{}}````{{{f{bd}}{f{bAn}}}j}`{f{{f{c}}}{}}000000000000000{{{f{b}}}{{f{bc}}}{}}000000000000000```{{{f{bd}}h}j}``{{{f{h}}}h}{{{f{Ad}}}Ad}{{{f{Ab}}}Ab}{{{f{B`}}}B`}{{{f{l}}}l}{{f{f{bc}}}j{}}0000{fj}0000{{{f{bd}}hh}j}0{{{f{bd}}ln}j}{{{f{bd}}lA`}j}`{{{f{bd}}Ad}j};{{{f{bd}}Bb}j}{{{f{bd}}Bd}j}{{{f{bd}}Bf}j}{{{f{bd}}Bh}j}````{{{f{bAn}}}j}{{{f{bAf}}}j}{{{f{Af}}}j}`````````{cc{}}000{AhA`}{BjA`}{Ahn}3{Bjn}{Bln}{Bnn}6{BjC`}{AhC`}{BnC`}{BlC`}{CbC`}{CdC`}{AhCf}{ChCf}>{CjCf}{ClCf}{BjCf}{BnCf}{BlCf}{CbCf}{CdCf}{CnCf}{cc{}}00000{lBh}{lBd}2{lBf}3{lBb}4{{{f{bd}}Bb}j}{{{f{bd}}h}j}{{{f{bd}}Ad}j}{{{f{bd}}Bh}j}{{{f{bd}}Bd}j}{{{f{bd}}Bf}j}`{{}c{}}000000000000000{d{{D`{Ah}}}}{{{f{bd}}{f{bAn}}}j}00{{{f{bd}}lAd}j}{{{f{bd}}Abl}j}{{{f{bd}}Adl}j}{{{f{bd}}hl}j}{{{f{bd}}lB`}j}{{{f{bd}}lAb}j}{{{f{bd}}Abn}j}{{{f{bd}}B`A`}j}{{{f{bd}}B`l}j}{{{f{bd}}lh}j}{{{f{bd}}B`B`}j}{{{f{bd}}AbAb}j}{{{f{bd}}AdAd}j}{{{f{bd}}hh}j}{{{f{bd}}hCf}j}{{{f{bd}}ln}j}{{{f{bd}}AdC`}j}{{}d}{{}An}{{}Af}{{{f{bd}}}j}{{{f{bd}}h}j}{{{f{bd}}Ab}j}01``````````````````````````````````````2``````9{{{f{bd}}lA`}j}8;:{fc{}}0000{c{{Db{e}}}{}{}}000000000000000{{}{{Db{c}}}{}}000000000000000{fDd}0000000000000008>````````````````{{{f{bDf}}ce}j{}{}}{{{f{bDh}}c}j{}}{{{f{bDj}}ce}j{}{}}{{{f{bDl}}ce}j{}{}}{{{f{bDn}}ce}j{}{}}{{{f{bE`}}c}j{}}{{{f{bEb}}c}j{}}{{{f{bEd}}c}j{}}{{{f{bEf}}c}j{}}{{{f{bEh}}c}j{}}{{{f{bEj}}ce}j{}{}}{{{f{bEl}}c}j{}}{{{f{bEn}}c}j{}}{{{f{bF`}}ce}j{}{}}{{{f{bFb}}ce}j{}{}}{{{f{bFd}}ce}j{}{}}","D":"Lh","p":[[0,"mut"],[5,"Asm",0,344],[1,"reference"],[6,"Reg64",0,345],[1,"unit"],[6,"MemOp",0],[5,"Imm16",0,346],[5,"Imm8",0,346],[6,"Reg16",0,345],[6,"Reg32",0,345],[5,"Runtime",0,347],[1,"u8"],[1,"slice"],[10,"AsRef",348],[5,"Label",0,349],[6,"Reg8",0,345],[5,"MemOp64",0],[5,"MemOp16",0],[5,"MemOp32",0],[5,"MemOp8",0],[1,"i8"],[1,"u16"],[1,"i16"],[5,"Imm32",0,346],[1,"i32"],[1,"u32"],[5,"Imm64",0,346],[1,"i64"],[1,"isize"],[1,"usize"],[1,"u64"],[5,"Vec",350],[6,"Result",351],[5,"TypeId",352],[10,"Add",312],[10,"Call",312],[10,"Cmovnz",312],[10,"Cmovz",312],[10,"Cmp",312],[10,"Dec",312],[10,"Inc",312],[10,"Jmp",312],[10,"Jnz",312],[10,"Jz",312],[10,"Mov",312],[10,"Pop",312],[10,"Push",312],[10,"Sub",312],[10,"Test",312],[10,"Xor",312]],"r":[[0,344],[1,346],[2,346],[3,346],[4,346],[8,349],[14,345],[15,345],[16,345],[17,345],[18,347]],"b":[[19,"impl-Add%3CReg64,+Reg64%3E-for-Asm"],[20,"impl-Add%3CReg64,+MemOp%3E-for-Asm"],[21,"impl-Add%3CMemOp,+Imm16%3E-for-Asm"],[22,"impl-Add%3CMemOp,+Imm8%3E-for-Asm"],[23,"impl-Add%3CMemOp,+Reg16%3E-for-Asm"],[24,"impl-Add%3CMemOp,+Reg64%3E-for-Asm"],[25,"impl-Add%3CReg32,+Reg32%3E-for-Asm"],[88,"impl-Cmp%3CMemOp,+Imm16%3E-for-Asm"],[89,"impl-Cmp%3CMemOp,+Imm8%3E-for-Asm"],[91,"impl-Dec%3CReg32%3E-for-Asm"],[92,"impl-Dec%3CReg64%3E-for-Asm"],[93,"impl-Dec%3CMemOp64%3E-for-Asm"],[94,"impl-Dec%3CMemOp16%3E-for-Asm"],[95,"impl-Dec%3CMemOp32%3E-for-Asm"],[96,"impl-Dec%3CMemOp8%3E-for-Asm"],[117,"impl-From%3Cu8%3E-for-Imm8"],[118,"impl-From%3Ci8%3E-for-Imm8"],[119,"impl-From%3Cu8%3E-for-Imm16"],[121,"impl-From%3Ci8%3E-for-Imm16"],[122,"impl-From%3Cu16%3E-for-Imm16"],[123,"impl-From%3Ci16%3E-for-Imm16"],[125,"impl-From%3Ci8%3E-for-Imm32"],[126,"impl-From%3Cu8%3E-for-Imm32"],[127,"impl-From%3Ci16%3E-for-Imm32"],[128,"impl-From%3Cu16%3E-for-Imm32"],[129,"impl-From%3Ci32%3E-for-Imm32"],[130,"impl-From%3Cu32%3E-for-Imm32"],[131,"impl-From%3Cu8%3E-for-Imm64"],[132,"impl-From%3Ci64%3E-for-Imm64"],[134,"impl-From%3Cisize%3E-for-Imm64"],[135,"impl-From%3Cusize%3E-for-Imm64"],[136,"impl-From%3Ci8%3E-for-Imm64"],[137,"impl-From%3Ci16%3E-for-Imm64"],[138,"impl-From%3Cu16%3E-for-Imm64"],[139,"impl-From%3Ci32%3E-for-Imm64"],[140,"impl-From%3Cu32%3E-for-Imm64"],[141,"impl-From%3Cu64%3E-for-Imm64"],[155,"impl-Inc%3CMemOp64%3E-for-Asm"],[156,"impl-Inc%3CReg64%3E-for-Asm"],[157,"impl-Inc%3CReg32%3E-for-Asm"],[158,"impl-Inc%3CMemOp8%3E-for-Asm"],[159,"impl-Inc%3CMemOp16%3E-for-Asm"],[160,"impl-Inc%3CMemOp32%3E-for-Asm"],[182,"impl-Mov%3CMemOp,+Reg32%3E-for-Asm"],[183,"impl-Mov%3CReg16,+MemOp%3E-for-Asm"],[184,"impl-Mov%3CReg32,+MemOp%3E-for-Asm"],[185,"impl-Mov%3CReg64,+MemOp%3E-for-Asm"],[186,"impl-Mov%3CMemOp,+Reg8%3E-for-Asm"],[187,"impl-Mov%3CMemOp,+Reg16%3E-for-Asm"],[188,"impl-Mov%3CReg16,+Imm16%3E-for-Asm"],[189,"impl-Mov%3CReg8,+Imm8%3E-for-Asm"],[190,"impl-Mov%3CReg8,+MemOp%3E-for-Asm"],[191,"impl-Mov%3CMemOp,+Reg64%3E-for-Asm"],[192,"impl-Mov%3CReg8,+Reg8%3E-for-Asm"],[193,"impl-Mov%3CReg16,+Reg16%3E-for-Asm"],[194,"impl-Mov%3CReg32,+Reg32%3E-for-Asm"],[195,"impl-Mov%3CReg64,+Reg64%3E-for-Asm"],[196,"impl-Mov%3CReg64,+Imm64%3E-for-Asm"],[197,"impl-Mov%3CMemOp,+Imm16%3E-for-Asm"],[198,"impl-Mov%3CReg32,+Imm32%3E-for-Asm"],[203,"impl-Pop%3CReg64%3E-for-Asm"],[204,"impl-Pop%3CReg16%3E-for-Asm"],[205,"impl-Push%3CReg16%3E-for-Asm"],[206,"impl-Push%3CReg64%3E-for-Asm"],[252,"impl-Sub%3CReg64,+Reg64%3E-for-Asm"],[253,"impl-Sub%3CMemOp,+Imm8%3E-for-Asm"],[254,"impl-Test%3CMemOp,+Imm16%3E-for-Asm"],[255,"impl-Test%3CReg32,+Reg32%3E-for-Asm"],[256,"impl-Test%3CReg64,+Reg64%3E-for-Asm"]],"c":"OjAAAAAAAAA=","e":"OzAAAAEAAPQADQAUAAYAHAADACEARQBpAAgAdgACAHoAAgB+AAcAhwAHAJwABQC0ABMAzAApAPcAPwA4AQAA"}],["tiny_vm",{"t":"PPPPPPPFPPPFPGGFNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNHHHNNNNNNNNNNNNNNNNNNNNNNN","n":["A","Add","Addi","B","Branch","BranchZero","C","Fixup","Halt","Load","LoadImm","PhysAddr","Store","TinyInsn","TinyReg","TinyVm","bind","borrow","","","","","borrow_mut","","","","","clone","","clone_into","","clone_to_uninit","","dump","eq","","fmt","","from","","","","","interp","into","","","","","","jit","make_tinyvm_fib","make_tinyvm_jit_perf","make_tinyvm_jit_test","new","","read_mem","read_reg","to_owned","","try_from","","","","","try_into","","","","","type_id","","","","","write_mem","write_reg"],"q":[[0,"tiny_vm"],[77,"alloc::vec"],[78,"core::fmt"],[79,"core::result"],[80,"core::any"]],"i":"nf01001`000`0```bAhA`24310243434343043431024301102430```02004310243102431024300","f":"````````````````{{b{j{d{h{f}}}}}l}{j{{j{c}}}{}}0000{{{j{d}}}{{j{dc}}}{}}0000{{{j{n}}}n}{{{j{f}}}f}{{j{j{dc}}}l{}}0{jl}0{{{j{A`}}}l}{{{j{n}}{j{n}}}Ab}{{{j{f}}{j{f}}}Ab}{{{j{n}}{j{dAd}}}Af}{{{j{f}}{j{dAd}}}Af}{cc{}}0000{{{j{dA`}}}l}{AhAj}{{}c{}}00002{Al{{h{f}}}}{{}{{h{f}}}}0{{{h{f}}}A`}{Ajb}{{{j{A`}}Ah}Al}{{{j{A`}}n}Al}{jc{}}0{c{{An{e}}}{}{}}0000{{}{{An{c}}}{}}0000{jB`}0000{{{j{dA`}}AhAl}l}{{{j{dA`}}nAl}l}","D":"Dj","p":[[5,"Fixup",0],[0,"mut"],[6,"TinyInsn",0],[5,"Vec",77],[1,"reference"],[1,"unit"],[6,"TinyReg",0],[5,"TinyVm",0],[1,"bool"],[5,"Formatter",78],[8,"Result",78],[5,"PhysAddr",0],[1,"usize"],[1,"u16"],[6,"Result",79],[5,"TypeId",80]],"r":[],"b":[],"c":"OjAAAAAAAAA=","e":"OzAAAAEAACgABwABAAAABAAAAAcAAAASAA8AIwADAC0AAAA7ABAA"}]]'));
+var searchIndex = new Map(JSON.parse('[["add",{"t":"","n":[],"q":[],"i":"","f":"","D":"b","p":[],"r":[],"b":[],"c":"OjAAAAAAAAA=","e":"OjAAAAAAAAA="}],["bf",{"t":"","n":[],"q":[],"i":"","f":"","D":"b","p":[],"r":[],"b":[],"c":"OjAAAAAAAAA=","e":"OjAAAAAAAAA="}],["fib",{"t":"","n":[],"q":[],"i":"","f":"","D":"b","p":[],"r":[],"b":[],"c":"OjAAAAAAAAA=","e":"OjAAAAAAAAA="}],["juicebox_asm",{"t":"FFFFFPPPFGFFFFGGGGFNNNNNNNNPPPPNPNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNPPPNPPNNNNNNNNNNNNNNNNNNNPNNNNNNPPPPNNNPPPPPPPPPNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNCNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPNPPPPPPNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNKKKKKKKKKKKKKKKKMMMMMMMMMMMMMMMM","n":["Asm","Imm16","Imm32","Imm64","Imm8","Indirect","IndirectBaseIndex","IndirectDisp","Label","MemOp","MemOp16","MemOp32","MemOp64","MemOp8","Reg16","Reg32","Reg64","Reg8","Runtime","add","","","","","","","add_code","ah","al","ax","bh","bind","bl","borrow","","","","","","","","","","","","","","","","borrow_mut","","","","","","","","","","","","","","","","bp","bpl","bx","call","ch","cl","clone","","","","","clone_into","","","","","clone_to_uninit","","","","","cmovnz","cmovz","cmp","","cx","dec","","","","","","dh","di","dil","dl","drop","","dump","dx","eax","ebp","ebx","ecx","edi","edx","esi","esp","from","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","inc","","","","","","insn","into","","","","","","","","","","","","","","","","into_code","jmp","jnz","jz","mov","","","","","","","","","","","","","","","","","new","","","nop","pop","","push","","r10","r10d","r10l","r10w","r11","r11d","r11l","r11w","r12","r12d","r12l","r12w","r13","r13d","r13l","r13w","r14","r14d","r14l","r14w","r15","r15d","r15l","r15w","r8","r8d","r8l","r8w","r9","r9d","r9l","r9w","rax","rbp","rbx","rcx","rdi","rdx","ret","rsi","rsp","si","sil","sp","spl","sub","","test","","","to_owned","","","","","try_from","","","","","","","","","","","","","","","","try_into","","","","","","","","","","","","","","","","type_id","","","","","","","","","","","","","","","","with_profile","xor","Add","Call","Cmovnz","Cmovz","Cmp","Dec","Inc","Jmp","Jnz","Jz","Mov","Pop","Push","Sub","Test","Xor","add","call","cmovnz","cmovz","cmp","dec","inc","jmp","jnz","jz","mov","pop","push","sub","test","xor"],"q":[[0,"juicebox_asm"],[312,"juicebox_asm::insn"],[344,"juicebox_asm::asm"],[345,"juicebox_asm::reg"],[346,"juicebox_asm::imm"],[347,"juicebox_asm::rt"],[348,"core::convert"],[349,"juicebox_asm::label"],[350,"alloc::vec"],[351,"core::result"],[352,"core::any"]],"i":"`````l00```````````d000000AfB`0Ab1313An3A`nC`CfhAd78;BhBdBfBb>:=987654;<?3210;<;><<54;<?54;<?54;<?>>>>;>>>>>><;<<:==;44444444>:=9998888877777776666666666654;<?33221100>>>>>>`>:=987654;<?3210>>>>>>>>>>>>>>>>>>>>>>:=>>>>>54<;54<;54<;54<;54<;54<;54<;54<;555555>55;<;<>>>>>54;<?>:=987654;<?3210>:=987654;<?3210>:=987654;<?3210=>````````````````DfDhDjDlDnE`EbEdEfEhEjElEnF`FbFd","f":"```````````````````{{{f{bd}}hh}j}{{{f{bd}}hl}j}{{{f{bd}}ln}j}{{{f{bd}}lA`}j}{{{f{bd}}lAb}j}{{{f{bd}}lh}j}{{{f{bd}}AdAd}j}{{{f{bAf}}c}e{{Al{{Aj{Ah}}}}}{}}````{{{f{bd}}{f{bAn}}}j}`{f{{f{c}}}{}}000000000000000{{{f{b}}}{{f{bc}}}{}}000000000000000```{{{f{bd}}h}j}``{{{f{h}}}h}{{{f{Ad}}}Ad}{{{f{Ab}}}Ab}{{{f{B`}}}B`}{{{f{l}}}l}{{f{f{bc}}}j{}}0000{fj}0000{{{f{bd}}hh}j}0{{{f{bd}}ln}j}{{{f{bd}}lA`}j}`{{{f{bd}}Ad}j};{{{f{bd}}Bb}j}{{{f{bd}}Bd}j}{{{f{bd}}Bf}j}{{{f{bd}}Bh}j}````{{{f{bAn}}}j}{{{f{bAf}}}j}{{{f{Af}}}j}`````````{cc{}}000{AhA`}{BjA`}{Ahn}3{Bjn}{Bln}{Bnn}6{BjC`}{AhC`}{BnC`}{BlC`}{CbC`}{CdC`}{AhCf}{ChCf}>{CjCf}{ClCf}{BjCf}{BnCf}{BlCf}{CbCf}{CdCf}{CnCf}{cc{}}00000{lBh}{lBd}2{lBf}3{lBb}4{{{f{bd}}Bb}j}{{{f{bd}}h}j}{{{f{bd}}Ad}j}{{{f{bd}}Bh}j}{{{f{bd}}Bd}j}{{{f{bd}}Bf}j}`{{}c{}}000000000000000{d{{D`{Ah}}}}{{{f{bd}}{f{bAn}}}j}00{{{f{bd}}lAd}j}{{{f{bd}}Abl}j}{{{f{bd}}Adl}j}{{{f{bd}}hl}j}{{{f{bd}}lB`}j}{{{f{bd}}lAb}j}{{{f{bd}}Abn}j}{{{f{bd}}B`A`}j}{{{f{bd}}B`l}j}{{{f{bd}}lh}j}{{{f{bd}}B`B`}j}{{{f{bd}}AbAb}j}{{{f{bd}}AdAd}j}{{{f{bd}}hh}j}{{{f{bd}}hCf}j}{{{f{bd}}ln}j}{{{f{bd}}AdC`}j}{{}d}{{}An}{{}Af}{{{f{bd}}}j}{{{f{bd}}h}j}{{{f{bd}}Ab}j}01``````````````````````````````````````2``````9{{{f{bd}}lA`}j}8;:{fc{}}0000{c{{Db{e}}}{}{}}000000000000000{{}{{Db{c}}}{}}000000000000000{fDd}0000000000000008>````````````````{{{f{bDf}}ce}j{}{}}{{{f{bDh}}c}j{}}{{{f{bDj}}ce}j{}{}}{{{f{bDl}}ce}j{}{}}{{{f{bDn}}ce}j{}{}}{{{f{bE`}}c}j{}}{{{f{bEb}}c}j{}}{{{f{bEd}}c}j{}}{{{f{bEf}}c}j{}}{{{f{bEh}}c}j{}}{{{f{bEj}}ce}j{}{}}{{{f{bEl}}c}j{}}{{{f{bEn}}c}j{}}{{{f{bF`}}ce}j{}{}}{{{f{bFb}}ce}j{}{}}{{{f{bFd}}ce}j{}{}}","D":"Lh","p":[[0,"mut"],[5,"Asm",0,344],[1,"reference"],[6,"Reg64",0,345],[1,"unit"],[6,"MemOp",0],[5,"Imm16",0,346],[5,"Imm8",0,346],[6,"Reg16",0,345],[6,"Reg32",0,345],[5,"Runtime",0,347],[1,"u8"],[1,"slice"],[10,"AsRef",348],[5,"Label",0,349],[6,"Reg8",0,345],[5,"MemOp64",0],[5,"MemOp16",0],[5,"MemOp32",0],[5,"MemOp8",0],[1,"i8"],[1,"u16"],[1,"i16"],[5,"Imm32",0,346],[1,"i32"],[1,"u32"],[5,"Imm64",0,346],[1,"i64"],[1,"isize"],[1,"usize"],[1,"u64"],[5,"Vec",350],[6,"Result",351],[5,"TypeId",352],[10,"Add",312],[10,"Call",312],[10,"Cmovnz",312],[10,"Cmovz",312],[10,"Cmp",312],[10,"Dec",312],[10,"Inc",312],[10,"Jmp",312],[10,"Jnz",312],[10,"Jz",312],[10,"Mov",312],[10,"Pop",312],[10,"Push",312],[10,"Sub",312],[10,"Test",312],[10,"Xor",312]],"r":[[0,344],[1,346],[2,346],[3,346],[4,346],[8,349],[14,345],[15,345],[16,345],[17,345],[18,347]],"b":[[19,"impl-Add%3CReg64,+Reg64%3E-for-Asm"],[20,"impl-Add%3CReg64,+MemOp%3E-for-Asm"],[21,"impl-Add%3CMemOp,+Imm16%3E-for-Asm"],[22,"impl-Add%3CMemOp,+Imm8%3E-for-Asm"],[23,"impl-Add%3CMemOp,+Reg16%3E-for-Asm"],[24,"impl-Add%3CMemOp,+Reg64%3E-for-Asm"],[25,"impl-Add%3CReg32,+Reg32%3E-for-Asm"],[88,"impl-Cmp%3CMemOp,+Imm16%3E-for-Asm"],[89,"impl-Cmp%3CMemOp,+Imm8%3E-for-Asm"],[91,"impl-Dec%3CReg32%3E-for-Asm"],[92,"impl-Dec%3CReg64%3E-for-Asm"],[93,"impl-Dec%3CMemOp64%3E-for-Asm"],[94,"impl-Dec%3CMemOp16%3E-for-Asm"],[95,"impl-Dec%3CMemOp32%3E-for-Asm"],[96,"impl-Dec%3CMemOp8%3E-for-Asm"],[117,"impl-From%3Cu8%3E-for-Imm8"],[118,"impl-From%3Ci8%3E-for-Imm8"],[119,"impl-From%3Cu8%3E-for-Imm16"],[121,"impl-From%3Ci8%3E-for-Imm16"],[122,"impl-From%3Cu16%3E-for-Imm16"],[123,"impl-From%3Ci16%3E-for-Imm16"],[125,"impl-From%3Ci8%3E-for-Imm32"],[126,"impl-From%3Cu8%3E-for-Imm32"],[127,"impl-From%3Ci16%3E-for-Imm32"],[128,"impl-From%3Cu16%3E-for-Imm32"],[129,"impl-From%3Ci32%3E-for-Imm32"],[130,"impl-From%3Cu32%3E-for-Imm32"],[131,"impl-From%3Cu8%3E-for-Imm64"],[132,"impl-From%3Ci64%3E-for-Imm64"],[134,"impl-From%3Cisize%3E-for-Imm64"],[135,"impl-From%3Cusize%3E-for-Imm64"],[136,"impl-From%3Ci8%3E-for-Imm64"],[137,"impl-From%3Ci16%3E-for-Imm64"],[138,"impl-From%3Cu16%3E-for-Imm64"],[139,"impl-From%3Ci32%3E-for-Imm64"],[140,"impl-From%3Cu32%3E-for-Imm64"],[141,"impl-From%3Cu64%3E-for-Imm64"],[155,"impl-Inc%3CMemOp64%3E-for-Asm"],[156,"impl-Inc%3CReg64%3E-for-Asm"],[157,"impl-Inc%3CReg32%3E-for-Asm"],[158,"impl-Inc%3CMemOp8%3E-for-Asm"],[159,"impl-Inc%3CMemOp16%3E-for-Asm"],[160,"impl-Inc%3CMemOp32%3E-for-Asm"],[182,"impl-Mov%3CMemOp,+Reg32%3E-for-Asm"],[183,"impl-Mov%3CReg16,+MemOp%3E-for-Asm"],[184,"impl-Mov%3CReg32,+MemOp%3E-for-Asm"],[185,"impl-Mov%3CReg64,+MemOp%3E-for-Asm"],[186,"impl-Mov%3CMemOp,+Reg8%3E-for-Asm"],[187,"impl-Mov%3CMemOp,+Reg16%3E-for-Asm"],[188,"impl-Mov%3CReg16,+Imm16%3E-for-Asm"],[189,"impl-Mov%3CReg8,+Imm8%3E-for-Asm"],[190,"impl-Mov%3CReg8,+MemOp%3E-for-Asm"],[191,"impl-Mov%3CMemOp,+Reg64%3E-for-Asm"],[192,"impl-Mov%3CReg8,+Reg8%3E-for-Asm"],[193,"impl-Mov%3CReg16,+Reg16%3E-for-Asm"],[194,"impl-Mov%3CReg32,+Reg32%3E-for-Asm"],[195,"impl-Mov%3CReg64,+Reg64%3E-for-Asm"],[196,"impl-Mov%3CReg64,+Imm64%3E-for-Asm"],[197,"impl-Mov%3CMemOp,+Imm16%3E-for-Asm"],[198,"impl-Mov%3CReg32,+Imm32%3E-for-Asm"],[203,"impl-Pop%3CReg64%3E-for-Asm"],[204,"impl-Pop%3CReg16%3E-for-Asm"],[205,"impl-Push%3CReg16%3E-for-Asm"],[206,"impl-Push%3CReg64%3E-for-Asm"],[252,"impl-Sub%3CReg64,+Reg64%3E-for-Asm"],[253,"impl-Sub%3CMemOp,+Imm8%3E-for-Asm"],[254,"impl-Test%3CMemOp,+Imm16%3E-for-Asm"],[255,"impl-Test%3CReg32,+Reg32%3E-for-Asm"],[256,"impl-Test%3CReg64,+Reg64%3E-for-Asm"]],"c":"OjAAAAAAAAA=","e":"OzAAAAEAAPQADQAUAAYAHAADACEARQBpAAgAdgACAHoAAgB+AAcAhwAHAJwABQC0ABMAzAApAPcAPwA4AQAA"}],["tiny_vm",{"t":"PPPPPPPFPPPFPGGFNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNHHHNNNNNNNNNNNNNNNNNNNNNNN","n":["A","Add","Addi","B","Branch","BranchZero","C","Fixup","Halt","Load","LoadImm","PhysAddr","Store","TinyInsn","TinyReg","TinyVm","bind","borrow","","","","","borrow_mut","","","","","clone","","clone_into","","clone_to_uninit","","dump","eq","","fmt","","from","","","","","interp","into","","","","","","jit","make_tinyvm_fib","make_tinyvm_jit_perf","make_tinyvm_jit_test","new","","read_mem","read_reg","to_owned","","try_from","","","","","try_into","","","","","type_id","","","","","write_mem","write_reg"],"q":[[0,"tiny_vm"],[77,"alloc::vec"],[78,"core::fmt"],[79,"core::result"],[80,"core::any"]],"i":"nf01001`000`0```bAhA`24310243434343043431024301102430```02004310243102431024300","f":"````````````````{{b{j{d{h{f}}}}}l}{j{{j{c}}}{}}0000{{{j{d}}}{{j{dc}}}{}}0000{{{j{n}}}n}{{{j{f}}}f}{{j{j{dc}}}l{}}0{jl}0{{{j{A`}}}l}{{{j{n}}{j{n}}}Ab}{{{j{f}}{j{f}}}Ab}{{{j{n}}{j{dAd}}}Af}{{{j{f}}{j{dAd}}}Af}{cc{}}0000{{{j{dA`}}}l}{AhAj}{{}c{}}00002{Al{{h{f}}}}{{}{{h{f}}}}0{{{h{f}}}A`}{Ajb}{{{j{A`}}Ah}Al}{{{j{A`}}n}Al}{jc{}}0{c{{An{e}}}{}{}}0000{{}{{An{c}}}{}}0000{jB`}0000{{{j{dA`}}AhAl}l}{{{j{dA`}}nAl}l}","D":"Dj","p":[[5,"Fixup",0],[0,"mut"],[6,"TinyInsn",0],[5,"Vec",77],[1,"reference"],[1,"unit"],[6,"TinyReg",0],[5,"TinyVm",0],[1,"bool"],[5,"Formatter",78],[8,"Result",78],[5,"PhysAddr",0],[1,"usize"],[1,"u16"],[6,"Result",79],[5,"TypeId",80]],"r":[],"b":[],"c":"OjAAAAAAAAA=","e":"OzAAAAEAACgABwABAAAABAAAAAcAAAASAA8AIwADAC0AAAA7ABAA"}]]'));
if (typeof exports !== 'undefined') exports.searchIndex = searchIndex;
else if (window.initSearch) window.initSearch(searchIndex);
-//{"start":39,"fragment_lengths":[111,111,112,112,7962,1542]} \ No newline at end of file
+//{"start":39,"fragment_lengths":[111,111,112,7962,1542]} \ No newline at end of file
diff --git a/search.desc/gen/gen-desc-0-.js b/search.desc/gen/gen-desc-0-.js
deleted file mode 100644
index dac6144..0000000
--- a/search.desc/gen/gen-desc-0-.js
+++ /dev/null
@@ -1 +0,0 @@
-searchState.loadedDescShard("gen", 0, "Add example.") \ No newline at end of file
diff --git a/src-files.js b/src-files.js
index b4498f6..91e9517 100644
--- a/src-files.js
+++ b/src-files.js
@@ -1,3 +1,3 @@
-var srcIndex = new Map(JSON.parse('[["add",["",[],["add.rs"]]],["bf",["",[],["bf.rs"]]],["fib",["",[],["fib.rs"]]],["gen",["",[],["gen.rs"]]],["juicebox_asm",["",[["insn",[],["add.rs","call.rs","cmovnz.rs","cmovz.rs","cmp.rs","dec.rs","inc.rs","jmp.rs","jnz.rs","jz.rs","mov.rs","nop.rs","pop.rs","push.rs","ret.rs","sub.rs","test.rs","xor.rs"]]],["asm.rs","imm.rs","insn.rs","label.rs","lib.rs","reg.rs","rt.rs"]]],["tiny_vm",["",[],["tiny_vm.rs"]]]]'));
+var srcIndex = new Map(JSON.parse('[["add",["",[],["add.rs"]]],["bf",["",[],["bf.rs"]]],["fib",["",[],["fib.rs"]]],["juicebox_asm",["",[["insn",[],["add.rs","call.rs","cmovnz.rs","cmovz.rs","cmp.rs","dec.rs","inc.rs","jmp.rs","jnz.rs","jz.rs","mov.rs","nop.rs","pop.rs","push.rs","ret.rs","sub.rs","test.rs","xor.rs"]]],["asm.rs","imm.rs","insn.rs","label.rs","lib.rs","reg.rs","rt.rs"]]],["tiny_vm",["",[],["tiny_vm.rs"]]]]'));
createSrcSidebar();
-//{"start":36,"fragment_lengths":[26,25,27,27,274,35]} \ No newline at end of file
+//{"start":36,"fragment_lengths":[26,25,27,274,35]} \ No newline at end of file
diff --git a/src/gen/gen.rs.html b/src/gen/gen.rs.html
deleted file mode 100644
index 1df336a..0000000
--- a/src/gen/gen.rs.html
+++ /dev/null
@@ -1,91 +0,0 @@
-<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><meta name="generator" content="rustdoc"><meta name="description" content="Source of the Rust file `examples/gen.rs`."><title>gen.rs - source</title><script>if(window.location.protocol!=="file:")document.head.insertAdjacentHTML("beforeend","SourceSerif4-Regular-46f98efaafac5295.ttf.woff2,FiraSans-Regular-018c141bf0843ffd.woff2,FiraSans-Medium-8f9a781e4970d388.woff2,SourceCodePro-Regular-562dcc5011b6de7d.ttf.woff2,SourceCodePro-Semibold-d899c5a5c4aeb14a.ttf.woff2".split(",").map(f=>`<link rel="preload" as="font" type="font/woff2" crossorigin href="../../static.files/${f}">`).join(""))</script><link rel="stylesheet" href="../../static.files/normalize-76eba96aa4d2e634.css"><link rel="stylesheet" href="../../static.files/rustdoc-b0742ba02757f159.css"><meta name="rustdoc-vars" data-root-path="../../" data-static-root-path="../../static.files/" data-current-crate="gen" data-themes="" data-resource-suffix="" data-rustdoc-version="1.83.0 (90b35a623 2024-11-26)" data-channel="1.83.0" data-search-js="search-f0d225181b97f9a4.js" data-settings-js="settings-805db61a62df4bd2.js" ><script src="../../static.files/storage-1d39b6787ed640ff.js"></script><script defer src="../../static.files/src-script-e66d777a5a92e9b2.js"></script><script defer src="../../src-files.js"></script><script defer src="../../static.files/main-f070b9041d14864c.js"></script><noscript><link rel="stylesheet" href="../../static.files/noscript-0111fcff984fae8f.css"></noscript><link rel="alternate icon" type="image/png" href="../../static.files/favicon-32x32-422f7d1d52889060.png"><link rel="icon" type="image/svg+xml" href="../../static.files/favicon-2c020d218678b618.svg"></head><body class="rustdoc src"><!--[if lte IE 11]><div class="warning">This old browser is unsupported and will most likely display funky things.</div><![endif]--><nav class="sidebar"><div class="src-sidebar-title"><h2>Files</h2></div></nav><div class="sidebar-resizer"></div><main><rustdoc-search></rustdoc-search><section id="main-content" class="content"><div class="main-heading"><h1><div class="sub-heading">gen/</div>gen.rs</h1><rustdoc-toolbar></rustdoc-toolbar></div><div class="example-wrap"><div data-nosnippet><pre class="src-line-numbers">
-<a href="#1" id="1">1</a>
-<a href="#2" id="2">2</a>
-<a href="#3" id="3">3</a>
-<a href="#4" id="4">4</a>
-<a href="#5" id="5">5</a>
-<a href="#6" id="6">6</a>
-<a href="#7" id="7">7</a>
-<a href="#8" id="8">8</a>
-<a href="#9" id="9">9</a>
-<a href="#10" id="10">10</a>
-<a href="#11" id="11">11</a>
-<a href="#12" id="12">12</a>
-<a href="#13" id="13">13</a>
-<a href="#14" id="14">14</a>
-<a href="#15" id="15">15</a>
-<a href="#16" id="16">16</a>
-<a href="#17" id="17">17</a>
-<a href="#18" id="18">18</a>
-<a href="#19" id="19">19</a>
-<a href="#20" id="20">20</a>
-<a href="#21" id="21">21</a>
-<a href="#22" id="22">22</a>
-<a href="#23" id="23">23</a>
-<a href="#24" id="24">24</a>
-<a href="#25" id="25">25</a>
-<a href="#26" id="26">26</a>
-<a href="#27" id="27">27</a>
-<a href="#28" id="28">28</a>
-<a href="#29" id="29">29</a>
-<a href="#30" id="30">30</a>
-<a href="#31" id="31">31</a>
-<a href="#32" id="32">32</a>
-<a href="#33" id="33">33</a>
-<a href="#34" id="34">34</a>
-<a href="#35" id="35">35</a>
-<a href="#36" id="36">36</a>
-<a href="#37" id="37">37</a>
-<a href="#38" id="38">38</a>
-<a href="#39" id="39">39</a>
-<a href="#40" id="40">40</a>
-<a href="#41" id="41">41</a>
-<a href="#42" id="42">42</a>
-<a href="#43" id="43">43</a>
-<a href="#44" id="44">44</a>
-<a href="#45" id="45">45</a></pre></div><pre class="rust"><code><span class="doccomment">//! Add example.
-//!
-//! Jit compile a function at runtime (generate native host code) which calls a function defined in
-//! the example based on the SystemV abi to demonstrate the [`juicebox_asm`] crate.
-
-</span><span class="attr">#[cfg(not(any(target_arch = <span class="string">"x86_64"</span>, target_os = <span class="string">"linux"</span>)))]
-</span><span class="macro">compile_error!</span>(<span class="string">"Only supported on x86_64 with SystemV abi"</span>);
-
-<span class="kw">use </span>juicebox_asm::insn::<span class="kw-2">*</span>;
-<span class="kw">use </span>juicebox_asm::{Asm, Imm16, Imm64, Imm8, Label, Reg16, Reg64::<span class="kw-2">*</span>, Runtime};
-<span class="kw">use </span>juicebox_asm::{MemOp, MemOp16, MemOp32, MemOp64, MemOp8};
-
-<span class="kw">extern </span><span class="string">"C" </span><span class="kw">fn </span>add(a: u32, b: u32) -&gt; u32 {
- a + b
-}
-
-<span class="kw">fn </span>main() {
- <span class="kw">let </span><span class="kw-2">mut </span>asm1 = Asm::new();
- asm1.xor(r11, r11);
-
- <span class="macro">assert!</span>(<span class="number">0x7fu8 </span>&lt;= i8::MAX <span class="kw">as </span>u8);
-
- asm1.add(MemOp::IndirectBaseIndex(rdi, r11), Imm8::from(<span class="number">0x10u8</span>));
- asm1.ret();
-
- <span class="kw">let </span>code = asm1.into_code();
- std::fs::write(<span class="string">"jit.asm"</span>, <span class="kw-2">&amp;</span>code).unwrap();
-
- <span class="kw">let </span><span class="kw-2">mut </span>asm2 = Asm::new();
- asm2.mov(Reg16::cx, Imm16::from(<span class="number">1u16</span>));
- asm2.mov(MemOp::Indirect(rdi), Reg16::cx);
- asm2.ret();
-
- <span class="kw">let </span><span class="kw-2">mut </span>rt = Runtime::new();
- <span class="kw">let </span>fn1 = <span class="kw">unsafe </span>{ rt.add_code::&lt;<span class="kw">extern </span><span class="string">"C" </span><span class="kw">fn</span>(<span class="kw-2">*mut </span>u64)&gt;(code) };
- <span class="kw">let </span>fn2 = <span class="kw">unsafe </span>{ rt.add_code::&lt;<span class="kw">extern </span><span class="string">"C" </span><span class="kw">fn</span>(<span class="kw-2">*mut </span>u64)&gt;(asm2.into_code()) };
-
- <span class="kw">let </span><span class="kw-2">mut </span>data = <span class="number">0xffff_ffff_ffff_ff00u64</span>;
- fn1(<span class="kw-2">&amp;mut </span>data <span class="kw">as </span><span class="kw-2">*mut </span>u64);
- <span class="macro">println!</span>(<span class="string">"data={:x}"</span>, data);
-
- <span class="kw">let </span><span class="kw-2">mut </span>data = <span class="number">0xffff_ffff_ffff_ffffu64</span>;
- fn2(<span class="kw-2">&amp;mut </span>data <span class="kw">as </span><span class="kw-2">*mut </span>u64);
- <span class="macro">println!</span>(<span class="string">"data={:x}"</span>, data);
-}
-</code></pre></div></section></main></body></html> \ No newline at end of file