Debian Codegraph @

tests/snapshots/testsuite/proposals/wasm-3.0/table_grow.wast.json

raw
1 {
2 "source_filename": "tests/testsuite/proposals/wasm-3.0/table_grow.wast",
3 "commands": [
4 {
5 "type": "module",
6 "line": 1,
7 "filename": "table_grow.0.wasm",
8 "module_type": "binary"
9 },
10 {
11 "type": "assert_return",
12 "line": 25,
13 "action": {
14 "type": "invoke",
15 "field": "size",
16 "args": []
17 },
18 "expected": [
19 {
20 "type": "i32",
21 "value": "0"
22 }
23 ]
24 },
25 {
26 "type": "assert_trap",
27 "line": 26,
28 "action": {
29 "type": "invoke",
30 "field": "set",
31 "args": [
32 {
33 "type": "i32",
34 "value": "0"
35 },
36 {
37 "type": "externref",
38 "value": "2"
39 }
40 ]
41 },
42 "text": "out of bounds table access"
43 },
44 {
45 "type": "assert_trap",
46 "line": 27,
47 "action": {
48 "type": "invoke",
49 "field": "get",
50 "args": [
51 {
52 "type": "i32",
53 "value": "0"
54 }
55 ]
56 },
57 "text": "out of bounds table access"
58 },
59 {
60 "type": "assert_return",
61 "line": 29,
62 "action": {
63 "type": "invoke",
64 "field": "grow",
65 "args": [
66 {
67 "type": "i32",
68 "value": "1"
69 },
70 {
71 "type": "externref",
72 "value": "null"
73 }
74 ]
75 },
76 "expected": [
77 {
78 "type": "i32",
79 "value": "0"
80 }
81 ]
82 },
83 {
84 "type": "assert_return",
85 "line": 30,
86 "action": {
87 "type": "invoke",
88 "field": "size",
89 "args": []
90 },
91 "expected": [
92 {
93 "type": "i32",
94 "value": "1"
95 }
96 ]
97 },
98 {
99 "type": "assert_return",
100 "line": 31,
101 "action": {
102 "type": "invoke",
103 "field": "get",
104 "args": [
105 {
106 "type": "i32",
107 "value": "0"
108 }
109 ]
110 },
111 "expected": [
112 {
113 "type": "externref",
114 "value": "null"
115 }
116 ]
117 },
118 {
119 "type": "assert_return",
120 "line": 32,
121 "action": {
122 "type": "invoke",
123 "field": "set",
124 "args": [
125 {
126 "type": "i32",
127 "value": "0"
128 },
129 {
130 "type": "externref",
131 "value": "2"
132 }
133 ]
134 },
135 "expected": []
136 },
137 {
138 "type": "assert_return",
139 "line": 33,
140 "action": {
141 "type": "invoke",
142 "field": "get",
143 "args": [
144 {
145 "type": "i32",
146 "value": "0"
147 }
148 ]
149 },
150 "expected": [
151 {
152 "type": "externref",
153 "value": "2"
154 }
155 ]
156 },
157 {
158 "type": "assert_trap",
159 "line": 34,
160 "action": {
161 "type": "invoke",
162 "field": "set",
163 "args": [
164 {
165 "type": "i32",
166 "value": "1"
167 },
168 {
169 "type": "externref",
170 "value": "2"
171 }
172 ]
173 },
174 "text": "out of bounds table access"
175 },
176 {
177 "type": "assert_trap",
178 "line": 35,
179 "action": {
180 "type": "invoke",
181 "field": "get",
182 "args": [
183 {
184 "type": "i32",
185 "value": "1"
186 }
187 ]
188 },
189 "text": "out of bounds table access"
190 },
191 {
192 "type": "assert_return",
193 "line": 37,
194 "action": {
195 "type": "invoke",
196 "field": "grow-abbrev",
197 "args": [
198 {
199 "type": "i32",
200 "value": "4"
201 },
202 {
203 "type": "externref",
204 "value": "3"
205 }
206 ]
207 },
208 "expected": [
209 {
210 "type": "i32",
211 "value": "1"
212 }
213 ]
214 },
215 {
216 "type": "assert_return",
217 "line": 38,
218 "action": {
219 "type": "invoke",
220 "field": "size",
221 "args": []
222 },
223 "expected": [
224 {
225 "type": "i32",
226 "value": "5"
227 }
228 ]
229 },
230 {
231 "type": "assert_return",
232 "line": 39,
233 "action": {
234 "type": "invoke",
235 "field": "get",
236 "args": [
237 {
238 "type": "i32",
239 "value": "0"
240 }
241 ]
242 },
243 "expected": [
244 {
245 "type": "externref",
246 "value": "2"
247 }
248 ]
249 },
250 {
251 "type": "assert_return",
252 "line": 40,
253 "action": {
254 "type": "invoke",
255 "field": "set",
256 "args": [
257 {
258 "type": "i32",
259 "value": "0"
260 },
261 {
262 "type": "externref",
263 "value": "2"
264 }
265 ]
266 },
267 "expected": []
268 },
269 {
270 "type": "assert_return",
271 "line": 41,
272 "action": {
273 "type": "invoke",
274 "field": "get",
275 "args": [
276 {
277 "type": "i32",
278 "value": "0"
279 }
280 ]
281 },
282 "expected": [
283 {
284 "type": "externref",
285 "value": "2"
286 }
287 ]
288 },
289 {
290 "type": "assert_return",
291 "line": 42,
292 "action": {
293 "type": "invoke",
294 "field": "get",
295 "args": [
296 {
297 "type": "i32",
298 "value": "1"
299 }
300 ]
301 },
302 "expected": [
303 {
304 "type": "externref",
305 "value": "3"
306 }
307 ]
308 },
309 {
310 "type": "assert_return",
311 "line": 43,
312 "action": {
313 "type": "invoke",
314 "field": "get",
315 "args": [
316 {
317 "type": "i32",
318 "value": "4"
319 }
320 ]
321 },
322 "expected": [
323 {
324 "type": "externref",
325 "value": "3"
326 }
327 ]
328 },
329 {
330 "type": "assert_return",
331 "line": 44,
332 "action": {
333 "type": "invoke",
334 "field": "set",
335 "args": [
336 {
337 "type": "i32",
338 "value": "4"
339 },
340 {
341 "type": "externref",
342 "value": "4"
343 }
344 ]
345 },
346 "expected": []
347 },
348 {
349 "type": "assert_return",
350 "line": 45,
351 "action": {
352 "type": "invoke",
353 "field": "get",
354 "args": [
355 {
356 "type": "i32",
357 "value": "4"
358 }
359 ]
360 },
361 "expected": [
362 {
363 "type": "externref",
364 "value": "4"
365 }
366 ]
367 },
368 {
369 "type": "assert_trap",
370 "line": 46,
371 "action": {
372 "type": "invoke",
373 "field": "set",
374 "args": [
375 {
376 "type": "i32",
377 "value": "5"
378 },
379 {
380 "type": "externref",
381 "value": "2"
382 }
383 ]
384 },
385 "text": "out of bounds table access"
386 },
387 {
388 "type": "assert_trap",
389 "line": 47,
390 "action": {
391 "type": "invoke",
392 "field": "get",
393 "args": [
394 {
395 "type": "i32",
396 "value": "5"
397 }
398 ]
399 },
400 "text": "out of bounds table access"
401 },
402 {
403 "type": "assert_return",
404 "line": 50,
405 "action": {
406 "type": "invoke",
407 "field": "size-t64",
408 "args": []
409 },
410 "expected": [
411 {
412 "type": "i64",
413 "value": "0"
414 }
415 ]
416 },
417 {
418 "type": "assert_trap",
419 "line": 51,
420 "action": {
421 "type": "invoke",
422 "field": "set-t64",
423 "args": [
424 {
425 "type": "i64",
426 "value": "0"
427 },
428 {
429 "type": "externref",
430 "value": "2"
431 }
432 ]
433 },
434 "text": "out of bounds table access"
435 },
436 {
437 "type": "assert_trap",
438 "line": 52,
439 "action": {
440 "type": "invoke",
441 "field": "get-t64",
442 "args": [
443 {
444 "type": "i64",
445 "value": "0"
446 }
447 ]
448 },
449 "text": "out of bounds table access"
450 },
451 {
452 "type": "assert_return",
453 "line": 54,
454 "action": {
455 "type": "invoke",
456 "field": "grow-t64",
457 "args": [
458 {
459 "type": "i64",
460 "value": "1"
461 },
462 {
463 "type": "externref",
464 "value": "null"
465 }
466 ]
467 },
468 "expected": [
469 {
470 "type": "i64",
471 "value": "0"
472 }
473 ]
474 },
475 {
476 "type": "assert_return",
477 "line": 55,
478 "action": {
479 "type": "invoke",
480 "field": "size-t64",
481 "args": []
482 },
483 "expected": [
484 {
485 "type": "i64",
486 "value": "1"
487 }
488 ]
489 },
490 {
491 "type": "assert_return",
492 "line": 56,
493 "action": {
494 "type": "invoke",
495 "field": "get-t64",
496 "args": [
497 {
498 "type": "i64",
499 "value": "0"
500 }
501 ]
502 },
503 "expected": [
504 {
505 "type": "externref",
506 "value": "null"
507 }
508 ]
509 },
510 {
511 "type": "assert_return",
512 "line": 57,
513 "action": {
514 "type": "invoke",
515 "field": "set-t64",
516 "args": [
517 {
518 "type": "i64",
519 "value": "0"
520 },
521 {
522 "type": "externref",
523 "value": "2"
524 }
525 ]
526 },
527 "expected": []
528 },
529 {
530 "type": "assert_return",
531 "line": 58,
532 "action": {
533 "type": "invoke",
534 "field": "get-t64",
535 "args": [
536 {
537 "type": "i64",
538 "value": "0"
539 }
540 ]
541 },
542 "expected": [
543 {
544 "type": "externref",
545 "value": "2"
546 }
547 ]
548 },
549 {
550 "type": "assert_trap",
551 "line": 59,
552 "action": {
553 "type": "invoke",
554 "field": "set-t64",
555 "args": [
556 {
557 "type": "i64",
558 "value": "1"
559 },
560 {
561 "type": "externref",
562 "value": "2"
563 }
564 ]
565 },
566 "text": "out of bounds table access"
567 },
568 {
569 "type": "assert_trap",
570 "line": 60,
571 "action": {
572 "type": "invoke",
573 "field": "get-t64",
574 "args": [
575 {
576 "type": "i64",
577 "value": "1"
578 }
579 ]
580 },
581 "text": "out of bounds table access"
582 },
583 {
584 "type": "assert_return",
585 "line": 62,
586 "action": {
587 "type": "invoke",
588 "field": "grow-t64",
589 "args": [
590 {
591 "type": "i64",
592 "value": "4"
593 },
594 {
595 "type": "externref",
596 "value": "3"
597 }
598 ]
599 },
600 "expected": [
601 {
602 "type": "i64",
603 "value": "1"
604 }
605 ]
606 },
607 {
608 "type": "assert_return",
609 "line": 63,
610 "action": {
611 "type": "invoke",
612 "field": "size-t64",
613 "args": []
614 },
615 "expected": [
616 {
617 "type": "i64",
618 "value": "5"
619 }
620 ]
621 },
622 {
623 "type": "assert_return",
624 "line": 64,
625 "action": {
626 "type": "invoke",
627 "field": "get-t64",
628 "args": [
629 {
630 "type": "i64",
631 "value": "0"
632 }
633 ]
634 },
635 "expected": [
636 {
637 "type": "externref",
638 "value": "2"
639 }
640 ]
641 },
642 {
643 "type": "assert_return",
644 "line": 65,
645 "action": {
646 "type": "invoke",
647 "field": "set-t64",
648 "args": [
649 {
650 "type": "i64",
651 "value": "0"
652 },
653 {
654 "type": "externref",
655 "value": "2"
656 }
657 ]
658 },
659 "expected": []
660 },
661 {
662 "type": "assert_return",
663 "line": 66,
664 "action": {
665 "type": "invoke",
666 "field": "get-t64",
667 "args": [
668 {
669 "type": "i64",
670 "value": "0"
671 }
672 ]
673 },
674 "expected": [
675 {
676 "type": "externref",
677 "value": "2"
678 }
679 ]
680 },
681 {
682 "type": "assert_return",
683 "line": 67,
684 "action": {
685 "type": "invoke",
686 "field": "get-t64",
687 "args": [
688 {
689 "type": "i64",
690 "value": "1"
691 }
692 ]
693 },
694 "expected": [
695 {
696 "type": "externref",
697 "value": "3"
698 }
699 ]
700 },
701 {
702 "type": "assert_return",
703 "line": 68,
704 "action": {
705 "type": "invoke",
706 "field": "get-t64",
707 "args": [
708 {
709 "type": "i64",
710 "value": "4"
711 }
712 ]
713 },
714 "expected": [
715 {
716 "type": "externref",
717 "value": "3"
718 }
719 ]
720 },
721 {
722 "type": "assert_return",
723 "line": 69,
724 "action": {
725 "type": "invoke",
726 "field": "set-t64",
727 "args": [
728 {
729 "type": "i64",
730 "value": "4"
731 },
732 {
733 "type": "externref",
734 "value": "4"
735 }
736 ]
737 },
738 "expected": []
739 },
740 {
741 "type": "assert_return",
742 "line": 70,
743 "action": {
744 "type": "invoke",
745 "field": "get-t64",
746 "args": [
747 {
748 "type": "i64",
749 "value": "4"
750 }
751 ]
752 },
753 "expected": [
754 {
755 "type": "externref",
756 "value": "4"
757 }
758 ]
759 },
760 {
761 "type": "assert_trap",
762 "line": 71,
763 "action": {
764 "type": "invoke",
765 "field": "set-t64",
766 "args": [
767 {
768 "type": "i64",
769 "value": "5"
770 },
771 {
772 "type": "externref",
773 "value": "2"
774 }
775 ]
776 },
777 "text": "out of bounds table access"
778 },
779 {
780 "type": "assert_trap",
781 "line": 72,
782 "action": {
783 "type": "invoke",
784 "field": "get-t64",
785 "args": [
786 {
787 "type": "i64",
788 "value": "5"
789 }
790 ]
791 },
792 "text": "out of bounds table access"
793 },
794 {
795 "type": "module",
796 "line": 75,
797 "filename": "table_grow.1.wasm",
798 "module_type": "binary"
799 },
800 {
801 "type": "assert_return",
802 "line": 83,
803 "action": {
804 "type": "invoke",
805 "field": "grow",
806 "args": []
807 },
808 "expected": [
809 {
810 "type": "i32",
811 "value": "-1"
812 }
813 ]
814 },
815 {
816 "type": "module",
817 "line": 86,
818 "filename": "table_grow.2.wasm",
819 "module_type": "binary"
820 },
821 {
822 "type": "assert_return",
823 "line": 93,
824 "action": {
825 "type": "invoke",
826 "field": "grow",
827 "args": [
828 {
829 "type": "i32",
830 "value": "0"
831 }
832 ]
833 },
834 "expected": [
835 {
836 "type": "i32",
837 "value": "0"
838 }
839 ]
840 },
841 {
842 "type": "assert_return",
843 "line": 94,
844 "action": {
845 "type": "invoke",
846 "field": "grow",
847 "args": [
848 {
849 "type": "i32",
850 "value": "1"
851 }
852 ]
853 },
854 "expected": [
855 {
856 "type": "i32",
857 "value": "0"
858 }
859 ]
860 },
861 {
862 "type": "assert_return",
863 "line": 95,
864 "action": {
865 "type": "invoke",
866 "field": "grow",
867 "args": [
868 {
869 "type": "i32",
870 "value": "0"
871 }
872 ]
873 },
874 "expected": [
875 {
876 "type": "i32",
877 "value": "1"
878 }
879 ]
880 },
881 {
882 "type": "assert_return",
883 "line": 96,
884 "action": {
885 "type": "invoke",
886 "field": "grow",
887 "args": [
888 {
889 "type": "i32",
890 "value": "2"
891 }
892 ]
893 },
894 "expected": [
895 {
896 "type": "i32",
897 "value": "1"
898 }
899 ]
900 },
901 {
902 "type": "assert_return",
903 "line": 97,
904 "action": {
905 "type": "invoke",
906 "field": "grow",
907 "args": [
908 {
909 "type": "i32",
910 "value": "800"
911 }
912 ]
913 },
914 "expected": [
915 {
916 "type": "i32",
917 "value": "3"
918 }
919 ]
920 },
921 {
922 "type": "module",
923 "line": 100,
924 "filename": "table_grow.3.wasm",
925 "module_type": "binary"
926 },
927 {
928 "type": "assert_return",
929 "line": 107,
930 "action": {
931 "type": "invoke",
932 "field": "grow",
933 "args": [
934 {
935 "type": "i32",
936 "value": "0"
937 }
938 ]
939 },
940 "expected": [
941 {
942 "type": "i32",
943 "value": "0"
944 }
945 ]
946 },
947 {
948 "type": "assert_return",
949 "line": 108,
950 "action": {
951 "type": "invoke",
952 "field": "grow",
953 "args": [
954 {
955 "type": "i32",
956 "value": "1"
957 }
958 ]
959 },
960 "expected": [
961 {
962 "type": "i32",
963 "value": "0"
964 }
965 ]
966 },
967 {
968 "type": "assert_return",
969 "line": 109,
970 "action": {
971 "type": "invoke",
972 "field": "grow",
973 "args": [
974 {
975 "type": "i32",
976 "value": "1"
977 }
978 ]
979 },
980 "expected": [
981 {
982 "type": "i32",
983 "value": "1"
984 }
985 ]
986 },
987 {
988 "type": "assert_return",
989 "line": 110,
990 "action": {
991 "type": "invoke",
992 "field": "grow",
993 "args": [
994 {
995 "type": "i32",
996 "value": "2"
997 }
998 ]
999 },
1000 "expected": [
1001 {
1002 "type": "i32",
1003 "value": "2"
1004 }
1005 ]
1006 },
1007 {
1008 "type": "assert_return",
1009 "line": 111,
1010 "action": {
1011 "type": "invoke",
1012 "field": "grow",
1013 "args": [
1014 {
1015 "type": "i32",
1016 "value": "6"
1017 }
1018 ]
1019 },
1020 "expected": [
1021 {
1022 "type": "i32",
1023 "value": "4"
1024 }
1025 ]
1026 },
1027 {
1028 "type": "assert_return",
1029 "line": 112,
1030 "action": {
1031 "type": "invoke",
1032 "field": "grow",
1033 "args": [
1034 {
1035 "type": "i32",
1036 "value": "0"
1037 }
1038 ]
1039 },
1040 "expected": [
1041 {
1042 "type": "i32",
1043 "value": "10"
1044 }
1045 ]
1046 },
1047 {
1048 "type": "assert_return",
1049 "line": 113,
1050 "action": {
1051 "type": "invoke",
1052 "field": "grow",
1053 "args": [
1054 {
1055 "type": "i32",
1056 "value": "1"
1057 }
1058 ]
1059 },
1060 "expected": [
1061 {
1062 "type": "i32",
1063 "value": "-1"
1064 }
1065 ]
1066 },
1067 {
1068 "type": "assert_return",
1069 "line": 114,
1070 "action": {
1071 "type": "invoke",
1072 "field": "grow",
1073 "args": [
1074 {
1075 "type": "i32",
1076 "value": "65536"
1077 }
1078 ]
1079 },
1080 "expected": [
1081 {
1082 "type": "i32",
1083 "value": "-1"
1084 }
1085 ]
1086 },
1087 {
1088 "type": "module",
1089 "line": 117,
1090 "filename": "table_grow.4.wasm",
1091 "module_type": "binary"
1092 },
1093 {
1094 "type": "assert_return",
1095 "line": 139,
1096 "action": {
1097 "type": "invoke",
1098 "field": "check-table-null",
1099 "args": [
1100 {
1101 "type": "i32",
1102 "value": "0"
1103 },
1104 {
1105 "type": "i32",
1106 "value": "9"
1107 }
1108 ]
1109 },
1110 "expected": [
1111 {
1112 "type": "funcref",
1113 "value": "null"
1114 }
1115 ]
1116 },
1117 {
1118 "type": "assert_return",
1119 "line": 140,
1120 "action": {
1121 "type": "invoke",
1122 "field": "grow",
1123 "args": [
1124 {
1125 "type": "i32",
1126 "value": "10"
1127 }
1128 ]
1129 },
1130 "expected": [
1131 {
1132 "type": "i32",
1133 "value": "10"
1134 }
1135 ]
1136 },
1137 {
1138 "type": "assert_return",
1139 "line": 141,
1140 "action": {
1141 "type": "invoke",
1142 "field": "check-table-null",
1143 "args": [
1144 {
1145 "type": "i32",
1146 "value": "0"
1147 },
1148 {
1149 "type": "i32",
1150 "value": "19"
1151 }
1152 ]
1153 },
1154 "expected": [
1155 {
1156 "type": "funcref",
1157 "value": "null"
1158 }
1159 ]
1160 },
1161 {
1162 "type": "module",
1163 "line": 144,
1164 "name": "Tgt",
1165 "filename": "table_grow.5.wasm",
1166 "module_type": "binary"
1167 },
1168 {
1169 "type": "register",
1170 "line": 148,
1171 "name": "Tgt",
1172 "as": "grown-table"
1173 },
1174 {
1175 "type": "assert_return",
1176 "line": 149,
1177 "action": {
1178 "type": "invoke",
1179 "module": "Tgt",
1180 "field": "grow",
1181 "args": []
1182 },
1183 "expected": [
1184 {
1185 "type": "i32",
1186 "value": "1"
1187 }
1188 ]
1189 },
1190 {
1191 "type": "module",
1192 "line": 150,
1193 "name": "Tgit1",
1194 "filename": "table_grow.6.wasm",
1195 "module_type": "binary"
1196 },
1197 {
1198 "type": "register",
1199 "line": 155,
1200 "name": "Tgit1",
1201 "as": "grown-imported-table"
1202 },
1203 {
1204 "type": "assert_return",
1205 "line": 156,
1206 "action": {
1207 "type": "invoke",
1208 "module": "Tgit1",
1209 "field": "grow",
1210 "args": []
1211 },
1212 "expected": [
1213 {
1214 "type": "i32",
1215 "value": "2"
1216 }
1217 ]
1218 },
1219 {
1220 "type": "module",
1221 "line": 157,
1222 "name": "Tgit2",
1223 "filename": "table_grow.7.wasm",
1224 "module_type": "binary"
1225 },
1226 {
1227 "type": "assert_return",
1228 "line": 162,
1229 "action": {
1230 "type": "invoke",
1231 "module": "Tgit2",
1232 "field": "size",
1233 "args": []
1234 },
1235 "expected": [
1236 {
1237 "type": "i32",
1238 "value": "3"
1239 }
1240 ]
1241 },
1242 {
1243 "type": "assert_invalid",
1244 "line": 168,
1245 "filename": "table_grow.8.wasm",
1246 "module_type": "binary",
1247 "text": "type mismatch"
1248 },
1249 {
1250 "type": "assert_invalid",
1251 "line": 177,
1252 "filename": "table_grow.9.wasm",
1253 "module_type": "binary",
1254 "text": "type mismatch"
1255 },
1256 {
1257 "type": "assert_invalid",
1258 "line": 186,
1259 "filename": "table_grow.10.wasm",
1260 "module_type": "binary",
1261 "text": "type mismatch"
1262 },
1263 {
1264 "type": "assert_invalid",
1265 "line": 195,
1266 "filename": "table_grow.11.wasm",
1267 "module_type": "binary",
1268 "text": "type mismatch"
1269 },
1270 {
1271 "type": "assert_invalid",
1272 "line": 204,
1273 "filename": "table_grow.12.wasm",
1274 "module_type": "binary",
1275 "text": "type mismatch"
1276 },
1277 {
1278 "type": "assert_invalid",
1279 "line": 214,
1280 "filename": "table_grow.13.wasm",
1281 "module_type": "binary",
1282 "text": "type mismatch"
1283 },
1284 {
1285 "type": "assert_invalid",
1286 "line": 223,
1287 "filename": "table_grow.14.wasm",
1288 "module_type": "binary",
1289 "text": "type mismatch"
1290 }
1291 ]
1292 }