wa-lang.org/wazero@v1.0.2/internal/integration_test/spectest/v2/testdata/global.json (about) 1 {"source_filename": "./global.wast", 2 "commands": [ 3 {"type": "module", "line": 3, "filename": "global.0.wasm"}, 4 {"type": "assert_return", "line": 196, "action": {"type": "invoke", "field": "get-a", "args": []}, "expected": [{"type": "i32", "value": "4294967294"}]}, 5 {"type": "assert_return", "line": 197, "action": {"type": "invoke", "field": "get-b", "args": []}, "expected": [{"type": "i64", "value": "18446744073709551611"}]}, 6 {"type": "assert_return", "line": 198, "action": {"type": "invoke", "field": "get-r", "args": []}, "expected": [{"type": "externref", "value": "null"}]}, 7 {"type": "assert_return", "line": 199, "action": {"type": "invoke", "field": "get-mr", "args": []}, "expected": [{"type": "externref", "value": "null"}]}, 8 {"type": "assert_return", "line": 200, "action": {"type": "invoke", "field": "get-x", "args": []}, "expected": [{"type": "i32", "value": "4294967284"}]}, 9 {"type": "assert_return", "line": 201, "action": {"type": "invoke", "field": "get-y", "args": []}, "expected": [{"type": "i64", "value": "18446744073709551601"}]}, 10 {"type": "assert_return", "line": 202, "action": {"type": "invoke", "field": "get-z1", "args": []}, "expected": [{"type": "i32", "value": "666"}]}, 11 {"type": "assert_return", "line": 203, "action": {"type": "invoke", "field": "get-z2", "args": []}, "expected": [{"type": "i64", "value": "666"}]}, 12 {"type": "assert_return", "line": 205, "action": {"type": "invoke", "field": "get-3", "args": []}, "expected": [{"type": "f32", "value": "3225419776"}]}, 13 {"type": "assert_return", "line": 206, "action": {"type": "invoke", "field": "get-4", "args": []}, "expected": [{"type": "f64", "value": "13839561654909534208"}]}, 14 {"type": "assert_return", "line": 207, "action": {"type": "invoke", "field": "get-7", "args": []}, "expected": [{"type": "f32", "value": "3243245568"}]}, 15 {"type": "assert_return", "line": 208, "action": {"type": "invoke", "field": "get-8", "args": []}, "expected": [{"type": "f64", "value": "13847442954257432576"}]}, 16 {"type": "assert_return", "line": 210, "action": {"type": "invoke", "field": "set-x", "args": [{"type": "i32", "value": "6"}]}, "expected": []}, 17 {"type": "assert_return", "line": 211, "action": {"type": "invoke", "field": "set-y", "args": [{"type": "i64", "value": "7"}]}, "expected": []}, 18 {"type": "assert_return", "line": 213, "action": {"type": "invoke", "field": "set-7", "args": [{"type": "f32", "value": "1090519040"}]}, "expected": []}, 19 {"type": "assert_return", "line": 214, "action": {"type": "invoke", "field": "set-8", "args": [{"type": "f64", "value": "4621256167635550208"}]}, "expected": []}, 20 {"type": "assert_return", "line": 216, "action": {"type": "invoke", "field": "get-x", "args": []}, "expected": [{"type": "i32", "value": "6"}]}, 21 {"type": "assert_return", "line": 217, "action": {"type": "invoke", "field": "get-y", "args": []}, "expected": [{"type": "i64", "value": "7"}]}, 22 {"type": "assert_return", "line": 218, "action": {"type": "invoke", "field": "get-7", "args": []}, "expected": [{"type": "f32", "value": "1090519040"}]}, 23 {"type": "assert_return", "line": 219, "action": {"type": "invoke", "field": "get-8", "args": []}, "expected": [{"type": "f64", "value": "4621256167635550208"}]}, 24 {"type": "assert_return", "line": 221, "action": {"type": "invoke", "field": "set-7", "args": [{"type": "f32", "value": "1090519040"}]}, "expected": []}, 25 {"type": "assert_return", "line": 222, "action": {"type": "invoke", "field": "set-8", "args": [{"type": "f64", "value": "4621256167635550208"}]}, "expected": []}, 26 {"type": "assert_return", "line": 223, "action": {"type": "invoke", "field": "set-mr", "args": [{"type": "externref", "value": "10"}]}, "expected": []}, 27 {"type": "assert_return", "line": 225, "action": {"type": "invoke", "field": "get-x", "args": []}, "expected": [{"type": "i32", "value": "6"}]}, 28 {"type": "assert_return", "line": 226, "action": {"type": "invoke", "field": "get-y", "args": []}, "expected": [{"type": "i64", "value": "7"}]}, 29 {"type": "assert_return", "line": 227, "action": {"type": "invoke", "field": "get-7", "args": []}, "expected": [{"type": "f32", "value": "1090519040"}]}, 30 {"type": "assert_return", "line": 228, "action": {"type": "invoke", "field": "get-8", "args": []}, "expected": [{"type": "f64", "value": "4621256167635550208"}]}, 31 {"type": "assert_return", "line": 229, "action": {"type": "invoke", "field": "get-mr", "args": []}, "expected": [{"type": "externref", "value": "10"}]}, 32 {"type": "assert_return", "line": 231, "action": {"type": "invoke", "field": "as-select-first", "args": []}, "expected": [{"type": "i32", "value": "6"}]}, 33 {"type": "assert_return", "line": 232, "action": {"type": "invoke", "field": "as-select-mid", "args": []}, "expected": [{"type": "i32", "value": "2"}]}, 34 {"type": "assert_return", "line": 233, "action": {"type": "invoke", "field": "as-select-last", "args": []}, "expected": [{"type": "i32", "value": "2"}]}, 35 {"type": "assert_return", "line": 235, "action": {"type": "invoke", "field": "as-loop-first", "args": []}, "expected": [{"type": "i32", "value": "6"}]}, 36 {"type": "assert_return", "line": 236, "action": {"type": "invoke", "field": "as-loop-mid", "args": []}, "expected": [{"type": "i32", "value": "6"}]}, 37 {"type": "assert_return", "line": 237, "action": {"type": "invoke", "field": "as-loop-last", "args": []}, "expected": [{"type": "i32", "value": "6"}]}, 38 {"type": "assert_return", "line": 239, "action": {"type": "invoke", "field": "as-if-condition", "args": []}, "expected": [{"type": "i32", "value": "2"}]}, 39 {"type": "assert_return", "line": 240, "action": {"type": "invoke", "field": "as-if-then", "args": []}, "expected": [{"type": "i32", "value": "6"}]}, 40 {"type": "assert_return", "line": 241, "action": {"type": "invoke", "field": "as-if-else", "args": []}, "expected": [{"type": "i32", "value": "6"}]}, 41 {"type": "assert_return", "line": 243, "action": {"type": "invoke", "field": "as-br_if-first", "args": []}, "expected": [{"type": "i32", "value": "6"}]}, 42 {"type": "assert_return", "line": 244, "action": {"type": "invoke", "field": "as-br_if-last", "args": []}, "expected": [{"type": "i32", "value": "2"}]}, 43 {"type": "assert_return", "line": 246, "action": {"type": "invoke", "field": "as-br_table-first", "args": []}, "expected": [{"type": "i32", "value": "6"}]}, 44 {"type": "assert_return", "line": 247, "action": {"type": "invoke", "field": "as-br_table-last", "args": []}, "expected": [{"type": "i32", "value": "2"}]}, 45 {"type": "assert_return", "line": 249, "action": {"type": "invoke", "field": "as-call_indirect-first", "args": []}, "expected": [{"type": "i32", "value": "6"}]}, 46 {"type": "assert_return", "line": 250, "action": {"type": "invoke", "field": "as-call_indirect-mid", "args": []}, "expected": [{"type": "i32", "value": "2"}]}, 47 {"type": "assert_trap", "line": 251, "action": {"type": "invoke", "field": "as-call_indirect-last", "args": []}, "text": "undefined element", "expected": [{"type": "i32"}]}, 48 {"type": "assert_return", "line": 253, "action": {"type": "invoke", "field": "as-store-first", "args": []}, "expected": []}, 49 {"type": "assert_return", "line": 254, "action": {"type": "invoke", "field": "as-store-last", "args": []}, "expected": []}, 50 {"type": "assert_return", "line": 255, "action": {"type": "invoke", "field": "as-load-operand", "args": []}, "expected": [{"type": "i32", "value": "1"}]}, 51 {"type": "assert_return", "line": 256, "action": {"type": "invoke", "field": "as-memory.grow-value", "args": []}, "expected": [{"type": "i32", "value": "1"}]}, 52 {"type": "assert_return", "line": 258, "action": {"type": "invoke", "field": "as-call-value", "args": []}, "expected": [{"type": "i32", "value": "6"}]}, 53 {"type": "assert_return", "line": 260, "action": {"type": "invoke", "field": "as-return-value", "args": []}, "expected": [{"type": "i32", "value": "6"}]}, 54 {"type": "assert_return", "line": 261, "action": {"type": "invoke", "field": "as-drop-operand", "args": []}, "expected": []}, 55 {"type": "assert_return", "line": 262, "action": {"type": "invoke", "field": "as-br-value", "args": []}, "expected": [{"type": "i32", "value": "6"}]}, 56 {"type": "assert_return", "line": 264, "action": {"type": "invoke", "field": "as-local.set-value", "args": [{"type": "i32", "value": "1"}]}, "expected": [{"type": "i32", "value": "6"}]}, 57 {"type": "assert_return", "line": 265, "action": {"type": "invoke", "field": "as-local.tee-value", "args": [{"type": "i32", "value": "1"}]}, "expected": [{"type": "i32", "value": "6"}]}, 58 {"type": "assert_return", "line": 266, "action": {"type": "invoke", "field": "as-global.set-value", "args": []}, "expected": [{"type": "i32", "value": "6"}]}, 59 {"type": "assert_return", "line": 268, "action": {"type": "invoke", "field": "as-unary-operand", "args": []}, "expected": [{"type": "i32", "value": "0"}]}, 60 {"type": "assert_return", "line": 269, "action": {"type": "invoke", "field": "as-binary-operand", "args": []}, "expected": [{"type": "i32", "value": "36"}]}, 61 {"type": "assert_return", "line": 270, "action": {"type": "invoke", "field": "as-compare-operand", "args": []}, "expected": [{"type": "i32", "value": "1"}]}, 62 {"type": "assert_invalid", "line": 273, "filename": "global.1.wasm", "text": "global is immutable", "module_type": "binary"}, 63 {"type": "assert_invalid", "line": 278, "filename": "global.2.wasm", "text": "global is immutable", "module_type": "binary"}, 64 {"type": "module", "line": 283, "filename": "global.3.wasm"}, 65 {"type": "module", "line": 284, "filename": "global.4.wasm"}, 66 {"type": "assert_invalid", "line": 287, "filename": "global.5.wasm", "text": "constant expression required", "module_type": "binary"}, 67 {"type": "assert_invalid", "line": 292, "filename": "global.6.wasm", "text": "constant expression required", "module_type": "binary"}, 68 {"type": "assert_invalid", "line": 297, "filename": "global.7.wasm", "text": "constant expression required", "module_type": "binary"}, 69 {"type": "assert_invalid", "line": 302, "filename": "global.8.wasm", "text": "constant expression required", "module_type": "binary"}, 70 {"type": "assert_invalid", "line": 307, "filename": "global.9.wasm", "text": "constant expression required", "module_type": "binary"}, 71 {"type": "assert_invalid", "line": 312, "filename": "global.10.wasm", "text": "constant expression required", "module_type": "binary"}, 72 {"type": "assert_invalid", "line": 317, "filename": "global.11.wasm", "text": "type mismatch", "module_type": "binary"}, 73 {"type": "assert_invalid", "line": 322, "filename": "global.12.wasm", "text": "type mismatch", "module_type": "binary"}, 74 {"type": "assert_invalid", "line": 327, "filename": "global.13.wasm", "text": "type mismatch", "module_type": "binary"}, 75 {"type": "assert_invalid", "line": 332, "filename": "global.14.wasm", "text": "type mismatch", "module_type": "binary"}, 76 {"type": "assert_invalid", "line": 337, "filename": "global.15.wasm", "text": "type mismatch", "module_type": "binary"}, 77 {"type": "assert_invalid", "line": 342, "filename": "global.16.wasm", "text": "type mismatch", "module_type": "binary"}, 78 {"type": "assert_invalid", "line": 347, "filename": "global.17.wasm", "text": "unknown global", "module_type": "binary"}, 79 {"type": "assert_invalid", "line": 352, "filename": "global.18.wasm", "text": "unknown global", "module_type": "binary"}, 80 {"type": "assert_invalid", "line": 356, "filename": "global.19.wasm", "text": "unknown global", "module_type": "binary"}, 81 {"type": "assert_invalid", "line": 361, "filename": "global.20.wasm", "text": "unknown global", "module_type": "binary"}, 82 {"type": "assert_invalid", "line": 366, "filename": "global.21.wasm", "text": "unknown global", "module_type": "binary"}, 83 {"type": "assert_invalid", "line": 371, "filename": "global.22.wasm", "text": "constant expression required", "module_type": "binary"}, 84 {"type": "module", "line": 375, "filename": "global.23.wasm"}, 85 {"type": "assert_malformed", "line": 379, "filename": "global.24.wasm", "text": "malformed mutability", "module_type": "binary"}, 86 {"type": "assert_malformed", "line": 392, "filename": "global.25.wasm", "text": "malformed mutability", "module_type": "binary"}, 87 {"type": "module", "line": 405, "filename": "global.26.wasm"}, 88 {"type": "assert_malformed", "line": 409, "filename": "global.27.wasm", "text": "malformed mutability", "module_type": "binary"}, 89 {"type": "assert_malformed", "line": 421, "filename": "global.28.wasm", "text": "malformed mutability", "module_type": "binary"}, 90 {"type": "assert_invalid", "line": 435, "filename": "global.29.wasm", "text": "unknown global", "module_type": "binary"}, 91 {"type": "assert_invalid", "line": 440, "filename": "global.30.wasm", "text": "unknown global", "module_type": "binary"}, 92 {"type": "assert_invalid", "line": 448, "filename": "global.31.wasm", "text": "unknown global", "module_type": "binary"}, 93 {"type": "assert_invalid", "line": 456, "filename": "global.32.wasm", "text": "unknown global", "module_type": "binary"}, 94 {"type": "assert_invalid", "line": 466, "filename": "global.33.wasm", "text": "unknown global", "module_type": "binary"}, 95 {"type": "assert_invalid", "line": 471, "filename": "global.34.wasm", "text": "unknown global", "module_type": "binary"}, 96 {"type": "assert_invalid", "line": 479, "filename": "global.35.wasm", "text": "unknown global", "module_type": "binary"}, 97 {"type": "assert_invalid", "line": 487, "filename": "global.36.wasm", "text": "unknown global", "module_type": "binary"}, 98 {"type": "assert_invalid", "line": 497, "filename": "global.37.wasm", "text": "type mismatch", "module_type": "binary"}, 99 {"type": "assert_invalid", "line": 506, "filename": "global.38.wasm", "text": "type mismatch", "module_type": "binary"}, 100 {"type": "assert_invalid", "line": 516, "filename": "global.39.wasm", "text": "type mismatch", "module_type": "binary"}, 101 {"type": "assert_invalid", "line": 526, "filename": "global.40.wasm", "text": "type mismatch", "module_type": "binary"}, 102 {"type": "assert_invalid", "line": 536, "filename": "global.41.wasm", "text": "type mismatch", "module_type": "binary"}, 103 {"type": "assert_invalid", "line": 546, "filename": "global.42.wasm", "text": "type mismatch", "module_type": "binary"}, 104 {"type": "assert_invalid", "line": 556, "filename": "global.43.wasm", "text": "type mismatch", "module_type": "binary"}, 105 {"type": "assert_invalid", "line": 566, "filename": "global.44.wasm", "text": "type mismatch", "module_type": "binary"}, 106 {"type": "assert_invalid", "line": 576, "filename": "global.45.wasm", "text": "type mismatch", "module_type": "binary"}, 107 {"type": "assert_invalid", "line": 585, "filename": "global.46.wasm", "text": "type mismatch", "module_type": "binary"}, 108 {"type": "assert_invalid", "line": 594, "filename": "global.47.wasm", "text": "type mismatch", "module_type": "binary"}, 109 {"type": "assert_invalid", "line": 604, "filename": "global.48.wasm", "text": "type mismatch", "module_type": "binary"}, 110 {"type": "assert_malformed", "line": 622, "filename": "global.49.wat", "text": "duplicate global", "module_type": "text"}, 111 {"type": "assert_malformed", "line": 626, "filename": "global.50.wat", "text": "duplicate global", "module_type": "text"}, 112 {"type": "assert_malformed", "line": 630, "filename": "global.51.wat", "text": "duplicate global", "module_type": "text"}]}