Skip to content

Commit 7b0aecc

Browse files
authored
Update wasm-semantics regression tests (#1847)
1 parent 9b912f4 commit 7b0aecc

28 files changed

+17150
-35100
lines changed

test/regression-wasm-semantics-75baf9b/generate.sh renamed to test/regression-wasm-semantics-5372938/generate.sh

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -25,19 +25,14 @@ for spec in \
2525
simple-arithmetic \
2626
locals \
2727
loops \
28-
memory-symbolic-type
28+
memory
2929
do
3030
kollect "test-$spec" \
3131
./kwasm prove --backend haskell \
3232
tests/proofs/"$spec"-spec.k \
3333
--def-module KWASM-LEMMAS
3434
done
3535

36-
kollect "test-memory-concrete-type" \
37-
./kwasm prove --backend haskell \
38-
tests/proofs/memory-concrete-type-spec.k \
39-
--def-module MEMORY-CONCRETE-TYPE-LEMMAS
40-
4136
kollect "test-wrc20" \
4237
./kwasm prove --backend haskell \
4338
tests/proofs/wrc20-spec.k \

test/regression-wasm-semantics-75baf9b/test-locals-spec.kore renamed to test/regression-wasm-semantics-5372938/test-locals-spec.kore

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,12 +6,12 @@ import KWASM-LEMMAS []
66

77

88
// claims
9-
// rule `<generatedTop>`(`<wasm>`(`<k>`(inj{Instrs,KItem}(`___WASM_Instrs_Instr_Instrs`(inj{FoldedInstr,Instr}(`(_)_WASM-TEXT_FoldedInstr_PlainInstr`(`local.get__WASM_PlainInstr_Index`(inj{Int,Index}(X)))),`___WASM_Instrs_Instr_Instrs`(inj{FoldedInstr,Instr}(`(_)_WASM-TEXT_FoldedInstr_PlainInstr`(`local.set__WASM_PlainInstr_Index`(inj{Int,Index}(X)))),inj{EmptyStmts,Instrs}(`.List{"___WASM_EmptyStmts_EmptyStmt_EmptyStmts"}_EmptyStmts`(.KList)))))~>DotVar2),_4,`<curFrame>`(`<locals>`(`_|->_`(inj{Int,KItem}(X),inj{Val,KItem}(`<_>__WASM-DATA_Val_AValType_Number`(ITYPE,VAL)))),_0,_1,_2,_3),_5,_6,_7,_8,_9,_10,_11),DotVar0)=>`<generatedTop>`(`<wasm>`(`<k>`(DotVar2),_4,`<curFrame>`(`<locals>`(`_|->_`(inj{Int,KItem}(X),inj{Val,KItem}(`<_>__WASM-DATA_Val_AValType_Number`(ITYPE,VAL)))),_0,_1,_2,_3),_5,_6,_7,_8,_9,_10,_11),DotVar0) requires #token("true","Bool") ensures #token("true","Bool") [contentStartColumn(10), contentStartLine(6), org.kframework.attributes.Location(Location(6,10,9,19)), org.kframework.attributes.Source(Source(/home/ana/kore/wasm-semantics/tests/proofs/locals-spec.k)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])]
9+
// rule `<generatedTop>`(`<wasm>`(`<k>`(inj{Instrs,KItem}(`___WASM_Instrs_Instr_Instrs`(inj{FoldedInstr,Instr}(`(_)_WASM-TEXT_FoldedInstr_PlainInstr`(`local.get__WASM_PlainInstr_Index`(inj{Int,Index}(X)))),`___WASM_Instrs_Instr_Instrs`(inj{FoldedInstr,Instr}(`(_)_WASM-TEXT_FoldedInstr_PlainInstr`(`local.set__WASM_PlainInstr_Index`(inj{Int,Index}(X)))),inj{EmptyStmts,Instrs}(`.List{"___WASM_EmptyStmts_EmptyStmt_EmptyStmts"}_EmptyStmts`(.KList)))))~>DotVar2),_3,`<curFrame>`(`<locals>`(`_|->_`(inj{Int,KItem}(X),inj{Val,KItem}(`<_>__WASM-DATA_Val_AValType_Number`(ITYPE,VAL)))),_0,_1,_2),_4,_5,_6,_7,_8,_9,_10),DotVar0)=>`<generatedTop>`(`<wasm>`(`<k>`(DotVar2),_3,`<curFrame>`(`<locals>`(`_|->_`(inj{Int,KItem}(X),inj{Val,KItem}(`<_>__WASM-DATA_Val_AValType_Number`(ITYPE,VAL)))),_0,_1,_2),_4,_5,_6,_7,_8,_9,_10),DotVar0) requires #token("true","Bool") ensures #token("true","Bool") [contentStartColumn(10), contentStartLine(6), org.kframework.attributes.Location(Location(6,10,9,19)), org.kframework.attributes.Source(Source(/home/ana/kore/wasm-semantics/tests/proofs/locals-spec.k)), org.kframework.definition.Production(syntax #RuleContent ::= #RuleBody [klabel(#ruleNoConditions), symbol])]
1010
claim{} \implies{SortGeneratedTopCell{}} (
1111
\and{SortGeneratedTopCell{}} (
12-
\top{SortGeneratedTopCell{}}(), Lbl'-LT-'generatedTop'-GT-'{}(Lbl'-LT-'wasm'-GT-'{}(Lbl'-LT-'k'-GT-'{}(kseq{}(inj{SortInstrs{}, SortKItem{}}(Lbl'UndsUndsUnds'WASM'Unds'Instrs'Unds'Instr'Unds'Instrs{}(inj{SortFoldedInstr{}, SortInstr{}}(Lbl'LParUndsRParUnds'WASM-TEXT'Unds'FoldedInstr'Unds'PlainInstr{}(Lbllocal'Stop'get'UndsUnds'WASM'Unds'PlainInstr'Unds'Index{}(inj{SortInt{}, SortIndex{}}(VarX:SortInt{})))),Lbl'UndsUndsUnds'WASM'Unds'Instrs'Unds'Instr'Unds'Instrs{}(inj{SortFoldedInstr{}, SortInstr{}}(Lbl'LParUndsRParUnds'WASM-TEXT'Unds'FoldedInstr'Unds'PlainInstr{}(Lbllocal'Stop'set'UndsUnds'WASM'Unds'PlainInstr'Unds'Index{}(inj{SortInt{}, SortIndex{}}(VarX:SortInt{})))),inj{SortEmptyStmts{}, SortInstrs{}}(Lbl'Stop'List'LBraQuotUndsUndsUnds'WASM'Unds'EmptyStmts'Unds'EmptyStmt'Unds'EmptyStmts'QuotRBraUnds'EmptyStmts{}())))),VarDotVar2:SortK{})),Var'Unds'4:SortValstackCell{},Lbl'-LT-'curFrame'-GT-'{}(Lbl'-LT-'locals'-GT-'{}(Lbl'UndsPipe'-'-GT-Unds'{}(inj{SortInt{}, SortKItem{}}(VarX:SortInt{}),inj{SortVal{}, SortKItem{}}(Lbl'-LT-Unds-GT-UndsUnds'WASM-DATA'Unds'Val'Unds'AValType'Unds'Number{}(VarITYPE:SortAValType{},VarVAL:SortNumber{})))),Var'Unds'0:SortLocalIdsCell{},Var'Unds'1:SortCurModIdxCell{},Var'Unds'2:SortLabelDepthCell{},Var'Unds'3:SortLabelIdsCell{}),Var'Unds'5:SortModuleRegistryCell{},Var'Unds'6:SortModuleIdsCell{},Var'Unds'7:SortModuleInstancesCell{},Var'Unds'8:SortNextModuleIdxCell{},Var'Unds'9:SortMainStoreCell{},Var'Unds'10:SortDeterministicMemoryGrowthCell{},Var'Unds'11:SortNextFreshIdCell{}),VarDotVar0:SortGeneratedCounterCell{})), weakAlwaysFinally{SortGeneratedTopCell{}} (
12+
\top{SortGeneratedTopCell{}}(), Lbl'-LT-'generatedTop'-GT-'{}(Lbl'-LT-'wasm'-GT-'{}(Lbl'-LT-'k'-GT-'{}(kseq{}(inj{SortInstrs{}, SortKItem{}}(Lbl'UndsUndsUnds'WASM'Unds'Instrs'Unds'Instr'Unds'Instrs{}(inj{SortFoldedInstr{}, SortInstr{}}(Lbl'LParUndsRParUnds'WASM-TEXT'Unds'FoldedInstr'Unds'PlainInstr{}(Lbllocal'Stop'get'UndsUnds'WASM'Unds'PlainInstr'Unds'Index{}(inj{SortInt{}, SortIndex{}}(VarX:SortInt{})))),Lbl'UndsUndsUnds'WASM'Unds'Instrs'Unds'Instr'Unds'Instrs{}(inj{SortFoldedInstr{}, SortInstr{}}(Lbl'LParUndsRParUnds'WASM-TEXT'Unds'FoldedInstr'Unds'PlainInstr{}(Lbllocal'Stop'set'UndsUnds'WASM'Unds'PlainInstr'Unds'Index{}(inj{SortInt{}, SortIndex{}}(VarX:SortInt{})))),inj{SortEmptyStmts{}, SortInstrs{}}(Lbl'Stop'List'LBraQuotUndsUndsUnds'WASM'Unds'EmptyStmts'Unds'EmptyStmt'Unds'EmptyStmts'QuotRBraUnds'EmptyStmts{}())))),VarDotVar2:SortK{})),Var'Unds'3:SortValstackCell{},Lbl'-LT-'curFrame'-GT-'{}(Lbl'-LT-'locals'-GT-'{}(Lbl'UndsPipe'-'-GT-Unds'{}(inj{SortInt{}, SortKItem{}}(VarX:SortInt{}),inj{SortVal{}, SortKItem{}}(Lbl'-LT-Unds-GT-UndsUnds'WASM-DATA'Unds'Val'Unds'AValType'Unds'Number{}(VarITYPE:SortAValType{},VarVAL:SortNumber{})))),Var'Unds'0:SortCurModIdxCell{},Var'Unds'1:SortLabelDepthCell{},Var'Unds'2:SortLabelIdsCell{}),Var'Unds'4:SortModuleRegistryCell{},Var'Unds'5:SortModuleIdsCell{},Var'Unds'6:SortModuleInstancesCell{},Var'Unds'7:SortNextModuleIdxCell{},Var'Unds'8:SortMainStoreCell{},Var'Unds'9:SortDeterministicMemoryGrowthCell{},Var'Unds'10:SortNextFreshIdCell{}),VarDotVar0:SortGeneratedCounterCell{})), weakAlwaysFinally{SortGeneratedTopCell{}} (
1313
\and{SortGeneratedTopCell{}} (
14-
\top{SortGeneratedTopCell{}}(), Lbl'-LT-'generatedTop'-GT-'{}(Lbl'-LT-'wasm'-GT-'{}(Lbl'-LT-'k'-GT-'{}(VarDotVar2:SortK{}),Var'Unds'4:SortValstackCell{},Lbl'-LT-'curFrame'-GT-'{}(Lbl'-LT-'locals'-GT-'{}(Lbl'UndsPipe'-'-GT-Unds'{}(inj{SortInt{}, SortKItem{}}(VarX:SortInt{}),inj{SortVal{}, SortKItem{}}(Lbl'-LT-Unds-GT-UndsUnds'WASM-DATA'Unds'Val'Unds'AValType'Unds'Number{}(VarITYPE:SortAValType{},VarVAL:SortNumber{})))),Var'Unds'0:SortLocalIdsCell{},Var'Unds'1:SortCurModIdxCell{},Var'Unds'2:SortLabelDepthCell{},Var'Unds'3:SortLabelIdsCell{}),Var'Unds'5:SortModuleRegistryCell{},Var'Unds'6:SortModuleIdsCell{},Var'Unds'7:SortModuleInstancesCell{},Var'Unds'8:SortNextModuleIdxCell{},Var'Unds'9:SortMainStoreCell{},Var'Unds'10:SortDeterministicMemoryGrowthCell{},Var'Unds'11:SortNextFreshIdCell{}),VarDotVar0:SortGeneratedCounterCell{}))))
14+
\top{SortGeneratedTopCell{}}(), Lbl'-LT-'generatedTop'-GT-'{}(Lbl'-LT-'wasm'-GT-'{}(Lbl'-LT-'k'-GT-'{}(VarDotVar2:SortK{}),Var'Unds'3:SortValstackCell{},Lbl'-LT-'curFrame'-GT-'{}(Lbl'-LT-'locals'-GT-'{}(Lbl'UndsPipe'-'-GT-Unds'{}(inj{SortInt{}, SortKItem{}}(VarX:SortInt{}),inj{SortVal{}, SortKItem{}}(Lbl'-LT-Unds-GT-UndsUnds'WASM-DATA'Unds'Val'Unds'AValType'Unds'Number{}(VarITYPE:SortAValType{},VarVAL:SortNumber{})))),Var'Unds'0:SortCurModIdxCell{},Var'Unds'1:SortLabelDepthCell{},Var'Unds'2:SortLabelIdsCell{}),Var'Unds'4:SortModuleRegistryCell{},Var'Unds'5:SortModuleIdsCell{},Var'Unds'6:SortModuleInstancesCell{},Var'Unds'7:SortNextModuleIdxCell{},Var'Unds'8:SortMainStoreCell{},Var'Unds'9:SortDeterministicMemoryGrowthCell{},Var'Unds'10:SortNextFreshIdCell{}),VarDotVar0:SortGeneratedCounterCell{}))))
1515
[org'Stop'kframework'Stop'attributes'Stop'Source{}(), org'Stop'kframework'Stop'definition'Stop'Production{}(), contentStartLine{}(), contentStartColumn{}(), org'Stop'kframework'Stop'attributes'Stop'Location{}()]
1616

1717
endmodule [org'Stop'kframework'Stop'attributes'Stop'Location{}(), org'Stop'kframework'Stop'attributes'Stop'Source{}()]

0 commit comments

Comments
 (0)