Debian Codegraph @

js/src/jit-test/tests/wasm/builtin-modules/js-string/inline-code.js

raw
1 // |jit-test| skip-if: !wasmJSStringBuiltinsEnabled() || !hasDisassembler() || wasmCompileMode() != "ion" || !getBuildConfiguration("arm64"); include:codegen-arm64-test.js
2
3 setJitCompilerOption("jit.full-debug-checks", 0);
4
5 codegenTestARM64_adhoc(`
6 (func $testImp
7 (import "wasm:js-string" "test")
8 (param externref)
9 (result i32)
10 )
11 (export "test" (func $testImp))`,
12 'test',
13 `92400401 and x1, x0, #0x3
14 7100083f cmp w1, #0x2 \\(2\\)
15 54000060 b\\.eq #\\+0xc \\(addr .*\\)
16 52800000 mov w0, #0x0
17 14000002 b #\\+0x8 \\(addr .*\\)
18 52800020 mov w0, #0x1`,
19 {features: {builtins: ["js-string"]}}
20 );
21
22 codegenTestARM64_adhoc(`
23 (func $castImp
24 (import "wasm:js-string" "cast")
25 (param externref)
26 (result (ref extern))
27 )
28 (export "cast" (func $castImp))`,
29 'cast',
30 `92400401 and x1, x0, #0x3
31 7100083f cmp w1, #0x2 \\(2\\)
32 54000040 b.eq #\\+0x8 \\(addr .*\\)
33 d4a00000 unimplemented \\(Exception\\)`,
34 {features: {builtins: ["js-string"]}}
35 );