Stream: git-wasmtime

Topic: wasmtime / issue #9835 Cranelift: should be implemented i...


view this post on Zulip Wasmtime GitHub notifications bot (Dec 16 2024 at 18:27):

stellaphax added the bug label to Issue #9835.

view this post on Zulip Wasmtime GitHub notifications bot (Dec 16 2024 at 18:27):

stellaphax added the cranelift label to Issue #9835.

view this post on Zulip Wasmtime GitHub notifications bot (Dec 16 2024 at 18:27):

stellaphax opened issue #9835:

Creating something for a Capture the Flag (CTF) challenge, and came across this when attempting to compile my function.

Full Backtrace:

thread 'main' panicked at C:\Users\accord\.cargo\registry\src\index.crates.io-6f17d22bba15001f\cranelift-codegen-0.114.0\src\machinst\lower.rs:685:21:
should be implemented in ISLE: inst = v71 = stack_load.i64 ss0, type = Some(types::I64)
stack backtrace:
0: std::panicking::begin_panic_handler
at /rustc/90b35a6239c3d8bdabc530a6a0816f7ff89a0aaf\library/std\src\panicking.rs:665
1: core::panicking::panic_fmt
at /rustc/90b35a6239c3d8bdabc530a6a0816f7ff89a0aaf\library/core\src\panicking.rs:74
2: cranelift_codegen::machinst::lower::impl$3::lower_clif_block::closure$0<enum2$<cranelift_codegen::isa::x64::lower::isle::generated_code::MInst>,cranelift_codegen::isa::x64::X64Backend>
at C:\Users\accord\.cargo\registry\src\index.crates.io-6f17d22bba15001f\cranelift-codegen-0.114.0\src\machinst\lower.rs:685
3: enum2$<core::option::Option<smallvec::SmallVec<array$<cranelift_codegen::machinst::valueregs::ValueRegs<cranelift_codegen::machinst::reg::Reg>,2> > > >::unwrap_or_else<smallvec::SmallVec<array$<cranelift_codegen::machinst::valueregs::ValueRegs<cranelift_co
at C:\Users\accord\.rustup\toolchains\stable-x86_64-pc-windows-msvc\lib\rustlib\src\rust\library\core\src\option.rs:1017
4: cranelift_codegen::machinst::lower::Lower<enum2$<cranelift_codegen::isa::x64::lower::isle::generated_code::MInst> >::lower_clif_block<enum2$<cranelift_codegen::isa::x64::lower::isle::generated_code::MInst>,cranelift_codegen::isa::x64::X64Backend>
at C:\Users\accord\.cargo\registry\src\index.crates.io-6f17d22bba15001f\cranelift-codegen-0.114.0\src\machinst\lower.rs:679
5: cranelift_codegen::machinst::lower::Lower<enum2$<cranelift_codegen::isa::x64::lower::isle::generated_code::MInst> >::lower<enum2$<cranelift_codegen::isa::x64::lower::isle::generated_code::MInst>,cranelift_codegen::isa::x64::X64Backend>
at C:\Users\accord\.cargo\registry\src\index.crates.io-6f17d22bba15001f\cranelift-codegen-0.114.0\src\machinst\lower.rs:1017
6: cranelift_codegen::machinst::compile::compile<cranelift_codegen::isa::x64::X64Backend>
at C:\Users\accord\.cargo\registry\src\index.crates.io-6f17d22bba15001f\cranelift-codegen-0.114.0\src\machinst\compile.rs:41
7: cranelift_codegen::isa::x64::X64Backend::compile_vcode
at C:\Users\accord\.cargo\registry\src\index.crates.io-6f17d22bba15001f\cranelift-codegen-0.114.0\src\isa\x64\mod.rs:61
8: cranelift_codegen::isa::x64::impl$1::compile_function
at C:\Users\accord\.cargo\registry\src\index.crates.io-6f17d22bba15001f\cranelift-codegen-0.114.0\src\isa\x64\mod.rs:73
9: ctf::interpreter::generate
at .\src\interpreter.rs:924
10: REDACTED::main
at .\src\bin\virtualizer.rs:6
11: core::ops::function::FnOnce::call_once<void (*)(),tuple$<> >
at C:\Users\accord\.rustup\toolchains\stable-x86_64-pc-windows-msvc\lib\rustlib\src\rust\library\core\src\ops\function.rs:250
12: core::hint::black_box
at C:\Users\accord\.rustup\toolchains\stable-x86_64-pc-windows-msvc\lib\rustlib\src\rust\library\core\src\hint.rs:389
note: Some details are omitted, run with RUST_BACKTRACE=full for a verbose backtrace.
error: process didn't exit successfully: REDACTED.exe (exit code: 101)

My IR

`function u0:0(i64, i64) -> i64 windows_fastcall {
ss0 = explicit_slot 8, align = 65536
ss1 = explicit_slot 8, align = 65536

block0(v0: i64, v1: i64):
stack_store v0, ss0
stack_store v1, ss1
jump block1

block1:
v2 = stack_load.i64 ss0
v3 = iconst.i64 128
v4 = iadd v2, v3 ; v3 = 128
v5 = load.i64 readonly little v4
v6 = load.i64 readonly little v5
v7 = bnot v6
v8 = iconst.i64 0x489d_2061_0fc3_fb2a
v9 = isub v7, v8 ; v8 = 0x489d_2061_0fc3_fb2a
v10 = iconst.i64 -4461110450679002079
v11 = bxor v9, v10 ; v10 = -4461110450679002079
v12 = iconst.i64 0x1c14_4295_049e_9905
v13 = bxor v11, v12 ; v12 = 0x1c14_4295_049e_9905
v14 = ineg v13
v15 = bnot v14
v16 = iconst.i64 -8819557583384649525
v17 = isub v15, v16 ; v16 = -8819557583384649525
v18 = iconst.i64 -292475872589187261
v19 = bxor v17, v18 ; v18 = -292475872589187261
v20 = iconst.i64 -8660319366599639002
v21 = isub v19, v20 ; v20 = -8660319366599639002
v22 = iconst.i64 -7151449463209098624
v23 = bxor v21, v22 ; v22 = -7151449463209098624
v24 = iconst.i64 0x18c8_b9af_33b0_a405
v25 = iadd v23, v24 ; v24 = 0x18c8_b9af_33b0_a405
v26 = iconst.i64 0x40e7_0af5_6ce5_56dd
v27 = bxor v25, v26 ; v26 = 0x40e7_0af5_6ce5_56dd
v28 = iconst.i64 -6954426303843586127
v29 = bxor v27, v28 ; v28 = -6954426303843586127
v30 = iconst.i64 -6831553930069083890
v31 = bxor v29, v30 ; v30 = -6831553930069083890
v32 = iconst.i64 0x0bbe_eb37_ba28_a537
v33 = bxor v31, v32 ; v32 = 0x0bbe_eb37_ba28_a537
v34 = iconst.i64 0x6d27_b06f_df5c_9472
v35 = bxor v33, v34 ; v34 = 0x6d27_b06f_df5c_9472
v36 = iconst.i64 0x6e30_5d88_0555_9288
v37 = bxor v35, v36 ; v36 = 0x6e30_5d88_0555_9288
v38 = ineg v37
v39 = iconst.i64 -2882484716177919502
v40 = bxor v38, v39 ; v39 = -2882484716177919502
v41 = iconst.i64 0x3af4_83c5_3db0_1d9d
v42 = isub v40, v41 ; v41 = 0x3af4_83c5_3db0_1d9d
v43 = iconst.i64 -5792733239001732165
v44 = bxor v42, v43 ; v43 = -5792733239001732165
v45 = bnot v44
v46 = iconst.i64 8
v47 = iadd v5, v46 ; v46 = 8
store little v47, v4
v48 = iconst.i64 -7783865175571007017
v49 = icmp eq v45, v48 ; v48 = -7783865175571007017
brif v49, block2, block13

block13:
v50 = iconst.i64 0x7b5a_d962_d1b6_bc9e
v51 = icmp.i64 eq v45, v50 ; v50 = 0x7b5a_d962_d1b6_bc9e
brif v51, block3, block14

block14:
v52 = iconst.i64 -6272791173886278192
v53 = icmp.i64 eq v45, v52 ; v52 = -6272791173886278192
brif v53, block4, block15

block15:
v54 = iconst.i64 -2797489443462894109
v55 = icmp.i64 eq v45, v54 ; v54 = -2797489443462894109
brif v55, block5, block16

block16:
v56 = iconst.i64 0x02c8_1cdd_21bd_b3c0
v57 = icmp.i64 eq v45, v56 ; v56 = 0x02c8_1cdd_21bd_b3c0
brif v57, block6, block17

block17:
v58 = iconst.i64 0x6ee2_e465_36e8_77b5
v59 = icmp.i64 eq v45, v58 ; v58 = 0x6ee2_e465_36e8_77b5
brif v59, block7, block18

block18:
v60 = iconst.i64 -8073358707478604768
v61 = icmp.i64 eq v45, v60 ; v60 = -8073358707478604768
brif v61, block8, block19

block19:
v62 = iconst.i64 0x1057_b219_e4fa_5f10
v63 = icmp.i64 eq v45, v62 ; v62 = 0x1057_b219_e4fa_5f10
brif v63, block9, block20

block20:
v64 = iconst.i64 -8726837251761108653
v65 = icmp.i64 eq v45, v64 ; v64 = -8726837251761108653
brif v65, block10, block21

block21:
v66 = iconst.i64 -7230224490429434294
v67 = icmp.i64 eq v45, v66 ; v66 = -7230224490429434294
brif v67, block11, block22

block22:
v68 = iconst.i64 0x6b23_5923_d009_c45c
v69 = icmp.i64 eq v45, v68 ; v68 = 0x6b23_5923_d009_c45c
brif v69, block12, block23

block23:
jump block1

block2:
v70 = stack_load.i64 ss0
v71 = iconst.i64 128
v72 = iadd v70, v71 ; v71 = 128
v73 = load.i64 readonly little v72
v74 = load.i64 readonly little v73
v75 = iconst.i64 -2704559895804829619
v76 = bxor v74, v75 ; v75 = -2704559895804829619
v77 = bnot v76
v78 = iconst.i64 0x7e5d_964e_adf2_ac49
v79 = isub v77, v78 ; v78 = 0x7e5d_964e_adf2_ac49
v80 = bnot v79
v81 = ineg v80
v82 = iconst.i64 0x5b93_de21_5f20_6444
v83 = isub v81, v82 ; v82 = 0x5b93_de21_5f20_6444
v84 = iconst.i64 0x2e8e_61ad_5854_eb18
v85 = bxor v83, v84 ; v84 = 0x2e8e_61ad_5854_eb18
v86 = bnot v85
v87 = iconst.i64 0x5935_230f_2339_3e3e
v88 = bxor v86, v87 ; v87 = 0x5935_230f_2339_3e3e
v89 = ineg v88
v90 = iconst.i64 -3750086189034530752
v91 = bxor v89, v90 ; v90 = -3750086189034530752
v92 = iconst.i64 0x66f2_7dd6_509a_7dd6
v93 = bxor v91, v92 ; v92 = 0x66f2_7dd6_509a_7dd6
v94 = iconst.i64 0x0feb_13a6_5b72_5ca9
v95 = bxor v93, v94 ; v94 = 0x0feb_13a6_5b72_5ca9
v96 = iconst.i64 0x4bae_b9b1_b37a_17d2
v97 = isub v95, v96 ; v96 = 0x4bae_b9b1_b37a_17d2
v98 = iconst.i64 0x4b39_bbbc_9294_7a09
v99 = bxor v97, v98 ; v98 = 0x4b39_bbbc_9294_7a09
v100 = iconst.i64 -5626529817850843395
v101 = iadd v99, v100 ; v100 = -5626529817850843395
v102 = iconst.i64 -6666738309278736411
v103 = isub v101, v102 ; v102 = -6666738309278736411
v104 = iconst.i64 -1757971160561802068
v105 = bxor v103, v104 ; v104 = -1757971160561802068
v106 = iconst.i64 8
v107 = iadd v73, v106 ; v106 = 8
store little v107, v72
v108 = iconst.i64 8
v109 = imul v105, v108 ; v108 = 8
v110 = iadd v70, v109
v111 = load.i64 readonly little v110
v112 = iconst.i64 336
v113 = iadd v70, v112 ; v112 = 336
v114 = load.i64 readonly little v113
v115 = iconst.i64 8
v116 = isub v114, v115 ; v115 = 8
store little v116, v113
store little v111, v116
jump block1

block3:
v117 = stack_load.i64 ss0
v118 = iconst.i64 128
v119 = iadd v117, v118 ; v118 = 128
v120 = load.i64 readonly little v119
v121 = load.i64 readonly little v120
v122 = iconst.i64 0x02f3_7043_5ac2_8a35
v123 = bxor v121, v122 ; v122 = 0x02f3_7043_5ac2_8a35
v124 = ineg v123
v125 = iconst.i64 0x5b5c_416b_0348_d8b8
v126 = bxor v124, v125 ;
[message truncated]

view this post on Zulip Wasmtime GitHub notifications bot (Dec 16 2024 at 18:54):

bjorn3 commented on issue #9835:

How did you try to compile the function? Using cranelift_codegen::Context::compile or in sone other way?

view this post on Zulip Wasmtime GitHub notifications bot (Dec 16 2024 at 20:00):

stellaphax closed issue #9835:

Creating something for a Capture the Flag (CTF) challenge, and came across this when attempting to compile my function.

Full Backtrace:

thread 'main' panicked at C:\Users\accord\.cargo\registry\src\index.crates.io-6f17d22bba15001f\cranelift-codegen-0.114.0\src\machinst\lower.rs:685:21:
should be implemented in ISLE: inst = v71 = stack_load.i64 ss0, type = Some(types::I64)
stack backtrace:
0: std::panicking::begin_panic_handler
at /rustc/90b35a6239c3d8bdabc530a6a0816f7ff89a0aaf\library/std\src\panicking.rs:665
1: core::panicking::panic_fmt
at /rustc/90b35a6239c3d8bdabc530a6a0816f7ff89a0aaf\library/core\src\panicking.rs:74
2: cranelift_codegen::machinst::lower::impl$3::lower_clif_block::closure$0<enum2$<cranelift_codegen::isa::x64::lower::isle::generated_code::MInst>,cranelift_codegen::isa::x64::X64Backend>
at C:\Users\accord\.cargo\registry\src\index.crates.io-6f17d22bba15001f\cranelift-codegen-0.114.0\src\machinst\lower.rs:685
3: enum2$<core::option::Option<smallvec::SmallVec<array$<cranelift_codegen::machinst::valueregs::ValueRegs<cranelift_codegen::machinst::reg::Reg>,2> > > >::unwrap_or_else<smallvec::SmallVec<array$<cranelift_codegen::machinst::valueregs::ValueRegs<cranelift_co
at C:\Users\accord\.rustup\toolchains\stable-x86_64-pc-windows-msvc\lib\rustlib\src\rust\library\core\src\option.rs:1017
4: cranelift_codegen::machinst::lower::Lower<enum2$<cranelift_codegen::isa::x64::lower::isle::generated_code::MInst> >::lower_clif_block<enum2$<cranelift_codegen::isa::x64::lower::isle::generated_code::MInst>,cranelift_codegen::isa::x64::X64Backend>
at C:\Users\accord\.cargo\registry\src\index.crates.io-6f17d22bba15001f\cranelift-codegen-0.114.0\src\machinst\lower.rs:679
5: cranelift_codegen::machinst::lower::Lower<enum2$<cranelift_codegen::isa::x64::lower::isle::generated_code::MInst> >::lower<enum2$<cranelift_codegen::isa::x64::lower::isle::generated_code::MInst>,cranelift_codegen::isa::x64::X64Backend>
at C:\Users\accord\.cargo\registry\src\index.crates.io-6f17d22bba15001f\cranelift-codegen-0.114.0\src\machinst\lower.rs:1017
6: cranelift_codegen::machinst::compile::compile<cranelift_codegen::isa::x64::X64Backend>
at C:\Users\accord\.cargo\registry\src\index.crates.io-6f17d22bba15001f\cranelift-codegen-0.114.0\src\machinst\compile.rs:41
7: cranelift_codegen::isa::x64::X64Backend::compile_vcode
at C:\Users\accord\.cargo\registry\src\index.crates.io-6f17d22bba15001f\cranelift-codegen-0.114.0\src\isa\x64\mod.rs:61
8: cranelift_codegen::isa::x64::impl$1::compile_function
at C:\Users\accord\.cargo\registry\src\index.crates.io-6f17d22bba15001f\cranelift-codegen-0.114.0\src\isa\x64\mod.rs:73
9: ctf::interpreter::generate
at .\src\interpreter.rs:924
10: REDACTED::main
at .\src\bin\virtualizer.rs:6
11: core::ops::function::FnOnce::call_once<void (*)(),tuple$<> >
at C:\Users\accord\.rustup\toolchains\stable-x86_64-pc-windows-msvc\lib\rustlib\src\rust\library\core\src\ops\function.rs:250
12: core::hint::black_box
at C:\Users\accord\.rustup\toolchains\stable-x86_64-pc-windows-msvc\lib\rustlib\src\rust\library\core\src\hint.rs:389
note: Some details are omitted, run with RUST_BACKTRACE=full for a verbose backtrace.
error: process didn't exit successfully: REDACTED.exe (exit code: 101)

My IR

`function u0:0(i64, i64) -> i64 windows_fastcall {
ss0 = explicit_slot 8, align = 65536
ss1 = explicit_slot 8, align = 65536

block0(v0: i64, v1: i64):
stack_store v0, ss0
stack_store v1, ss1
jump block1

block1:
v2 = stack_load.i64 ss0
v3 = iconst.i64 128
v4 = iadd v2, v3 ; v3 = 128
v5 = load.i64 readonly little v4
v6 = load.i64 readonly little v5
v7 = bnot v6
v8 = iconst.i64 0x489d_2061_0fc3_fb2a
v9 = isub v7, v8 ; v8 = 0x489d_2061_0fc3_fb2a
v10 = iconst.i64 -4461110450679002079
v11 = bxor v9, v10 ; v10 = -4461110450679002079
v12 = iconst.i64 0x1c14_4295_049e_9905
v13 = bxor v11, v12 ; v12 = 0x1c14_4295_049e_9905
v14 = ineg v13
v15 = bnot v14
v16 = iconst.i64 -8819557583384649525
v17 = isub v15, v16 ; v16 = -8819557583384649525
v18 = iconst.i64 -292475872589187261
v19 = bxor v17, v18 ; v18 = -292475872589187261
v20 = iconst.i64 -8660319366599639002
v21 = isub v19, v20 ; v20 = -8660319366599639002
v22 = iconst.i64 -7151449463209098624
v23 = bxor v21, v22 ; v22 = -7151449463209098624
v24 = iconst.i64 0x18c8_b9af_33b0_a405
v25 = iadd v23, v24 ; v24 = 0x18c8_b9af_33b0_a405
v26 = iconst.i64 0x40e7_0af5_6ce5_56dd
v27 = bxor v25, v26 ; v26 = 0x40e7_0af5_6ce5_56dd
v28 = iconst.i64 -6954426303843586127
v29 = bxor v27, v28 ; v28 = -6954426303843586127
v30 = iconst.i64 -6831553930069083890
v31 = bxor v29, v30 ; v30 = -6831553930069083890
v32 = iconst.i64 0x0bbe_eb37_ba28_a537
v33 = bxor v31, v32 ; v32 = 0x0bbe_eb37_ba28_a537
v34 = iconst.i64 0x6d27_b06f_df5c_9472
v35 = bxor v33, v34 ; v34 = 0x6d27_b06f_df5c_9472
v36 = iconst.i64 0x6e30_5d88_0555_9288
v37 = bxor v35, v36 ; v36 = 0x6e30_5d88_0555_9288
v38 = ineg v37
v39 = iconst.i64 -2882484716177919502
v40 = bxor v38, v39 ; v39 = -2882484716177919502
v41 = iconst.i64 0x3af4_83c5_3db0_1d9d
v42 = isub v40, v41 ; v41 = 0x3af4_83c5_3db0_1d9d
v43 = iconst.i64 -5792733239001732165
v44 = bxor v42, v43 ; v43 = -5792733239001732165
v45 = bnot v44
v46 = iconst.i64 8
v47 = iadd v5, v46 ; v46 = 8
store little v47, v4
v48 = iconst.i64 -7783865175571007017
v49 = icmp eq v45, v48 ; v48 = -7783865175571007017
brif v49, block2, block13

block13:
v50 = iconst.i64 0x7b5a_d962_d1b6_bc9e
v51 = icmp.i64 eq v45, v50 ; v50 = 0x7b5a_d962_d1b6_bc9e
brif v51, block3, block14

block14:
v52 = iconst.i64 -6272791173886278192
v53 = icmp.i64 eq v45, v52 ; v52 = -6272791173886278192
brif v53, block4, block15

block15:
v54 = iconst.i64 -2797489443462894109
v55 = icmp.i64 eq v45, v54 ; v54 = -2797489443462894109
brif v55, block5, block16

block16:
v56 = iconst.i64 0x02c8_1cdd_21bd_b3c0
v57 = icmp.i64 eq v45, v56 ; v56 = 0x02c8_1cdd_21bd_b3c0
brif v57, block6, block17

block17:
v58 = iconst.i64 0x6ee2_e465_36e8_77b5
v59 = icmp.i64 eq v45, v58 ; v58 = 0x6ee2_e465_36e8_77b5
brif v59, block7, block18

block18:
v60 = iconst.i64 -8073358707478604768
v61 = icmp.i64 eq v45, v60 ; v60 = -8073358707478604768
brif v61, block8, block19

block19:
v62 = iconst.i64 0x1057_b219_e4fa_5f10
v63 = icmp.i64 eq v45, v62 ; v62 = 0x1057_b219_e4fa_5f10
brif v63, block9, block20

block20:
v64 = iconst.i64 -8726837251761108653
v65 = icmp.i64 eq v45, v64 ; v64 = -8726837251761108653
brif v65, block10, block21

block21:
v66 = iconst.i64 -7230224490429434294
v67 = icmp.i64 eq v45, v66 ; v66 = -7230224490429434294
brif v67, block11, block22

block22:
v68 = iconst.i64 0x6b23_5923_d009_c45c
v69 = icmp.i64 eq v45, v68 ; v68 = 0x6b23_5923_d009_c45c
brif v69, block12, block23

block23:
jump block1

block2:
v70 = stack_load.i64 ss0
v71 = iconst.i64 128
v72 = iadd v70, v71 ; v71 = 128
v73 = load.i64 readonly little v72
v74 = load.i64 readonly little v73
v75 = iconst.i64 -2704559895804829619
v76 = bxor v74, v75 ; v75 = -2704559895804829619
v77 = bnot v76
v78 = iconst.i64 0x7e5d_964e_adf2_ac49
v79 = isub v77, v78 ; v78 = 0x7e5d_964e_adf2_ac49
v80 = bnot v79
v81 = ineg v80
v82 = iconst.i64 0x5b93_de21_5f20_6444
v83 = isub v81, v82 ; v82 = 0x5b93_de21_5f20_6444
v84 = iconst.i64 0x2e8e_61ad_5854_eb18
v85 = bxor v83, v84 ; v84 = 0x2e8e_61ad_5854_eb18
v86 = bnot v85
v87 = iconst.i64 0x5935_230f_2339_3e3e
v88 = bxor v86, v87 ; v87 = 0x5935_230f_2339_3e3e
v89 = ineg v88
v90 = iconst.i64 -3750086189034530752
v91 = bxor v89, v90 ; v90 = -3750086189034530752
v92 = iconst.i64 0x66f2_7dd6_509a_7dd6
v93 = bxor v91, v92 ; v92 = 0x66f2_7dd6_509a_7dd6
v94 = iconst.i64 0x0feb_13a6_5b72_5ca9
v95 = bxor v93, v94 ; v94 = 0x0feb_13a6_5b72_5ca9
v96 = iconst.i64 0x4bae_b9b1_b37a_17d2
v97 = isub v95, v96 ; v96 = 0x4bae_b9b1_b37a_17d2
v98 = iconst.i64 0x4b39_bbbc_9294_7a09
v99 = bxor v97, v98 ; v98 = 0x4b39_bbbc_9294_7a09
v100 = iconst.i64 -5626529817850843395
v101 = iadd v99, v100 ; v100 = -5626529817850843395
v102 = iconst.i64 -6666738309278736411
v103 = isub v101, v102 ; v102 = -6666738309278736411
v104 = iconst.i64 -1757971160561802068
v105 = bxor v103, v104 ; v104 = -1757971160561802068
v106 = iconst.i64 8
v107 = iadd v73, v106 ; v106 = 8
store little v107, v72
v108 = iconst.i64 8
v109 = imul v105, v108 ; v108 = 8
v110 = iadd v70, v109
v111 = load.i64 readonly little v110
v112 = iconst.i64 336
v113 = iadd v70, v112 ; v112 = 336
v114 = load.i64 readonly little v113
v115 = iconst.i64 8
v116 = isub v114, v115 ; v115 = 8
store little v116, v113
store little v111, v116
jump block1

block3:
v117 = stack_load.i64 ss0
v118 = iconst.i64 128
v119 = iadd v117, v118 ; v118 = 128
v120 = load.i64 readonly little v119
v121 = load.i64 readonly little v120
v122 = iconst.i64 0x02f3_7043_5ac2_8a35
v123 = bxor v121, v122 ; v122 = 0x02f3_7043_5ac2_8a35
v124 = ineg v123
v125 = iconst.i64 0x5b5c_416b_0348_d8b8
v126 = bxor v124, v125 ;
[message truncated]

view this post on Zulip Wasmtime GitHub notifications bot (Dec 16 2024 at 20:00):

stellaphax commented on issue #9835:

How did you try to compile the function? Using cranelift_codegen::Context::compile or in sone other way?

Ohh.... I did it through some other avenue. Thank you for letting me know! I switched to using that same API you just mentioned, and everything works fine now. Thank you!

view this post on Zulip Wasmtime GitHub notifications bot (Dec 16 2024 at 21:08):

bjorn3 commented on issue #9835:

Great to hear you managed to get it working! The reason it didn't work through the other method you tried is likely because that other method skipped the "legalization" from stack_load to stack_addr combined with a regular load.


Last updated: Dec 23 2024 at 12:05 UTC