[test] Add tests for data segment with memidx 1#1249
Merged
rossberg merged 1 commit intoWebAssembly:masterfrom Nov 10, 2020
Merged
[test] Add tests for data segment with memidx 1#1249rossberg merged 1 commit intoWebAssembly:masterfrom
rossberg merged 1 commit intoWebAssembly:masterfrom
Conversation
rossberg
approved these changes
Sep 22, 2020
test/core/data.wast
Outdated
| "\01\00" ;; data segment 0 for memory 1 with malformed index expr | ||
| ) | ||
| "unexpected end of section or function" | ||
| ) No newline at end of file |
Contributor
Author
There was a problem hiding this comment.
I decided to replace this test with an "assert_invalid" one. It detect the same bug in WABT, but contains single error.
20a3a26 to
d1ee577
Compare
gumb0
reviewed
Sep 23, 2020
test/core/data.wast
Outdated
| ;; "constant expression required" | ||
| ;; ) | ||
|
|
||
| ;; data segment with memory index 1 (only memory 0 available) |
There was a problem hiding this comment.
There's ;; Data without memory section above, maybe better to move these over there?
gumb0
reviewed
Sep 23, 2020
test/core/data.wast
Outdated
| ;; "constant expression required" | ||
| ;; ) | ||
|
|
||
| ;; data segment with memory index 1 (only memory 0 available) |
There was a problem hiding this comment.
For completeness I would also add a test with imported memory defined, and data segment with memory index 1.
d1ee577 to
f375d45
Compare
Contributor
Author
|
As WABT is fixed already, can we merge this PR here too? |
Member
|
Merged. Btw, please don't force-push to PR branches, because that breaks the review mechanics. |
chfast
added a commit
to wasmx/wasm-spec
that referenced
this pull request
Nov 10, 2020
ngzhian
added a commit
to ngzhian/spec
that referenced
this pull request
Nov 4, 2021
* [spec] automate instruction index rebuild (WebAssembly#1259) * [test] Add test for malformed functype (WebAssembly#1254) * [test] Correct tests for missing elements (WebAssembly#1251) Remove the code section in tests for malformed element section. Otherwise the code section id (0x0a) is taken as an element's table index what is a validation error. This is similar to the previously reported issue: WebAssembly#1170. * [test] Add tests for data segment with memidx 1 (WebAssembly#1249) * [test] Correct i32.store alignment in a LEB128 test (WebAssembly#1261) In the binary-leb128.wast, change the alignment of an i32.store instruction from 3 (invalid) to 2 (the intention suggested by the comment). Co-authored-by: Andreas Rossberg <rossberg@dfinity.org> Co-authored-by: Paweł Bylica <chfast@gmail.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Related to the bug in WABT: WebAssembly/wabt#1546,
found by Fizzy fuzzing.