You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 357cc31
Browse filesBrowse the repository at this point in the historyBrowse files
This CL adds support for globals with index types.
Bug: 533316073
Change-Id: I417c6eee3034590100a1c833c27038b5b866655b
Reviewed-on: https://chrome-internal-review.googlesource.com/c/v8/fuzzilli/+/9529335
Commit-Queue: Leon Bettscheider <bettscheider@chromium.org>
Reviewed-by: Matthias Liedtke <mliedtke@google.com>
// This has to be a constant expression: https://webassembly.github.io/spec/core/valid/instructions.html#constant-expressions
1134
-
vartemporaryInstruction:Instruction?=nil
1135
-
// Also create some temporary output variables that do not have a number, these are only to satisfy the instruction assertions, maybe this can be done more nicely somehow.
// Type: (ref null $typeIndex). 0x63 is nullable ref.
1135
+
temp +=Data([0x63])+ typeIndexData
1136
+
temp +=Data([definition.isMutable ?0x1:0x0])
1137
+
1138
+
// Init expr: ref.null $typeIndex, then end (0x0B)
1139
+
temp +=Data([0xD0])+ typeIndexData + Data([0x0B])
1140
+
}else{
1141
+
letglobal= definition.wasmGlobal
1142
+
temp +=tryencodeType(global.toType())
1143
+
temp +=Data([definition.isMutable ?0x1:0x0])
1144
+
// This has to be a constant expression: https://webassembly.github.io/spec/core/valid/instructions.html#constant-expressions
1145
+
vartemporaryInstruction:Instruction?=nil
1146
+
// Also create some temporary output variables that do not have a number, these are only to satisfy the instruction assertions, maybe this can be done more nicely somehow.
// Append the length of the section and the section contents itself.
@@ -1543,20 +1557,24 @@ public class WasmLifter {
1543
1557
// TODO: check if this is still accurate as we now only have defined imports.
1544
1558
// Also, we export the globals in the order we "see" them, which might mismatch the order in which they are laid out in the binary at the end, which is why we track the order of the globals separately.
0 commit comments