Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit ead9aca

Browse files
mkustermannCommit Queue
authored and
Commit Queue
committed
[dart2wasm] Roll binaryen to newest version
It brings in some optimizations for constants: e.g. a string access that used to look like (global X (..., (global.get A) (struct.new))) ... (global.get X) (struct.get) now looks like: (global.get A) See * WebAssembly/binaryen#8002 * WebAssembly/binaryen#8016 Change-Id: I1b2b444867ea53e6e454e93a400dd17aa8fc53fc Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/462440 Commit-Queue: Martin Kustermann <kustermann@google.com> Reviewed-by: Ömer Ağacan <omersa@google.com>
1 parent 1125460 commit ead9aca

File tree

9 files changed

+31
-32
lines changed

9 files changed

+31
-32
lines changed

‎DEPS‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ vars = {
9696
### /third_party/ dependencies
9797

9898
# Prefer to use hashes of binaryen that have been reviewed & rolled into g3.
99-
"binaryen_rev" : "23f7af14bba0139e61bb8f403c4ef53dfee44023",
99+
"binaryen_rev" : "fc3374548433eafaab08985ef0754d19273391d2",
100100
"boringssl_rev": "d409d1853233ede6b69d25c6fd4529fd59791b6d",
101101
"browser-compat-data_tag": "ac8cae697014da1ff7124fba33b0b4245cc6cd1b", # v1.0.22
102102
"cpu_features_rev": "936b9ab5515dead115606559502e3864958f7f6e",

‎pkg/dart2wasm/test/ir_tests/dyn_closure.wat‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,11 +24,11 @@
2424
(field $vtable (ref $#Vtable-0-2))
2525
(field $functionType (ref $_FunctionType)))))
2626
(type $#DummyStruct <...>)
27-
(global $global3 (ref $#DummyStruct) <...>)
2827
(global $"C1 WasmArray<_Type>[0]" (ref $Array<_Type>) <...>)
29-
(global $"C28 _InterfaceType" (ref $_InterfaceType) <...>)
3028
(global $"C311 WasmArray<_NamedParameter>[0]" (ref $Array<_NamedParameter>) <...>)
3129
(global $"C337 _TopType" (ref $_TopType) <...>)
30+
(global $"C28 _InterfaceType" (ref $_InterfaceType) <...>)
31+
(global $global3 (ref $#DummyStruct) <...>)
3232
(global $"C341 foo tear-off" (ref $#Closure-0-2)
3333
(i32.const 55)
3434
(i32.const 0)

‎pkg/dart2wasm/test/ir_tests/dyn_closure_function_apply.wat‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,15 +24,15 @@
2424
(field $vtable (ref $#Vtable-0-2))
2525
(field $functionType (ref $_FunctionType)))))
2626
(type $#DummyStruct <...>)
27-
(global $global3 (ref $#DummyStruct) <...>)
2827
(global $"C1 WasmArray<_Type>[0]" (ref $Array<_Type>) <...>)
29-
(global $"C28 _InterfaceType" (ref $_InterfaceType) <...>)
3028
(global $"C311 WasmArray<_NamedParameter>[0]" (ref $Array<_NamedParameter>) <...>)
3129
(global $"C337 _TopType" (ref $_TopType) <...>)
30+
(global $"C28 _InterfaceType" (ref $_InterfaceType) <...>)
31+
(global $global2 (ref $#DummyStruct) <...>)
3232
(global $"C341 foo tear-off" (ref $#Closure-0-2)
3333
(i32.const 55)
3434
(i32.const 0)
35-
(global.get $global3)
35+
(global.get $global2)
3636
(ref.func $"closure arguments dispatcher representation=0-2")
3737
(ref.func $"foo tear-off trampoline")
3838
(ref.func $"foo tear-off trampoline_303")
@@ -58,7 +58,7 @@
5858
(global $"C346 bar tear-off" (ref $#Closure-0-2)
5959
(i32.const 55)
6060
(i32.const 0)
61-
(global.get $global3)
61+
(global.get $global2)
6262
(ref.func $"closure arguments dispatcher representation=0-2")
6363
(ref.func $"bar tear-off trampoline")
6464
(ref.func $"bar tear-off trampoline_308")

‎pkg/dart2wasm/test/ir_tests/dyn_closure_function_apply_named.wat‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,15 +22,15 @@
2222
(field $functionType (ref $_FunctionType)))))
2323
(type $_TopType <...>)
2424
(type $#DummyStruct <...>)
25-
(global $global3 (ref $#DummyStruct) <...>)
2625
(global $"C1 WasmArray<_Type>[0]" (ref $Array<_Type>) <...>)
27-
(global $"C28 _InterfaceType" (ref $_InterfaceType) <...>)
2826
(global $"C311 WasmArray<_NamedParameter>[0]" (ref $Array<_NamedParameter>) <...>)
2927
(global $"C337 _TopType" (ref $_TopType) <...>)
28+
(global $"C28 _InterfaceType" (ref $_InterfaceType) <...>)
29+
(global $global2 (ref $#DummyStruct) <...>)
3030
(global $"C341 foo tear-off" (ref $#Closure-0-2)
3131
(i32.const 55)
3232
(i32.const 0)
33-
(global.get $global3)
33+
(global.get $global2)
3434
(ref.func $"foo tear-off dynamic call entry")
3535
(ref.func $"foo tear-off trampoline_307")
3636
(struct.new $#Vtable-0-2)
@@ -56,7 +56,7 @@
5656
(global $"C346 bar tear-off" (ref $#Closure-0-2)
5757
(i32.const 55)
5858
(i32.const 0)
59-
(global.get $global3)
59+
(global.get $global2)
6060
(ref.func $"bar tear-off dynamic call entry")
6161
(ref.func $"bar tear-off trampoline_313")
6262
(struct.new $#Vtable-0-2)

‎pkg/dart2wasm/test/ir_tests/interop.bool.wat‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,12 +7,12 @@
77
(func $"dart2wasm._150 (import)" (import "dart2wasm" "_150") (param i32) (result externref))
88
(global $"C2 false" (ref $#Top) <...>)
99
(global $"C40 true" (ref $#Top) <...>)
10-
(global $"boolValueNullable initialized" (mut i32) <...>)
11-
(global $boolValueNullable (mut (ref null $#Top)) <...>)
12-
(global $"ktrue initialized" (mut i32) <...>)
1310
(global $ktrue (mut i32) <...>)
14-
(global $"boolValue initialized" (mut i32) <...>)
1511
(global $boolValue (mut i32) <...>)
12+
(global $"ktrue initialized" (mut i32) <...>)
13+
(global $"boolValue initialized" (mut i32) <...>)
14+
(global $"boolValueNullable initialized" (mut i32) <...>)
15+
(global $boolValueNullable (mut (ref null $#Top)) <...>)
1616
(func $"testBoolConstant <noInline>"
1717
(local $var0 externref)
1818
i32.const 1

‎pkg/dart2wasm/test/ir_tests/interop.double.wat‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,12 @@
88
(func $"dart2wasm._275 (import)" (import "dart2wasm" "_275") (param externref) (result externref))
99
(func $"dart2wasm._147 (import)" (import "dart2wasm" "_147") (param externref) (result f64))
1010
(func $"dart2wasm._148 (import)" (import "dart2wasm" "_148") (param f64) (result externref))
11-
(global $"doubleValueNullable initialized" (mut i32) <...>)
12-
(global $doubleValueNullable (mut (ref null $BoxedDouble)) <...>)
13-
(global $"ktrue initialized" (mut i32) <...>)
1411
(global $ktrue (mut i32) <...>)
15-
(global $"doubleValue initialized" (mut i32) <...>)
1612
(global $doubleValue (mut f64) <...>)
13+
(global $"ktrue initialized" (mut i32) <...>)
14+
(global $"doubleValue initialized" (mut i32) <...>)
15+
(global $"doubleValueNullable initialized" (mut i32) <...>)
16+
(global $doubleValueNullable (mut (ref null $BoxedDouble)) <...>)
1717
(func $"testDoubleConstant <noInline>"
1818
(local $var0 externref)
1919
f64.const 1.1

‎pkg/dart2wasm/test/ir_tests/interop.int.wat‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,12 +6,12 @@
66
(field $value i64))))
77
(func $"dart2wasm._274 (import)" (import "dart2wasm" "_274") (param externref) (result externref))
88
(func $"dart2wasm._275 (import)" (import "dart2wasm" "_275") (param externref) (result externref))
9-
(global $"intValueNullable initialized" (mut i32) <...>)
10-
(global $intValueNullable (mut (ref null $BoxedInt)) <...>)
11-
(global $"ktrue initialized" (mut i32) <...>)
129
(global $ktrue (mut i32) <...>)
13-
(global $"intValue initialized" (mut i32) <...>)
1410
(global $intValue (mut i64) <...>)
11+
(global $"ktrue initialized" (mut i32) <...>)
12+
(global $"intValue initialized" (mut i32) <...>)
13+
(global $"intValueNullable initialized" (mut i32) <...>)
14+
(global $intValueNullable (mut (ref null $BoxedInt)) <...>)
1515
(func $"testIntConstant <noInline>"
1616
(local $var0 externref)
1717
i64.const 1

‎pkg/dart2wasm/test/ir_tests/interop.num.wat‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,13 +19,13 @@
1919
(func $"dart2wasm._147 (import)" (import "dart2wasm" "_147") (param externref) (result f64))
2020
(func $"dart2wasm._148 (import)" (import "dart2wasm" "_148") (param f64) (result externref))
2121
(table $dtable1 745 funcref)
22+
(global $ktrue (mut i32) <...>)
23+
(global $numValue (mut (ref null $#Top)) <...>)
24+
(global $"ktrue initialized" (mut i32) <...>)
2225
(global $"C66 WasmArray<WasmArray<_Type>>[729]" (ref $Array<WasmArray<_Type>>) <...>)
2326
(global $"C319 _TopType" (ref $_TopType) <...>)
2427
(global $"numValueNullable initialized" (mut i32) <...>)
2528
(global $numValueNullable (mut (ref null $#Top)) <...>)
26-
(global $"ktrue initialized" (mut i32) <...>)
27-
(global $ktrue (mut i32) <...>)
28-
(global $numValue (mut (ref null $#Top)) <...>)
2929
(elem $dtable1 <...>)
3030
(func $_TypeUniverse.isSubtype (param $var0 (ref $_Type)) (param $var1 (ref null $_Environment)) (param $var2 (ref $_Type)) (param $var3 (ref null $_Environment)) (result i32) <...>)
3131
(func $_TypeUniverse._checkSubclassRelationshipViaTable (param $var0 i32) (param $var1 i32) (result i32) <...>)

‎pkg/dart2wasm/test/ir_tests/interop.string.wat‎

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,17 +6,16 @@
66
(field $_ref externref))))
77
(func $"dart2wasm._274 (import)" (import "dart2wasm" "_274") (param externref) (result externref))
88
(func $"dart2wasm._275 (import)" (import "dart2wasm" "_275") (param externref) (result externref))
9-
(global $"stringValueNullable initialized" (mut i32) <...>)
10-
(global $stringValueNullable (mut (ref null $JSStringImpl)) <...>)
11-
(global $"ktrue initialized" (mut i32) <...>)
9+
(global $.a (import "" "a") (ref extern))
1210
(global $ktrue (mut i32) <...>)
1311
(global $stringValue (mut (ref null $JSStringImpl)) <...>)
14-
(global $"C366 \"a\"" (ref $JSStringImpl) <...>)
12+
(global $"ktrue initialized" (mut i32) <...>)
13+
(global $"stringValueNullable initialized" (mut i32) <...>)
14+
(global $stringValueNullable (mut (ref null $JSStringImpl)) <...>)
1515
(func $new JSStringImpl.fromRef (param $var0 externref) (result (ref $JSStringImpl)) <...>)
1616
(func $"testStringConstant <noInline>"
1717
(local $var0 externref)
18-
global.get $"C366 \"a\""
19-
struct.get $JSStringImpl $_ref
18+
global.get $.a
2019
call $"dart2wasm._274 (import)"
2120
local.tee $var0
2221
call $isDartNull

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /