From 304658d67102d3ddd5aa8ea59bcc94402d8338b8 Mon Sep 17 00:00:00 2001 From: Abbas Mashayekh Date: Wed, 21 Apr 2021 03:41:32 +0430 Subject: Fix element segment ordering in Print (#3818) We used to print active element segments right after corresponding tables, and passive segments came after those. We didn't print internal segment names, and empty segments weren't being printed at all. This meant that there was no way for instructions to refer to those table segments after round tripping. This will fix those issues by printing segments in the order they were defined, including segment names when necessary and not omitting empty segments anymore. --- ...y_pass-arg=asyncify-addlist@foo_pass-arg=asyncify-ignore-indirect.txt | 1 + 1 file changed, 1 insertion(+) (limited to 'test/passes/asyncify_pass-arg=asyncify-addlist@foo_pass-arg=asyncify-ignore-indirect.txt') diff --git a/test/passes/asyncify_pass-arg=asyncify-addlist@foo_pass-arg=asyncify-ignore-indirect.txt b/test/passes/asyncify_pass-arg=asyncify-addlist@foo_pass-arg=asyncify-ignore-indirect.txt index 152fba58b..213ead5aa 100644 --- a/test/passes/asyncify_pass-arg=asyncify-addlist@foo_pass-arg=asyncify-ignore-indirect.txt +++ b/test/passes/asyncify_pass-arg=asyncify-addlist@foo_pass-arg=asyncify-ignore-indirect.txt @@ -7,6 +7,7 @@ (global $__asyncify_data (mut i32) (i32.const 0)) (memory $0 1 2) (table $0 1 funcref) + (elem (i32.const 0)) (export "asyncify_start_unwind" (func $asyncify_start_unwind)) (export "asyncify_stop_unwind" (func $asyncify_stop_unwind)) (export "asyncify_start_rewind" (func $asyncify_start_rewind)) -- cgit v1.2.3