aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/add/add.rs.html
diff options
context:
space:
mode:
Diffstat (limited to 'src/add/add.rs.html')
-rw-r--r--src/add/add.rs.html8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/add/add.rs.html b/src/add/add.rs.html
index 580daa0..ba76c7d 100644
--- a/src/add/add.rs.html
+++ b/src/add/add.rs.html
@@ -36,8 +36,7 @@
<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></pre></div><pre class="rust"><code><span class="doccomment">//! Add example.
+<a href="#38" id="38">38</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.
@@ -69,9 +68,8 @@
<span class="kw">let </span><span class="kw-2">mut </span>rt = Runtime::new();
<span class="kw">let </span>add42 = <span class="kw">unsafe </span>{ rt.add_code::&lt;<span class="kw">extern </span><span class="string">"C" </span><span class="kw">fn</span>(u32) -&gt; u32&gt;(asm.into_code()) };
- <span class="comment">// Write out JIT code for visualization.
- // Disassemble for example with `ndisasm -b 64 jit.asm`.
- </span>rt.dump();
+ <span class="comment">// Disassemble JIT code and write to stdout.
+ </span>rt.disasm();
<span class="kw">let </span>res = add42(<span class="number">5</span>);
<span class="macro">assert_eq!</span>(res, <span class="number">47</span>);