gurry commented on issue #6844:
DataValueExt::int()
doesn't currently seem to have any tests. Please let me know if I should add any tests for this PR or forDataValueExt::int()
in general.
gurry edited a comment on issue #6844:
DataValueExt::int()
doesn't currently seem to have any tests. Please let me know if I should add any tests for this PR or forDataValueExt::int()
in general.Wonder if it would be a good idea to create a test from the
.clif
in #6827
gurry commented on issue #6844:
Just saw that the test already exists:
So just enabled it for the interpreter.
gurry edited a comment on issue #6844:
Just saw that the test already exists:
So I've enabled it for the interpreter.
gurry commented on issue #6844:
Thanks @afonso360
In order to test with an 8 byte vector input to
DataValueExt::int()
I tried adding the following test tosimd-ineg.clif
but it crashed with the below trace:RUST_BACKTRACE=1 cargo test --test filetests Finished test [unoptimized + debuginfo] target(s) in 0.47s Running tests/filetests.rs ([...]\wasmtime\target\debug\deps\filetests-d08e13383c5d8a1e.exe) slow: 0.026 filetests\filetests\wasm\aarch64-relaxed-simd.wat thread 'worker #2' panicked at 'called `Option::unwrap()` on a `None` value', cranelift\codegen\src\isa\x64\lower\isle.rs:550:21 stack backtrace: 0: std::panicking::begin_panic_handler at /rustc/eb26296b556cef10fb713a38f3d16b9886080f26/library\std\src\panicking.rs:593 1: core::panicking::panic_fmt at /rustc/eb26296b556cef10fb713a38f3d16b9886080f26/library\core\src\panicking.rs:67 2: core::panicking::panic at /rustc/eb26296b556cef10fb713a38f3d16b9886080f26/library\core\src\panicking.rs:117 3: enum2$<core::option::Option<cranelift_codegen::isa::x64::inst::args::Gpr> >::unwrap<cranelift_codegen::isa::x64::inst::args::Gpr> at /rustc/eb26296b556cef10fb713a38f3d16b9886080f26\library\core\src\option.rs:935 4: cranelift_codegen::isa::x64::lower::isle::impl$0::gpr_new at .\codegen\src\isa\x64\lower\isle.rs:550 5: cranelift_codegen::isa::x64::lower::isle::generated_code::constructor_put_in_gpr<cranelift_codegen::machinst::isle::IsleContext<enum2$<cranelift_codegen::isa::x64::lower::isle::generated_code::MInst>,cranelift_codegen::isa::x64::X64Backend> > at C:\Users\gurinder.singh\Projects\Personal\wasmtime_dev\wasmtime\target\debug\build\cranelift-codegen-3e0280ce8237aaeb\out\isle_x64.rs:2610 6: cranelift_codegen::isa::x64::lower::isle::generated_code::constructor_lower<cranelift_codegen::machinst::isle::IsleContext<enum2$<cranelift_codegen::isa::x64::lower::isle::generated_code::MInst>,cranelift_codegen::isa::x64::X64Backend> > at C:\Users\gurinder.singh\Projects\Personal\wasmtime_dev\wasmtime\target\debug\build\cranelift-codegen-3e0280ce8237aaeb\out\isle_x64.rs:16695 7: cranelift_codegen::isa::x64::lower::isle::lower at .\codegen\src\isa\x64\lower\isle.rs:64 8: cranelift_codegen::isa::x64::lower::impl$1::lower at .\codegen\src\isa\x64\lower.rs:325 9: 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 .\codegen\src\machinst\lower.rs:743 10: 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 .\codegen\src\machinst\lower.rs:1067 11: cranelift_codegen::machinst::compile::compile<cranelift_codegen::isa::x64::X64Backend> at .\codegen\src\machinst\compile.rs:40 12: cranelift_codegen::isa::x64::X64Backend::compile_vcode at .\codegen\src\isa\x64\mod.rs:61 13: cranelift_codegen::isa::x64::impl$1::compile_function at .\codegen\src\isa\x64\mod.rs:73 14: cranelift_codegen::context::Context::compile_stencil at .\codegen\src\context.rs:146 15: cranelift_codegen::context::Context::compile at .\codegen\src\context.rs:206 16: cranelift_jit::backend::impl$2::define_function_with_control_plane at .\jit\src\backend.rs:689 17: cranelift_filetests::function_runner::TestFileCompiler::define_function at .\filetests\src\function_runner.rs:248 18: cranelift_filetests::function_runner::TestFileCompiler::add_functions at .\filetests\src\function_runner.rs:148 19: cranelift_filetests::function_runner::TestFileCompiler::add_testfile at .\filetests\src\function_runner.rs:165 20: cranelift_filetests::test_run::compile_testfile at .\filetests\src\test_run.rs:127 21: cranelift_filetests::test_run::impl$0::run_target at .\filetests\src\test_run.rs:197 22: cranelift_filetests::runone::run at .\filetests\src\runone.rs:102 23: cranelift_filetests::concurrent::worker_thread::closure$0::closure$0 at .\filetests\src\concurrent.rs:152 24: std::panicking::try::do_call<cranelift_filetests::concurrent::worker_thread::closure$0::closure_env$0,enum2$<core::result::Result<core::time::Duration,anyhow::Error> > > at /rustc/eb26296b556cef10fb713a38f3d16b9886080f26\library\std\src\panicking.rs:500 25: std::panicking::try::do_catch<cranelift_filetests::concurrent::worker_thread::closure$0::closure_env$0,enum2$<core::result::Result<core::time::Duration,anyhow::Error> > > 26: std::panicking::try<enum2$<core::result::Result<core::time::Duration,anyhow::Error> >,cranelift_filetests::concurrent::worker_thread::closure$0::closure_env$0> at /rustc/eb26296b556cef10fb713a38f3d16b9886080f26\library\std\src\panicking.rs:464 27: std::panic::catch_unwind<cranelift_filetests::concurrent::worker_thread::closure$0::closure_env$0,enum2$<core::result::Result<core::time::Duration,anyhow::Error> > > at /rustc/eb26296b556cef10fb713a38f3d16b9886080f26\library\std\src\panic.rs:142 28: cranelift_filetests::concurrent::worker_thread::closure$0 at .\filetests\src\concurrent.rs:152 note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace. FAIL filetests\filetests\runtests\simd-ineg.clif: panicked in worker #2: called `Option::unwrap()` on a `None` value 1355 tests Error: 1 failure error: test failed, to rerun pass `--test filetests`
While the interpreter worked fine, it was the compiler that crashed. Is this expected?
afonso360 commented on issue #6844:
While the interpreter worked fine, it was the compiler that crashed. Is this expected?
Well, sort of. Ideally we would be able to compile all clif code, but 64 bit SIMD support is very incomplete both in the backends and in the interpreter itself. The only architectures that support it are AArch64 and RISC-V.
I think X86_64 has never supported it, so yeah I would expect it to crash there.
afonso360 edited a comment on issue #6844:
While the interpreter worked fine, it was the compiler that crashed. Is this expected?
Well, sort of. Ideally we would be able to compile all clif code, but 64 bit SIMD support is very incomplete both in the backends and in the interpreter itself. The only architectures that support it are AArch64 and RISC-V (And neither of those fully support it!).
I think X86_64 has never supported it, so yeah I would expect it to crash there.
gurry commented on issue #6844:
Okay, makes sense. Thanks :+1:
Last updated: Nov 22 2024 at 16:03 UTC