forked from runtimeverification/wasm-semantics
-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Tests and fixes for the memory instructions
- Loading branch information
1 parent
3afcc0e
commit fe6d323
Showing
6 changed files
with
94 additions
and
11 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
(module $mymodule | ||
(func (param i32) (result i32) | ||
|
||
i32.const 0 | ||
i32.const 0 | ||
i32.const 0 | ||
memory.init 0 | ||
|
||
data.drop 0 | ||
(return (i32.const 1)) | ||
) | ||
(memory (;0;) 17) | ||
(data (i32.const 1048576) ";askdfja;skdjf") | ||
) |
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,65 @@ | ||
<generatedTop> | ||
<k> | ||
#module (... types: #type (... type: [ i32 .ValTypes ] -> [ i32 .ValTypes ] , metadata: ) .EmptyStmts , funcs: #func (... type: 0 , locals: [ .ValTypes ] , body: i32 . const 0 #load ( i32 , load , 0 ) drop i32 . const 0 #load ( i32 , load , 8 ) drop i32 . const 0 #load ( i32 , load , 0 ) drop i32 . const 0 #load ( i32 , load , 8 ) drop i32 . const 0 #load ( i64 , load , 8 ) drop i32 . const 0 #load ( f32 , load , 8 ) drop i32 . const 0 #load ( f64 , load , 8 ) drop i32 . const 0 #load ( i32 , load8_s , 8 ) drop i32 . const 0 #load ( i32 , load8_u , 8 ) drop i32 . const 0 #load ( i32 , load16_s , 8 ) drop i32 . const 0 #load ( i32 , load16_u , 8 ) drop i32 . const 0 #load ( i64 , load8_s , 8 ) drop i32 . const 0 #load ( i64 , load8_u , 8 ) drop i32 . const 0 #load ( i64 , load16_s , 8 ) drop i32 . const 0 #load ( i64 , load16_u , 8 ) drop i32 . const 0 #load ( i64 , load32_s , 8 ) drop i32 . const 0 #load ( i64 , load32_u , 8 ) drop i32 . const 0 i32 . const 0 #store ( i32 , store , 8 ) i32 . const 0 i32 . const 0 #store ( i32 , store8 , 8 ) i32 . const 0 i32 . const 0 #store ( i32 , store16 , 8 ) i32 . const 0 i64 . const 0 #store ( i64 , store , 8 ) i32 . const 0 i64 . const 0 #store ( i64 , store8 , 8 ) i32 . const 0 i64 . const 0 #store ( i64 , store16 , 8 ) i32 . const 0 i64 . const 0 #store ( i64 , store32 , 8 ) i32 . const 0 i32 . const 0 #load ( f32 , load , 8 ) #store ( f32 , store , 8 ) i32 . const 0 i32 . const 0 #load ( f64 , load , 8 ) #store ( f64 , store , 8 ) memory.size drop i32 . const 0 memory.grow drop i32 . const 0 i32 . const 0 i32 . const 0 memory.fill i32 . const 0 i32 . const 0 i32 . const 0 memory.copy i32 . const 1 return .EmptyStmts , metadata: #meta (... id: , localIds: .Map ) ) .EmptyStmts , tables: .EmptyStmts , mems: #memory (... limits: #limitsMin ( 17 ) , metadata: ) .EmptyStmts , globals: #global (... type: var i32 , init: i32 . const 1048576 .EmptyStmts , metadata: ) .EmptyStmts , elem: .EmptyStmts , data: #data (... index: 0 , offset: i32 . const 1048576 .EmptyStmts , data: b";askdfja;skdjf" ) .EmptyStmts , start: .EmptyStmts , importDefns: .EmptyStmts , exports: .EmptyStmts , metadata: #meta (... id: , funcIds: .Map , filename: .String ) ) ~> .K | ||
</k> | ||
<wasm> | ||
<instrs> | ||
.K | ||
</instrs> | ||
<valstack> | ||
.ValStack | ||
</valstack> | ||
<curFrame> | ||
<locals> | ||
.List | ||
</locals> | ||
<curModIdx> | ||
.Int | ||
</curModIdx> | ||
</curFrame> | ||
<moduleRegistry> | ||
.Map | ||
</moduleRegistry> | ||
<moduleIds> | ||
.Map | ||
</moduleIds> | ||
<moduleInstances> | ||
.ModuleInstCellMap | ||
</moduleInstances> | ||
<nextModuleIdx> | ||
0 | ||
</nextModuleIdx> | ||
<mainStore> | ||
<funcs> | ||
.FuncDefCellMap | ||
</funcs> | ||
<nextFuncAddr> | ||
0 | ||
</nextFuncAddr> | ||
<tabs> | ||
.TabInstCellMap | ||
</tabs> | ||
<nextTabAddr> | ||
0 | ||
</nextTabAddr> | ||
<mems> | ||
.List | ||
</mems> | ||
<globals> | ||
.GlobalInstCellMap | ||
</globals> | ||
<nextGlobAddr> | ||
0 | ||
</nextGlobAddr> | ||
<elems> | ||
.ElemInstCellMap | ||
</elems> | ||
<nextElemAddr> | ||
0 | ||
</nextElemAddr> | ||
</mainStore> | ||
<deterministicMemoryGrowth> | ||
true | ||
</deterministicMemoryGrowth> | ||
</wasm> | ||
</generatedTop> |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
tests/binary-parsing/type-param-v128.wast | ||
tests/binary-parsing/code-call-indirect.wast | ||
tests/binary-parsing/code-variable-global.wast | ||
tests/binary-parsing/code-memory.wast | ||
tests/binary-parsing/code-memory-mem-init-data-drop.wast | ||
tests/binary-parsing/code-numeric-float-parsing.md | ||
tests/binary-parsing/code-numeric-convert-reinterpret.wast |