task_id
stringlengths
21
23
challenge_id
stringlengths
16
16
proof_assistant
stringclasses
1 value
session
stringclasses
1 value
repo
stringclasses
57 values
revision
stringclasses
57 values
file_path
stringlengths
13
92
theory
stringlengths
1
48
variant
int64
0
132
challenge_type
stringclasses
1 value
difficulty
null
count
null
by_centrality
bool
1 class
ablation_prob
float64
0.5
0.5
min_depth
int64
1
1
max_depth
int64
1
1
leaves_only
bool
1 class
min_size
int64
0
0
max_size
stringclasses
1 value
min_centrality
int64
0
0
max_centrality
stringclasses
1 value
seed
int64
42
42
n_proofs
int64
1
173
n_ablated
int64
1
60
holes_filled
listlengths
1
60
deleted_lemmas
listlengths
1
1
corollaries
listlengths
1
1
closure_size
int64
1
172
challenge_file_content
stringlengths
133
350k
solution_file_content
stringlengths
394
351k
solution_diff
stringlengths
243
134k
manifest
dict
ablate_505d6fc2e7c3_3
1dd150196211b0b2
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/ObjectResolve.lean
ObjectResolve
3
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
22
2
[ { "theorem_name": "stepOp_ok_env", "depth": 1, "n_commands": 0, "n_lines": 1, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " stepOp_sameEnv h", "n_chars": 17, "n_subproofs": 0, "n_tactics": 1, "cyclomatic": 1, "n_automation": 0, "n_...
[ { "name": "stepOp_sameEnv", "text": "private theorem stepOp_sameEnv {op : Op} {args : List U256}\n {st : EvmState} {r} (h : stepOp op args st = some r) :\n SameEnvResult st r := by\n cases op <;> simp only [stepOp] at h <;>\n first\n | exact un_sameEnv _ _ _ h\n | exact bin_sameEnv _ _ _ h\n...
[ { "name": "stepOp_halt_env", "fan_in": 1, "n_deps_direct": 1, "n_deps_transitive": 6, "n_lines": 5, "n_chars": 172, "n_subproofs": 0, "n_tactics": 1, "cyclomatic": 1, "n_automation": 0, "n_rewrites": 0, "n_structural": 0, "automation_only": false, "max_nesting...
6
import YulSemantics.Determinism import YulSemantics.ObjectRun /-! # YulEvmCompiler.ObjectResolve Semantic preservation for object-layout reference resolution. `resolveForLayout` replaces `dataoffset("name")` and `datasize("name")` with the concrete word recorded by a selected `Layout`. The transformation is total a...
import YulSemantics.Determinism import YulSemantics.ObjectRun /-! # YulEvmCompiler.ObjectResolve Semantic preservation for object-layout reference resolution. `resolveForLayout` replaces `dataoffset("name")` and `datasize("name")` with the concrete word recorded by a selected `Layout`. The transformation is total a...
@@ -253,9 +253,23 @@ | nil => simp [YulSemantics.EVM.rd1] at h; subst r; rfl | cons => simp [YulSemantics.EVM.rd1] at h +private theorem stepOp_sameEnv {op : Op} {args : List U256} + {st : EvmState} {r} (h : stepOp op args st = some r) : + SameEnvResult st r := by + cases op <;> simp only [stepOp...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_505d6fc2e7c3_4
e6c9fbd14dc6f4c2
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/ObjectResolve.lean
ObjectResolve
4
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
22
1
[ { "theorem_name": "evmStep_env", "depth": 1, "n_commands": 0, "n_lines": 6, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n induction h <;> simp_all\n case builtinOk hargs hbuiltin ih =>\n exact (stepOp_ok_env hbuiltin).trans ih\n case builtinHal...
[ { "name": "stepOp_halt_env", "text": "private theorem stepOp_halt_env {op : Op} {args : List U256}\n {st st' : EvmState} (h : stepOp op args st = some (.halt st')) :\n st'.env = st.env := stepOp_sameEnv h\n\n", "fan_in": 1, "n_lines": 5, "n_chars": 172, "n_subproofs": 0, "n_tactics...
[ { "name": "evmStep_env", "fan_in": 5, "n_deps_direct": 2, "n_deps_transitive": 8, "n_lines": 14, "n_chars": 575, "n_subproofs": 0, "n_tactics": 7, "cyclomatic": 3, "n_automation": 1, "n_rewrites": 0, "n_structural": 3, "automation_only": false, "max_nesting": ...
8
import YulSemantics.Determinism import YulSemantics.ObjectRun /-! # YulEvmCompiler.ObjectResolve Semantic preservation for object-layout reference resolution. `resolveForLayout` replaces `dataoffset("name")` and `datasize("name")` with the concrete word recorded by a selected `Layout`. The transformation is total a...
import YulSemantics.Determinism import YulSemantics.ObjectRun /-! # YulEvmCompiler.ObjectResolve Semantic preservation for object-layout reference resolution. `resolveForLayout` replaces `dataoffset("name")` and `datasize("name")` with the concrete word recorded by a selected `Layout`. The transformation is total a...
@@ -271,13 +271,22 @@ {st st' : EvmState} (h : stepOp op args st = some (.ok returns st')) : st'.env = st.env := stepOp_sameEnv h +private theorem stepOp_halt_env {op : Op} {args : List U256} + {st st' : EvmState} (h : stepOp op args st = some (.halt st')) : + st'.env = st.env := stepOp_sameEnv h + /...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_505d6fc2e7c3_5
76668d843dc1d7c8
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/ObjectResolve.lean
ObjectResolve
5
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
22
5
[ { "theorem_name": "UsesLayout.after_vals", "depth": 1, "n_commands": 0, "n_lines": 5, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n have henv := evmStep_env h\n constructor <;> rw [henv]\n · exact hL.1\n · exact hL.2", "n_chars": 92, "n_s...
[ { "name": "evmStep_env", "text": "/-- Every relational Yul step preserves the immutable execution environment. -/\ntheorem evmStep_env {funs : FunEnv evm} {V : VEnv evm} {st : EvmState}\n {code : Code Op} {res : Res evm} (h : Step evm funs V st code res) :\n match res with\n | .eres (.vals _ st') =...
[ { "name": "UsesLayout.after_vals", "fan_in": 1, "n_deps_direct": 1, "n_deps_transitive": 9, "n_lines": 11, "n_chars": 372, "n_subproofs": 1, "n_tactics": 6, "cyclomatic": 3, "n_automation": 0, "n_rewrites": 1, "n_structural": 3, "automation_only": false, "max_...
9
import YulSemantics.Determinism import YulSemantics.ObjectRun /-! # YulEvmCompiler.ObjectResolve Semantic preservation for object-layout reference resolution. `resolveForLayout` replaces `dataoffset("name")` and `datasize("name")` with the concrete word recorded by a selected `Layout`. The transformation is total a...
import YulSemantics.Determinism import YulSemantics.ObjectRun /-! # YulEvmCompiler.ObjectResolve Semantic preservation for object-layout reference resolution. `resolveForLayout` replaces `dataoffset("name")` and `datasize("name")` with the concrete word recorded by a selected `Layout`. The transformation is total a...
@@ -275,11 +275,28 @@ {st st' : EvmState} (h : stepOp op args st = some (.halt st')) : st'.env = st.env := stepOp_sameEnv h +/-- Every relational Yul step preserves the immutable execution environment. -/ +theorem evmStep_env {funs : FunEnv evm} {V : VEnv evm} {st : EvmState} + {code : Code Op} {res : Re...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_505d6fc2e7c3_6
3529b76955e53e41
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/ObjectResolve.lean
ObjectResolve
6
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
22
5
[ { "theorem_name": "UsesLayout.after_vals", "depth": 1, "n_commands": 0, "n_lines": 5, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n have henv := evmStep_env h\n constructor <;> rw [henv]\n · exact hL.1\n · exact hL.2", "n_chars": 92, "n_s...
[ { "name": "evmStep_env", "text": "/-- Every relational Yul step preserves the immutable execution environment. -/\ntheorem evmStep_env {funs : FunEnv evm} {V : VEnv evm} {st : EvmState}\n {code : Code Op} {res : Res evm} (h : Step evm funs V st code res) :\n match res with\n | .eres (.vals _ st') =...
[ { "name": "UsesLayout.after_expr_vals", "fan_in": 1, "n_deps_direct": 1, "n_deps_transitive": 9, "n_lines": 11, "n_chars": 368, "n_subproofs": 1, "n_tactics": 6, "cyclomatic": 3, "n_automation": 0, "n_rewrites": 1, "n_structural": 3, "automation_only": false, ...
9
import YulSemantics.Determinism import YulSemantics.ObjectRun /-! # YulEvmCompiler.ObjectResolve Semantic preservation for object-layout reference resolution. `resolveForLayout` replaces `dataoffset("name")` and `datasize("name")` with the concrete word recorded by a selected `Layout`. The transformation is total a...
import YulSemantics.Determinism import YulSemantics.ObjectRun /-! # YulEvmCompiler.ObjectResolve Semantic preservation for object-layout reference resolution. `resolveForLayout` replaces `dataoffset("name")` and `datasize("name")` with the concrete word recorded by a selected `Layout`. The transformation is total a...
@@ -275,11 +275,28 @@ {st st' : EvmState} (h : stepOp op args st = some (.halt st')) : st'.env = st.env := stepOp_sameEnv h +/-- Every relational Yul step preserves the immutable execution environment. -/ +theorem evmStep_env {funs : FunEnv evm} {V : VEnv evm} {st : EvmState} + {code : Code Op} {res : Re...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_505d6fc2e7c3_7
1db8d38704ad392f
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/ObjectResolve.lean
ObjectResolve
7
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
22
5
[ { "theorem_name": "UsesLayout.after_vals", "depth": 1, "n_commands": 0, "n_lines": 5, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n have henv := evmStep_env h\n constructor <;> rw [henv]\n · exact hL.1\n · exact hL.2", "n_chars": 92, "n_s...
[ { "name": "evmStep_env", "text": "/-- Every relational Yul step preserves the immutable execution environment. -/\ntheorem evmStep_env {funs : FunEnv evm} {V : VEnv evm} {st : EvmState}\n {code : Code Op} {res : Res evm} (h : Step evm funs V st code res) :\n match res with\n | .eres (.vals _ st') =...
[ { "name": "UsesLayout.after_stmt", "fan_in": 1, "n_deps_direct": 1, "n_deps_transitive": 9, "n_lines": 11, "n_chars": 361, "n_subproofs": 1, "n_tactics": 6, "cyclomatic": 3, "n_automation": 0, "n_rewrites": 1, "n_structural": 3, "automation_only": false, "max_...
9
import YulSemantics.Determinism import YulSemantics.ObjectRun /-! # YulEvmCompiler.ObjectResolve Semantic preservation for object-layout reference resolution. `resolveForLayout` replaces `dataoffset("name")` and `datasize("name")` with the concrete word recorded by a selected `Layout`. The transformation is total a...
import YulSemantics.Determinism import YulSemantics.ObjectRun /-! # YulEvmCompiler.ObjectResolve Semantic preservation for object-layout reference resolution. `resolveForLayout` replaces `dataoffset("name")` and `datasize("name")` with the concrete word recorded by a selected `Layout`. The transformation is total a...
@@ -275,11 +275,28 @@ {st st' : EvmState} (h : stepOp op args st = some (.halt st')) : st'.env = st.env := stepOp_sameEnv h +/-- Every relational Yul step preserves the immutable execution environment. -/ +theorem evmStep_env {funs : FunEnv evm} {V : VEnv evm} {st : EvmState} + {code : Code Op} {res : Re...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_505d6fc2e7c3_8
51e55f3f96ff0c1a
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/ObjectResolve.lean
ObjectResolve
8
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
22
5
[ { "theorem_name": "UsesLayout.after_vals", "depth": 1, "n_commands": 0, "n_lines": 5, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n have henv := evmStep_env h\n constructor <;> rw [henv]\n · exact hL.1\n · exact hL.2", "n_chars": 92, "n_s...
[ { "name": "evmStep_env", "text": "/-- Every relational Yul step preserves the immutable execution environment. -/\ntheorem evmStep_env {funs : FunEnv evm} {V : VEnv evm} {st : EvmState}\n {code : Code Op} {res : Res evm} (h : Step evm funs V st code res) :\n match res with\n | .eres (.vals _ st') =...
[ { "name": "UsesLayout.after_stmts", "fan_in": 1, "n_deps_direct": 1, "n_deps_transitive": 9, "n_lines": 11, "n_chars": 366, "n_subproofs": 1, "n_tactics": 6, "cyclomatic": 3, "n_automation": 0, "n_rewrites": 1, "n_structural": 3, "automation_only": false, "max...
9
import YulSemantics.Determinism import YulSemantics.ObjectRun /-! # YulEvmCompiler.ObjectResolve Semantic preservation for object-layout reference resolution. `resolveForLayout` replaces `dataoffset("name")` and `datasize("name")` with the concrete word recorded by a selected `Layout`. The transformation is total a...
import YulSemantics.Determinism import YulSemantics.ObjectRun /-! # YulEvmCompiler.ObjectResolve Semantic preservation for object-layout reference resolution. `resolveForLayout` replaces `dataoffset("name")` and `datasize("name")` with the concrete word recorded by a selected `Layout`. The transformation is total a...
@@ -275,11 +275,28 @@ {st st' : EvmState} (h : stepOp op args st = some (.halt st')) : st'.env = st.env := stepOp_sameEnv h +/-- Every relational Yul step preserves the immutable execution environment. -/ +theorem evmStep_env {funs : FunEnv evm} {V : VEnv evm} {st : EvmState} + {code : Code Op} {res : Re...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_505d6fc2e7c3_9
be5ab305e2ad8a00
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/ObjectResolve.lean
ObjectResolve
9
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
22
5
[ { "theorem_name": "UsesLayout.after_vals", "depth": 1, "n_commands": 0, "n_lines": 5, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n have henv := evmStep_env h\n constructor <;> rw [henv]\n · exact hL.1\n · exact hL.2", "n_chars": 92, "n_s...
[ { "name": "evmStep_env", "text": "/-- Every relational Yul step preserves the immutable execution environment. -/\ntheorem evmStep_env {funs : FunEnv evm} {V : VEnv evm} {st : EvmState}\n {code : Code Op} {res : Res evm} (h : Step evm funs V st code res) :\n match res with\n | .eres (.vals _ st') =...
[ { "name": "UsesLayout.after_loop", "fan_in": 0, "n_deps_direct": 1, "n_deps_transitive": 9, "n_lines": 12, "n_chars": 398, "n_subproofs": 1, "n_tactics": 6, "cyclomatic": 3, "n_automation": 0, "n_rewrites": 1, "n_structural": 3, "automation_only": false, "max_...
9
import YulSemantics.Determinism import YulSemantics.ObjectRun /-! # YulEvmCompiler.ObjectResolve Semantic preservation for object-layout reference resolution. `resolveForLayout` replaces `dataoffset("name")` and `datasize("name")` with the concrete word recorded by a selected `Layout`. The transformation is total a...
import YulSemantics.Determinism import YulSemantics.ObjectRun /-! # YulEvmCompiler.ObjectResolve Semantic preservation for object-layout reference resolution. `resolveForLayout` replaces `dataoffset("name")` and `datasize("name")` with the concrete word recorded by a selected `Layout`. The transformation is total a...
@@ -275,12 +275,29 @@ {st st' : EvmState} (h : stepOp op args st = some (.halt st')) : st'.env = st.env := stepOp_sameEnv h +/-- Every relational Yul step preserves the immutable execution environment. -/ +theorem evmStep_env {funs : FunEnv evm} {V : VEnv evm} {st : EvmState} + {code : Code Op} {res : Re...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_505d6fc2e7c3_10
d267d6fb1902217b
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/ObjectResolve.lean
ObjectResolve
10
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
22
1
[ { "theorem_name": "resolveForLayout_step", "depth": 1, "n_commands": 0, "n_lines": 247, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n revert hL\n induction h with\n | lit =>\n intro _\n exact .lit\n | var hget =>\n intro _\n e...
[ { "name": "not_size_ref", "text": "private theorem not_size_ref {op : Op} {args : List (Expr Op)}\n (h : ¬ ∃ name, op = .datasize ∧ args = [.lit (.string name)]) :\n ∀ name, op ≠ .datasize ∨ args ≠ [.lit (.string name)] := by\n intro name\n by_contra hn\n push Not at hn\n exact h ⟨name, hn⟩\n\n", ...
[ { "name": "resolveForLayout_step", "fan_in": 1, "n_deps_direct": 10, "n_deps_transitive": 11, "n_lines": 257, "n_chars": 11445, "n_subproofs": 45, "n_tactics": 251, "cyclomatic": 2, "n_automation": 74, "n_rewrites": 9, "n_structural": 68, "automation_only": false,...
8
import YulSemantics.Determinism import YulSemantics.ObjectRun /-! # YulEvmCompiler.ObjectResolve Semantic preservation for object-layout reference resolution. `resolveForLayout` replaces `dataoffset("name")` and `datasize("name")` with the concrete word recorded by a selected `Layout`. The transformation is total a...
import YulSemantics.Determinism import YulSemantics.ObjectRun /-! # YulEvmCompiler.ObjectResolve Semantic preservation for object-layout reference resolution. `resolveForLayout` replaces `dataoffset("name")` and `datasize("name")` with the concrete word recorded by a selected `Layout`. The transformation is total a...
@@ -449,6 +449,14 @@ push Not at hn exact h ⟨name, hn⟩ +private theorem not_size_ref {op : Op} {args : List (Expr Op)} + (h : ¬ ∃ name, op = .datasize ∧ args = [.lit (.string name)]) : + ∀ name, op ≠ .datasize ∨ args ≠ [.lit (.string name)] := by + intro name + by_contra hn + push Not at hn + exact h ...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_505d6fc2e7c3_11
4c299d5d33b051fc
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/ObjectResolve.lean
ObjectResolve
11
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
22
1
[ { "theorem_name": "resolveForLayout_run", "depth": 1, "n_commands": 0, "n_lines": 3, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n simpa [Run, resolveForLayoutCode, resolveForLayoutFuns,\n resolveForLayoutStmt.eq_def] using resolveForLayout_step ...
[ { "name": "resolveForLayout_step", "text": "/-- Replacing object-layout reads by the selected layout's concrete words\npreserves every Yul derivation, including calls into transformed hoisted\nfunction bodies. -/\ntheorem resolveForLayout_step (L : Layout)\n {funs : FunEnv evm} {V : VEnv evm} {st : EvmSt...
[ { "name": "resolveForLayout_run", "fan_in": 0, "n_deps_direct": 1, "n_deps_transitive": 12, "n_lines": 10, "n_chars": 444, "n_subproofs": 0, "n_tactics": 3, "cyclomatic": 1, "n_automation": 1, "n_rewrites": 0, "n_structural": 0, "automation_only": true, "max_n...
9
import YulSemantics.Determinism import YulSemantics.ObjectRun /-! # YulEvmCompiler.ObjectResolve Semantic preservation for object-layout reference resolution. `resolveForLayout` replaces `dataoffset("name")` and `datasize("name")` with the concrete word recorded by a selected `Layout`. The transformation is total a...
import YulSemantics.Determinism import YulSemantics.ObjectRun /-! # YulEvmCompiler.ObjectResolve Semantic preservation for object-layout reference resolution. `resolveForLayout` replaces `dataoffset("name")` and `datasize("name")` with the concrete word recorded by a selected `Layout`. The transformation is total a...
@@ -457,12 +457,270 @@ push Not at hn exact h ⟨name, hn⟩ +/-- Replacing object-layout reads by the selected layout's concrete words +preserves every Yul derivation, including calls into transformed hoisted +function bodies. -/ +theorem resolveForLayout_step (L : Layout) + {funs : FunEnv evm} {V : VEnv evm} {...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_fb5952b882e0_0
aa09c6b6f7e90c40
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/Asm.lean
Asm
0
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
12
1
[ { "theorem_name": "codeSize_suffix_le", "depth": 1, "n_commands": 0, "n_lines": 4, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n obtain ⟨pre, rfl⟩ := h\n rw [codeSize_append]\n omega", "n_chars": 63, "n_subproofs": 1, "n_tactics": 4, ...
[ { "name": "codeSize_append", "text": "theorem codeSize_append (p q : List Asm) :\n codeSize (p ++ q) = codeSize p + codeSize q := by\n simp [codeSize]\n\n", "fan_in": 1, "n_lines": 5, "n_chars": 116, "n_subproofs": 0, "n_tactics": 2, "cyclomatic": 1, "n_automation": 1, "n...
[ { "name": "codeSize_suffix_le", "fan_in": 0, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 7, "n_chars": 157, "n_subproofs": 1, "n_tactics": 4, "cyclomatic": 1, "n_automation": 2, "n_rewrites": 1, "n_structural": 1, "automation_only": false, "max_nest...
1
import YulEvmCompiler.OpTable /-! # YulEvmCompiler.Asm The **labeled assembly layer**: the compiler's control-flow IR. `Asm` sits between Yul and the byte-level `Instr` IR. Jumps target symbolic *labels*, so compilation is position-independent (no byte positions are threaded through the compiler), and the simulation...
import YulEvmCompiler.OpTable /-! # YulEvmCompiler.Asm The **labeled assembly layer**: the compiler's control-flow IR. `Asm` sits between Yul and the byte-level `Instr` IR. Jumps target symbolic *labels*, so compilation is position-independent (no byte positions are threaded through the compiler), and the simulation...
@@ -100,8 +100,15 @@ @[simp] theorem codeSize_cons (i : Asm) (p : List Asm) : codeSize (i :: p) = i.size + codeSize p := by simp [codeSize] +theorem codeSize_append (p q : List Asm) : + codeSize (p ++ q) = codeSize p + codeSize q := by + simp [codeSize] + theorem codeSize_suffix_le {c p : List Asm} (h : c...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_fb5952b882e0_1
6ba1336bc1361335
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/Asm.lean
Asm
1
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
12
1
[ { "theorem_name": "labelDefs_label", "depth": 1, "n_commands": 0, "n_lines": 2, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n rw [labelDefs_cons]; rfl", "n_chars": 30, "n_subproofs": 0, "n_tactics": 3, "cyclomatic": 1, "n_automat...
[ { "name": "labelDefs_cons", "text": "theorem labelDefs_cons (i : Asm) (p : List Asm) :\n labelDefs (i :: p) = i.defines.toList ++ labelDefs p := by\n unfold labelDefs\n rw [List.filterMap_cons]\n cases i.defines <;> simp\n\n", "fan_in": 1, "n_lines": 7, "n_chars": 187, "n_subproofs": 0...
[ { "name": "labelDefs_label", "fan_in": 0, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 5, "n_chars": 144, "n_subproofs": 0, "n_tactics": 3, "cyclomatic": 1, "n_automation": 1, "n_rewrites": 1, "n_structural": 0, "automation_only": false, "max_nesting...
1
import YulEvmCompiler.OpTable /-! # YulEvmCompiler.Asm The **labeled assembly layer**: the compiler's control-flow IR. `Asm` sits between Yul and the byte-level `Instr` IR. Jumps target symbolic *labels*, so compilation is position-independent (no byte positions are threaded through the compiler), and the simulation...
import YulEvmCompiler.OpTable /-! # YulEvmCompiler.Asm The **labeled assembly layer**: the compiler's control-flow IR. `Asm` sits between Yul and the byte-level `Instr` IR. Jumps target symbolic *labels*, so compilation is position-independent (no byte positions are threaded through the compiler), and the simulation...
@@ -109,8 +109,15 @@ @[simp] theorem labelDefs_nil : labelDefs [] = [] := rfl @[simp] theorem labelRefs_nil : labelRefs [] = [] := rfl +theorem labelDefs_cons (i : Asm) (p : List Asm) : + labelDefs (i :: p) = i.defines.toList ++ labelDefs p := by + unfold labelDefs + rw [List.filterMap_cons] + cases i.defines...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_fb5952b882e0_2
4eb115d6b03e22fd
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/Asm.lean
Asm
2
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
12
5
[ { "theorem_name": "findLabel_eq_some", "depth": 1, "n_commands": 0, "n_lines": 21, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n intro p\n induction p with\n | nil => intro c h; simp [findLabel] at h\n | cons i rest ih =>\n intro c h\n rw [...
[ { "name": "mem_labelDefs_cons", "text": "/-- Membership in the defined labels of a cons, by cases on the head. -/\ntheorem mem_labelDefs_cons {l : Label} {i : Asm} {p : List Asm} :\n l ∈ labelDefs (i :: p) ↔ i = .label l ∨ l ∈ labelDefs p := by\n cases i <;>\n simp [labelDefs, Asm.defines, eq_comm]\n...
[ { "name": "findLabel_eq_some", "fan_in": 1, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 28, "n_chars": 951, "n_subproofs": 2, "n_tactics": 22, "cyclomatic": 3, "n_automation": 10, "n_rewrites": 5, "n_structural": 12, "automation_only": false, "max_n...
1
import YulEvmCompiler.OpTable /-! # YulEvmCompiler.Asm The **labeled assembly layer**: the compiler's control-flow IR. `Asm` sits between Yul and the byte-level `Instr` IR. Jumps target symbolic *labels*, so compilation is position-independent (no byte positions are threaded through the compiler), and the simulation...
import YulEvmCompiler.OpTable /-! # YulEvmCompiler.Asm The **labeled assembly layer**: the compiler's control-flow IR. `Asm` sits between Yul and the byte-level `Instr` IR. Jumps target symbolic *labels*, so compilation is position-independent (no byte positions are threaded through the compiler), and the simulation...
@@ -119,6 +119,12 @@ labelDefs (.label l :: p) = l :: labelDefs p := by rw [labelDefs_cons]; rfl +/-- Membership in the defined labels of a cons, by cases on the head. -/ +theorem mem_labelDefs_cons {l : Label} {i : Asm} {p : List Asm} : + l ∈ labelDefs (i :: p) ↔ i = .label l ∨ l ∈ labelDefs p := by + ca...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_fb5952b882e0_3
d27421236ee46593
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/Asm.lean
Asm
3
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
12
5
[ { "theorem_name": "findLabel_eq_some", "depth": 1, "n_commands": 0, "n_lines": 21, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n intro p\n induction p with\n | nil => intro c h; simp [findLabel] at h\n | cons i rest ih =>\n intro c h\n rw [...
[ { "name": "mem_labelDefs_cons", "text": "/-- Membership in the defined labels of a cons, by cases on the head. -/\ntheorem mem_labelDefs_cons {l : Label} {i : Asm} {p : List Asm} :\n l ∈ labelDefs (i :: p) ↔ i = .label l ∨ l ∈ labelDefs p := by\n cases i <;>\n simp [labelDefs, Asm.defines, eq_comm]\n...
[ { "name": "findLabel_suffix", "fan_in": 0, "n_deps_direct": 1, "n_deps_transitive": 2, "n_lines": 7, "n_chars": 248, "n_subproofs": 1, "n_tactics": 3, "cyclomatic": 1, "n_automation": 2, "n_rewrites": 0, "n_structural": 2, "automation_only": false, "max_nestin...
2
import YulEvmCompiler.OpTable /-! # YulEvmCompiler.Asm The **labeled assembly layer**: the compiler's control-flow IR. `Asm` sits between Yul and the byte-level `Instr` IR. Jumps target symbolic *labels*, so compilation is position-independent (no byte positions are threaded through the compiler), and the simulation...
import YulEvmCompiler.OpTable /-! # YulEvmCompiler.Asm The **labeled assembly layer**: the compiler's control-flow IR. `Asm` sits between Yul and the byte-level `Instr` IR. Jumps target symbolic *labels*, so compilation is position-independent (no byte positions are threaded through the compiler), and the simulation...
@@ -119,6 +119,12 @@ labelDefs (.label l :: p) = l :: labelDefs p := by rw [labelDefs_cons]; rfl +/-- Membership in the defined labels of a cons, by cases on the head. -/ +theorem mem_labelDefs_cons {l : Label} {i : Asm} {p : List Asm} : + l ∈ labelDefs (i :: p) ↔ i = .label l ∨ l ∈ labelDefs p := by + ca...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_fb5952b882e0_4
b248c55f528bc439
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/Asm.lean
Asm
4
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
12
5
[ { "theorem_name": "findLabel_eq_some", "depth": 1, "n_commands": 0, "n_lines": 21, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n intro p\n induction p with\n | nil => intro c h; simp [findLabel] at h\n | cons i rest ih =>\n intro c h\n rw [...
[ { "name": "mem_labelDefs_cons", "text": "/-- Membership in the defined labels of a cons, by cases on the head. -/\ntheorem mem_labelDefs_cons {l : Label} {i : Asm} {p : List Asm} :\n l ∈ labelDefs (i :: p) ↔ i = .label l ∨ l ∈ labelDefs p := by\n cases i <;>\n simp [labelDefs, Asm.defines, eq_comm]\n...
[ { "name": "findLabel_of_not_mem", "fan_in": 1, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 15, "n_chars": 599, "n_subproofs": 1, "n_tactics": 11, "cyclomatic": 2, "n_automation": 1, "n_rewrites": 2, "n_structural": 5, "automation_only": false, "max_...
1
import YulEvmCompiler.OpTable /-! # YulEvmCompiler.Asm The **labeled assembly layer**: the compiler's control-flow IR. `Asm` sits between Yul and the byte-level `Instr` IR. Jumps target symbolic *labels*, so compilation is position-independent (no byte positions are threaded through the compiler), and the simulation...
import YulEvmCompiler.OpTable /-! # YulEvmCompiler.Asm The **labeled assembly layer**: the compiler's control-flow IR. `Asm` sits between Yul and the byte-level `Instr` IR. Jumps target symbolic *labels*, so compilation is position-independent (no byte positions are threaded through the compiler), and the simulation...
@@ -119,6 +119,12 @@ labelDefs (.label l :: p) = l :: labelDefs p := by rw [labelDefs_cons]; rfl +/-- Membership in the defined labels of a cons, by cases on the head. -/ +theorem mem_labelDefs_cons {l : Label} {i : Asm} {p : List Asm} : + l ∈ labelDefs (i :: p) ↔ i = .label l ∨ l ∈ labelDefs p := by + ca...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_fb5952b882e0_5
b0f4815511e8e26d
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/Asm.lean
Asm
5
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
12
5
[ { "theorem_name": "findLabel_eq_some", "depth": 1, "n_commands": 0, "n_lines": 21, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n intro p\n induction p with\n | nil => intro c h; simp [findLabel] at h\n | cons i rest ih =>\n intro c h\n rw [...
[ { "name": "mem_labelDefs_cons", "text": "/-- Membership in the defined labels of a cons, by cases on the head. -/\ntheorem mem_labelDefs_cons {l : Label} {i : Asm} {p : List Asm} :\n l ∈ labelDefs (i :: p) ↔ i = .label l ∨ l ∈ labelDefs p := by\n cases i <;>\n simp [labelDefs, Asm.defines, eq_comm]\n...
[ { "name": "resolve_of_not_mem", "fan_in": 1, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 16, "n_chars": 593, "n_subproofs": 1, "n_tactics": 13, "cyclomatic": 2, "n_automation": 3, "n_rewrites": 2, "n_structural": 4, "automation_only": false, "max_ne...
1
import YulEvmCompiler.OpTable /-! # YulEvmCompiler.Asm The **labeled assembly layer**: the compiler's control-flow IR. `Asm` sits between Yul and the byte-level `Instr` IR. Jumps target symbolic *labels*, so compilation is position-independent (no byte positions are threaded through the compiler), and the simulation...
import YulEvmCompiler.OpTable /-! # YulEvmCompiler.Asm The **labeled assembly layer**: the compiler's control-flow IR. `Asm` sits between Yul and the byte-level `Instr` IR. Jumps target symbolic *labels*, so compilation is position-independent (no byte positions are threaded through the compiler), and the simulation...
@@ -119,6 +119,12 @@ labelDefs (.label l :: p) = l :: labelDefs p := by rw [labelDefs_cons]; rfl +/-- Membership in the defined labels of a cons, by cases on the head. -/ +theorem mem_labelDefs_cons {l : Label} {i : Asm} {p : List Asm} : + l ∈ labelDefs (i :: p) ↔ i = .label l ∨ l ∈ labelDefs p := by + ca...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_fb5952b882e0_6
ad8d37a41eac9196
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/Asm.lean
Asm
6
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
12
5
[ { "theorem_name": "findLabel_eq_some", "depth": 1, "n_commands": 0, "n_lines": 21, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n intro p\n induction p with\n | nil => intro c h; simp [findLabel] at h\n | cons i rest ih =>\n intro c h\n rw [...
[ { "name": "mem_labelDefs_cons", "text": "/-- Membership in the defined labels of a cons, by cases on the head. -/\ntheorem mem_labelDefs_cons {l : Label} {i : Asm} {p : List Asm} :\n l ∈ labelDefs (i :: p) ↔ i = .label l ∨ l ∈ labelDefs p := by\n cases i <;>\n simp [labelDefs, Asm.defines, eq_comm]\n...
[ { "name": "not_mem_labelDefs_left", "fan_in": 2, "n_deps_direct": 2, "n_deps_transitive": 2, "n_lines": 11, "n_chars": 380, "n_subproofs": 0, "n_tactics": 5, "cyclomatic": 1, "n_automation": 1, "n_rewrites": 1, "n_structural": 2, "automation_only": false, "max...
2
import YulEvmCompiler.OpTable /-! # YulEvmCompiler.Asm The **labeled assembly layer**: the compiler's control-flow IR. `Asm` sits between Yul and the byte-level `Instr` IR. Jumps target symbolic *labels*, so compilation is position-independent (no byte positions are threaded through the compiler), and the simulation...
import YulEvmCompiler.OpTable /-! # YulEvmCompiler.Asm The **labeled assembly layer**: the compiler's control-flow IR. `Asm` sits between Yul and the byte-level `Instr` IR. Jumps target symbolic *labels*, so compilation is position-independent (no byte positions are threaded through the compiler), and the simulation...
@@ -123,6 +123,12 @@ labelDefs (.label l :: p) = l :: labelDefs p := by rw [labelDefs_cons]; rfl +/-- Membership in the defined labels of a cons, by cases on the head. -/ +theorem mem_labelDefs_cons {l : Label} {i : Asm} {p : List Asm} : + l ∈ labelDefs (i :: p) ↔ i = .label l ∨ l ∈ labelDefs p := by + ca...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_fb5952b882e0_7
f88a3d064940c037
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/Asm.lean
Asm
7
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
12
5
[ { "theorem_name": "findLabel_eq_some", "depth": 1, "n_commands": 0, "n_lines": 21, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n intro p\n induction p with\n | nil => intro c h; simp [findLabel] at h\n | cons i rest ih =>\n intro c h\n rw [...
[ { "name": "mem_labelDefs_cons", "text": "/-- Membership in the defined labels of a cons, by cases on the head. -/\ntheorem mem_labelDefs_cons {l : Label} {i : Asm} {p : List Asm} :\n l ∈ labelDefs (i :: p) ↔ i = .label l ∨ l ∈ labelDefs p := by\n cases i <;>\n simp [labelDefs, Asm.defines, eq_comm]\n...
[ { "name": "findLabel_boundary", "fan_in": 0, "n_deps_direct": 2, "n_deps_transitive": 4, "n_lines": 9, "n_chars": 419, "n_subproofs": 0, "n_tactics": 1, "cyclomatic": 1, "n_automation": 0, "n_rewrites": 0, "n_structural": 0, "automation_only": false, "max_nest...
4
import YulEvmCompiler.OpTable /-! # YulEvmCompiler.Asm The **labeled assembly layer**: the compiler's control-flow IR. `Asm` sits between Yul and the byte-level `Instr` IR. Jumps target symbolic *labels*, so compilation is position-independent (no byte positions are threaded through the compiler), and the simulation...
import YulEvmCompiler.OpTable /-! # YulEvmCompiler.Asm The **labeled assembly layer**: the compiler's control-flow IR. `Asm` sits between Yul and the byte-level `Instr` IR. Jumps target symbolic *labels*, so compilation is position-independent (no byte positions are threaded through the compiler), and the simulation...
@@ -123,6 +123,12 @@ labelDefs (.label l :: p) = l :: labelDefs p := by rw [labelDefs_cons]; rfl +/-- Membership in the defined labels of a cons, by cases on the head. -/ +theorem mem_labelDefs_cons {l : Label} {i : Asm} {p : List Asm} : + l ∈ labelDefs (i :: p) ↔ i = .label l ∨ l ∈ labelDefs p := by + ca...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_fb5952b882e0_8
a71afbf66e14757f
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/Asm.lean
Asm
8
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
12
5
[ { "theorem_name": "findLabel_eq_some", "depth": 1, "n_commands": 0, "n_lines": 21, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n intro p\n induction p with\n | nil => intro c h; simp [findLabel] at h\n | cons i rest ih =>\n intro c h\n rw [...
[ { "name": "mem_labelDefs_cons", "text": "/-- Membership in the defined labels of a cons, by cases on the head. -/\ntheorem mem_labelDefs_cons {l : Label} {i : Asm} {p : List Asm} :\n l ∈ labelDefs (i :: p) ↔ i = .label l ∨ l ∈ labelDefs p := by\n cases i <;>\n simp [labelDefs, Asm.defines, eq_comm]\n...
[ { "name": "resolve_boundary", "fan_in": 0, "n_deps_direct": 2, "n_deps_transitive": 4, "n_lines": 7, "n_chars": 286, "n_subproofs": 0, "n_tactics": 1, "cyclomatic": 1, "n_automation": 0, "n_rewrites": 0, "n_structural": 0, "automation_only": false, "max_nestin...
4
import YulEvmCompiler.OpTable /-! # YulEvmCompiler.Asm The **labeled assembly layer**: the compiler's control-flow IR. `Asm` sits between Yul and the byte-level `Instr` IR. Jumps target symbolic *labels*, so compilation is position-independent (no byte positions are threaded through the compiler), and the simulation...
import YulEvmCompiler.OpTable /-! # YulEvmCompiler.Asm The **labeled assembly layer**: the compiler's control-flow IR. `Asm` sits between Yul and the byte-level `Instr` IR. Jumps target symbolic *labels*, so compilation is position-independent (no byte positions are threaded through the compiler), and the simulation...
@@ -123,6 +123,12 @@ labelDefs (.label l :: p) = l :: labelDefs p := by rw [labelDefs_cons]; rfl +/-- Membership in the defined labels of a cons, by cases on the head. -/ +theorem mem_labelDefs_cons {l : Label} {i : Asm} {p : List Asm} : + l ∈ labelDefs (i :: p) ↔ i = .label l ∨ l ∈ labelDefs p := by + ca...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_fb5952b882e0_9
9da032ca5c1d7fa0
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/Asm.lean
Asm
9
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
12
1
[ { "theorem_name": "resolve_lt", "depth": 1, "n_commands": 0, "n_lines": 18, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n intro p\n induction p with\n | nil => intro a h; simp [resolve] at h\n | cons i rest ih =>\n intro a h\n rw [resolve] ...
[ { "name": "size_pos", "text": "theorem size_pos (i : Asm) : 1 ≤ i.size := by cases i <;> simp [size]\n\n", "fan_in": 1, "n_lines": 3, "n_chars": 73, "n_subproofs": 0, "n_tactics": 2, "cyclomatic": 3, "n_automation": 1, "n_rewrites": 0, "n_structural": 1, "automation_o...
[ { "name": "resolve_lt", "fan_in": 0, "n_deps_direct": 2, "n_deps_transitive": 2, "n_lines": 23, "n_chars": 659, "n_subproofs": 4, "n_tactics": 19, "cyclomatic": 2, "n_automation": 7, "n_rewrites": 5, "n_structural": 6, "automation_only": false, "max_nesting": ...
1
import YulEvmCompiler.OpTable /-! # YulEvmCompiler.Asm The **labeled assembly layer**: the compiler's control-flow IR. `Asm` sits between Yul and the byte-level `Instr` IR. Jumps target symbolic *labels*, so compilation is position-independent (no byte positions are threaded through the compiler), and the simulation...
import YulEvmCompiler.OpTable /-! # YulEvmCompiler.Asm The **labeled assembly layer**: the compiler's control-flow IR. `Asm` sits between Yul and the byte-level `Instr` IR. Jumps target symbolic *labels*, so compilation is position-independent (no byte positions are threaded through the compiler), and the simulation...
@@ -81,6 +81,8 @@ | pushLabel _ => 33 | dynJump => 1 +theorem size_pos (i : Asm) : 1 ≤ i.size := by cases i <;> simp [size] + /-- The label an instruction defines (only `.label`). -/ def defines : Asm → Option Label | label l => some l @@ -135,7 +137,24 @@ /-- A resolved position points strictly inside th...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_fb5952b882e0_10
b92626cfd4bceccc
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/Asm.lean
Asm
10
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
12
5
[ { "theorem_name": "findLabel_eq_some", "depth": 1, "n_commands": 0, "n_lines": 21, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n intro p\n induction p with\n | nil => intro c h; simp [findLabel] at h\n | cons i rest ih =>\n intro c h\n rw [...
[ { "name": "mem_labelDefs_cons", "text": "/-- Membership in the defined labels of a cons, by cases on the head. -/\ntheorem mem_labelDefs_cons {l : Label} {i : Asm} {p : List Asm} :\n l ∈ labelDefs (i :: p) ↔ i = .label l ∨ l ∈ labelDefs p := by\n cases i <;>\n simp [labelDefs, Asm.defines, eq_comm]\n...
[ { "name": "mem_labelDefs_iff_findLabel", "fan_in": 0, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 17, "n_chars": 508, "n_subproofs": 0, "n_tactics": 11, "cyclomatic": 2, "n_automation": 2, "n_rewrites": 3, "n_structural": 3, "automation_only": false, ...
1
import YulEvmCompiler.OpTable /-! # YulEvmCompiler.Asm The **labeled assembly layer**: the compiler's control-flow IR. `Asm` sits between Yul and the byte-level `Instr` IR. Jumps target symbolic *labels*, so compilation is position-independent (no byte positions are threaded through the compiler), and the simulation...
import YulEvmCompiler.OpTable /-! # YulEvmCompiler.Asm The **labeled assembly layer**: the compiler's control-flow IR. `Asm` sits between Yul and the byte-level `Instr` IR. Jumps target symbolic *labels*, so compilation is position-independent (no byte positions are threaded through the compiler), and the simulation...
@@ -119,6 +119,12 @@ labelDefs (.label l :: p) = l :: labelDefs p := by rw [labelDefs_cons]; rfl +/-- Membership in the defined labels of a cons, by cases on the head. -/ +theorem mem_labelDefs_cons {l : Label} {i : Asm} {p : List Asm} : + l ∈ labelDefs (i :: p) ↔ i = .label l ∨ l ∈ labelDefs p := by + ca...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_fb5952b882e0_11
0cac50bfbdd1e971
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/Asm.lean
Asm
11
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
12
3
[ { "theorem_name": "lowerFrag_append", "depth": 1, "n_commands": 0, "n_lines": 10, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n intro p\n induction p with\n | nil => intro q is h; exact ⟨[], is, rfl, h, rfl⟩\n | cons i p ih =>\n intro q is h\n...
[ { "name": "lowerFrag_cons", "text": "theorem lowerFrag_cons {prog : List Asm} {i : Asm} {p : List Asm} {is : List Instr}\n (h : lowerFrag prog (i :: p) = some is) :\n ∃ is1 is2, lowerInstr prog i = some is1 ∧ lowerFrag prog p = some is2\n ∧ is = is1 ++ is2 := by\n rw [lowerFrag, Option.bind_eq_b...
[ { "name": "lowerFrag_append", "fan_in": 0, "n_deps_direct": 2, "n_deps_transitive": 2, "n_lines": 17, "n_chars": 645, "n_subproofs": 2, "n_tactics": 11, "cyclomatic": 2, "n_automation": 5, "n_rewrites": 1, "n_structural": 8, "automation_only": false, "max_nest...
2
import YulEvmCompiler.OpTable /-! # YulEvmCompiler.Asm The **labeled assembly layer**: the compiler's control-flow IR. `Asm` sits between Yul and the byte-level `Instr` IR. Jumps target symbolic *labels*, so compilation is position-independent (no byte positions are threaded through the compiler), and the simulation...
import YulEvmCompiler.OpTable /-! # YulEvmCompiler.Asm The **labeled assembly layer**: the compiler's control-flow IR. `Asm` sits between Yul and the byte-level `Instr` IR. Jumps target symbolic *labels*, so compilation is position-independent (no byte positions are threaded through the compiler), and the simulation...
@@ -181,6 +181,15 @@ @[simp] theorem lowerFrag_nil (prog : List Asm) : lowerFrag prog [] = some [] := rfl +theorem lowerFrag_cons {prog : List Asm} {i : Asm} {p : List Asm} {is : List Instr} + (h : lowerFrag prog (i :: p) = some is) : + ∃ is1 is2, lowerInstr prog i = some is1 ∧ lowerFrag prog p = some is2 + ...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_fb5952b882e0_12
fec32bb7a48d5e4a
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/Asm.lean
Asm
12
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
12
3
[ { "theorem_name": "lowerFrag_append", "depth": 1, "n_commands": 0, "n_lines": 10, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n intro p\n induction p with\n | nil => intro q is h; exact ⟨[], is, rfl, h, rfl⟩\n | cons i p ih =>\n intro q is h\n...
[ { "name": "lowerFrag_cons", "text": "theorem lowerFrag_cons {prog : List Asm} {i : Asm} {p : List Asm} {is : List Instr}\n (h : lowerFrag prog (i :: p) = some is) :\n ∃ is1 is2, lowerInstr prog i = some is1 ∧ lowerFrag prog p = some is2\n ∧ is = is1 ++ is2 := by\n rw [lowerFrag, Option.bind_eq_b...
[ { "name": "lowerFrag_append'", "fan_in": 0, "n_deps_direct": 2, "n_deps_transitive": 2, "n_lines": 19, "n_chars": 619, "n_subproofs": 3, "n_tactics": 13, "cyclomatic": 2, "n_automation": 5, "n_rewrites": 1, "n_structural": 6, "automation_only": false, "max_nes...
2
import YulEvmCompiler.OpTable /-! # YulEvmCompiler.Asm The **labeled assembly layer**: the compiler's control-flow IR. `Asm` sits between Yul and the byte-level `Instr` IR. Jumps target symbolic *labels*, so compilation is position-independent (no byte positions are threaded through the compiler), and the simulation...
import YulEvmCompiler.OpTable /-! # YulEvmCompiler.Asm The **labeled assembly layer**: the compiler's control-flow IR. `Asm` sits between Yul and the byte-level `Instr` IR. Jumps target symbolic *labels*, so compilation is position-independent (no byte positions are threaded through the compiler), and the simulation...
@@ -181,6 +181,15 @@ @[simp] theorem lowerFrag_nil (prog : List Asm) : lowerFrag prog [] = some [] := rfl +theorem lowerFrag_cons {prog : List Asm} {i : Asm} {p : List Asm} {is : List Instr} + (h : lowerFrag prog (i :: p) = some is) : + ∃ is1 is2, lowerInstr prog i = some is1 ∧ lowerFrag prog p = some is2 + ...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_fb5952b882e0_13
71a4accf80cf2217
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/Asm.lean
Asm
13
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
12
3
[ { "theorem_name": "lowerFrag_append", "depth": 1, "n_commands": 0, "n_lines": 10, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n intro p\n induction p with\n | nil => intro q is h; exact ⟨[], is, rfl, h, rfl⟩\n | cons i p ih =>\n intro q is h\n...
[ { "name": "lowerFrag_cons", "text": "theorem lowerFrag_cons {prog : List Asm} {i : Asm} {p : List Asm} {is : List Instr}\n (h : lowerFrag prog (i :: p) = some is) :\n ∃ is1 is2, lowerInstr prog i = some is1 ∧ lowerFrag prog p = some is2\n ∧ is = is1 ++ is2 := by\n rw [lowerFrag, Option.bind_eq_b...
[ { "name": "lowerFrag_length", "fan_in": 0, "n_deps_direct": 3, "n_deps_transitive": 3, "n_lines": 18, "n_chars": 547, "n_subproofs": 2, "n_tactics": 12, "cyclomatic": 2, "n_automation": 4, "n_rewrites": 1, "n_structural": 6, "automation_only": false, "max_nest...
2
import YulEvmCompiler.OpTable /-! # YulEvmCompiler.Asm The **labeled assembly layer**: the compiler's control-flow IR. `Asm` sits between Yul and the byte-level `Instr` IR. Jumps target symbolic *labels*, so compilation is position-independent (no byte positions are threaded through the compiler), and the simulation...
import YulEvmCompiler.OpTable /-! # YulEvmCompiler.Asm The **labeled assembly layer**: the compiler's control-flow IR. `Asm` sits between Yul and the byte-level `Instr` IR. Jumps target symbolic *labels*, so compilation is position-independent (no byte positions are threaded through the compiler), and the simulation...
@@ -217,6 +217,15 @@ @[simp] theorem lowerFrag_nil (prog : List Asm) : lowerFrag prog [] = some [] := rfl +theorem lowerFrag_cons {prog : List Asm} {i : Asm} {p : List Asm} {is : List Instr} + (h : lowerFrag prog (i :: p) = some is) : + ∃ is1 is2, lowerInstr prog i = some is1 ∧ lowerFrag prog p = some is2 + ...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_a2d882de954c_0
7d25e343c129a956
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulParser/Lexer.lean
Lexer
0
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
2
1
[ { "theorem_name": "pQuotedChars_rest_lt", "depth": 1, "n_commands": 0, "n_lines": 8, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n cases cs with\n | nil => simp [pQuotedChars] at h\n | cons c cs =>\n simp only [pQuotedChars] at h\n split...
[ { "name": "quotedBody_rest_lt", "text": "theorem quotedBody_rest_lt {cs body rest}\n (h : quotedBody cs = some (body, rest)) : rest.length < cs.length := by\n fun_induction quotedBody cs generalizing body rest <;> simp_all <;> omega\n\n", "fan_in": 1, "n_lines": 5, "n_chars": 195, "n_sub...
[ { "name": "pQuotedChars_rest_lt", "fan_in": 0, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 11, "n_chars": 323, "n_subproofs": 1, "n_tactics": 10, "cyclomatic": 3, "n_automation": 4, "n_rewrites": 0, "n_structural": 1, "automation_only": false, "max_...
1
import YulParser.Tokens /-! # YulParser.Lexer Character classes, greedy spans (`pWhile1`/`pWhile0`), the word-boundary check (`notIdCont`), and keyword/symbol tokens. -/ namespace YulParser /-! ### Character classes -/ def isDigitC (c : Char) : Bool := '0' ≤ c ∧ c ≤ '9' def isHexDigitC (c : Char) : Bool := isDig...
import YulParser.Tokens /-! # YulParser.Lexer Character classes, greedy spans (`pWhile1`/`pWhile0`), the word-boundary check (`notIdCont`), and keyword/symbol tokens. -/ namespace YulParser /-! ### Character classes -/ def isDigitC (c : Char) : Bool := '0' ≤ c ∧ c ≤ '9' def isHexDigitC (c : Char) : Bool := isDig...
@@ -46,6 +46,10 @@ | '"' :: rest => quotedBody rest | _ => none +theorem quotedBody_rest_lt {cs body rest} + (h : quotedBody cs = some (body, rest)) : rest.length < cs.length := by + fun_induction quotedBody cs generalizing body rest <;> simp_all <;> omega + theorem pQuotedChars_rest_lt {cs body rest} ...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_a2d882de954c_1
a2290776305b4757
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulParser/Lexer.lean
Lexer
1
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
2
1
[ { "theorem_name": "pQuotedChars_body", "depth": 1, "n_commands": 0, "n_lines": 8, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n cases cs with\n | nil => simp [pQuotedChars] at h\n | cons c input =>\n simp only [pQuotedChars] at h\n split...
[ { "name": "quotedBody_self", "text": "theorem quotedBody_self {cs body rest}\n (h : quotedBody cs = some (body, rest)) : QuotedBody body := by\n fun_induction quotedBody cs generalizing body rest <;> simp_all\n case case2 => exact .nil\n case case4 =>\n rename_i escaped input parsedBody after hnr h...
[ { "name": "pQuotedChars_body", "fan_in": 0, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 11, "n_chars": 293, "n_subproofs": 0, "n_tactics": 8, "cyclomatic": 3, "n_automation": 2, "n_rewrites": 0, "n_structural": 2, "automation_only": false, "max_nest...
1
import YulParser.Tokens /-! # YulParser.Lexer Character classes, greedy spans (`pWhile1`/`pWhile0`), the word-boundary check (`notIdCont`), and keyword/symbol tokens. -/ namespace YulParser /-! ### Character classes -/ def isDigitC (c : Char) : Bool := '0' ≤ c ∧ c ≤ '9' def isHexDigitC (c : Char) : Bool := isDig...
import YulParser.Tokens /-! # YulParser.Lexer Character classes, greedy spans (`pWhile1`/`pWhile0`), the word-boundary check (`notIdCont`), and keyword/symbol tokens. -/ namespace YulParser /-! ### Character classes -/ def isDigitC (c : Char) : Bool := '0' ≤ c ∧ c ≤ '9' def isHexDigitC (c : Char) : Bool := isDig...
@@ -80,6 +80,24 @@ (hn : c ≠ '\n') (hr : c ≠ '\r') (tail : QuotedBody rest) : QuotedBody (c :: rest) +theorem quotedBody_self {cs body rest} + (h : quotedBody cs = some (body, rest)) : QuotedBody body := by + fun_induction quotedBody cs generalizing body rest <;> simp_all + case case2 => exact .nil...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_d37620b977a0_0
f2f9daedc71731f5
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulParser/SoundC.lean
SoundC
0
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
2
1
[ { "theorem_name": "pmapC_eq", "depth": 1, "n_commands": 0, "n_lines": 2, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": "\n pmapC hp (fun a => by rw [hf a]) (fun a c => by rw [hf a]; exact c)", "n_chars": 70, "n_subproofs": 0, "n_tactics": 2, ...
[ { "name": "pmapC", "text": "theorem pmapC {α β : Type} {f : α → β} {p : Parser α}\n {pr : α → List Char} {pr' : β → List Char}\n (hp : SoundC p pr)\n (hf : ∀ a, canon (pr' (f a)) = canon (pr a))\n (hcl : ∀ a, Closed (pr a) → Closed (pr' (f a))) :\n SoundC (pmap f p) pr' := by\n intro cs b re...
[ { "name": "pmapC_eq", "fan_in": 0, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 10, "n_chars": 373, "n_subproofs": 0, "n_tactics": 2, "cyclomatic": 1, "n_automation": 0, "n_rewrites": 2, "n_structural": 1, "automation_only": false, "max_nesting": 2 ...
1
import YulParser.Canon import YulParser.Tokens /-! # YulParser.SoundC The `canon`-level soundness invariant and its combinator lemmas, mirroring `YulParser.Sound` but with `canon` in place of `fws`. Because `canon` is not a per-character filter, the invariant additionally carries `Closed (pr a)` (the printed form doe...
import YulParser.Canon import YulParser.Tokens /-! # YulParser.SoundC The `canon`-level soundness invariant and its combinator lemmas, mirroring `YulParser.Sound` but with `canon` in place of `fws`. Because `canon` is not a per-character filter, the invariant additionally carries `Closed (pr a)` (the printed form doe...
@@ -24,11 +24,26 @@ /-! ### Sequencing -/ +theorem pmapC {α β : Type} {f : α → β} {p : Parser α} + {pr : α → List Char} {pr' : β → List Char} + (hp : SoundC p pr) + (hf : ∀ a, canon (pr' (f a)) = canon (pr a)) + (hcl : ∀ a, Closed (pr a) → Closed (pr' (f a))) : + SoundC (pmap f p) pr' := by + intro...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_d37620b977a0_1
816eeacba4609190
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulParser/SoundC.lean
SoundC
1
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
2
1
[ { "theorem_name": "manyC", "depth": 1, "n_commands": 0, "n_lines": 7, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n intro cs a rest h\n simp only [manyP, Option.some.injEq] at h\n have ha : a = (many p cs).1 := by rw [h]\n have hr : rest = (many ...
[ { "name": "manyC_raw", "text": "theorem manyC_raw {α : Type} {p : Parser α} {pr : α → List Char} (hp : SoundC p pr)\n (cs : List Char) :\n canon (printManyC pr (many p cs).1) ++ canon (many p cs).2 = canon cs\n ∧ Closed (printManyC pr (many p cs).1) := by\n fun_induction many p cs with\n | case...
[ { "name": "manyC", "fan_in": 0, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 10, "n_chars": 322, "n_subproofs": 2, "n_tactics": 7, "cyclomatic": 1, "n_automation": 1, "n_rewrites": 3, "n_structural": 2, "automation_only": false, "max_nesting": 2 } ...
1
import YulParser.Canon import YulParser.Tokens /-! # YulParser.SoundC The `canon`-level soundness invariant and its combinator lemmas, mirroring `YulParser.Sound` but with `canon` in place of `fws`. Because `canon` is not a per-character filter, the invariant additionally carries `Closed (pr a)` (the printed form doe...
import YulParser.Canon import YulParser.Tokens /-! # YulParser.SoundC The `canon`-level soundness invariant and its combinator lemmas, mirroring `YulParser.Sound` but with `canon` in place of `fws`. Because `canon` is not a per-character filter, the invariant additionally carries `Closed (pr a)` (the printed form doe...
@@ -30,8 +30,31 @@ | [] => [] | a :: as => pr a ++ printManyC pr as +theorem manyC_raw {α : Type} {p : Parser α} {pr : α → List Char} (hp : SoundC p pr) + (cs : List Char) : + canon (printManyC pr (many p cs).1) ++ canon (many p cs).2 = canon cs + ∧ Closed (printManyC pr (many p cs).1) := by + fun_i...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_a44efa43f193_0
9d555175ddf06bcd
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/Correctness.lean
Correctness
0
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
2
2
[ { "theorem_name": "compile_correct", "depth": 1, "n_commands": 0, "n_lines": 51, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n -- unfold the pipeline\n rcases hpa : compileProgram prog with _ | asm\n · simp [compile, hpa] at hcomp\n · simp only [...
[ { "name": "compileProgramAsm_inv", "text": "/-- Invert a successful `compileProgram`: it hoisted the top scope,\nchecked its names `Nodup`, compiled the statements, and passed `wfCheck`. -/\ntheorem compileProgramAsm_inv {prog : YulSemantics.Block Op} {asm : List Asm}\n (h : compileProgram prog = some as...
[ { "name": "compile_correct", "fan_in": 1, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 74, "n_chars": 4073, "n_subproofs": 19, "n_tactics": 53, "cyclomatic": 7, "n_automation": 21, "n_rewrites": 5, "n_structural": 23, "automation_only": false, "max_n...
1
import YulEvmCompiler.SimAsm import YulEvmCompiler.LowerCorrect import YulEvmCompiler.OpStep /-! # YulEvmCompiler.Correctness The **end-to-end correctness theorem** for the labeled-assembly pipeline (`compile = compileProgram ≫ lowerProg`), composing the two proved simulations: * **Phase A** (`YulEvmCompiler.SimA.si...
import YulEvmCompiler.SimAsm import YulEvmCompiler.LowerCorrect import YulEvmCompiler.OpStep /-! # YulEvmCompiler.Correctness The **end-to-end correctness theorem** for the labeled-assembly pipeline (`compile = compileProgram ≫ lowerProg`), composing the two proved simulations: * **Phase A** (`YulEvmCompiler.SimA.si...
@@ -28,6 +28,37 @@ open YulSemantics.EVM (U256 EvmState Op stepOp) open YulSemantics (Outcome Ident VEnv) +/-- Invert a successful `compileProgram`: it hoisted the top scope, +checked its names `Nodup`, compiled the statements, and passed `wfCheck`. -/ +theorem compileProgramAsm_inv {prog : YulSemantics.Block Op} {...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_a44efa43f193_1
a97b067271bb6b09
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/Correctness.lean
Correctness
1
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
2
2
[ { "theorem_name": "compile_correct", "depth": 1, "n_commands": 0, "n_lines": 51, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n -- unfold the pipeline\n rcases hpa : compileProgram prog with _ | asm\n · simp [compile, hpa] at hcomp\n · simp only [...
[ { "name": "compileProgramAsm_inv", "text": "/-- Invert a successful `compileProgram`: it hoisted the top scope,\nchecked its names `Nodup`, compiled the statements, and passed `wfCheck`. -/\ntheorem compileProgramAsm_inv {prog : YulSemantics.Block Op} {asm : List Asm}\n (h : compileProgram prog = some as...
[ { "name": "compile_correct_withPayload", "fan_in": 0, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 67, "n_chars": 3515, "n_subproofs": 18, "n_tactics": 56, "cyclomatic": 7, "n_automation": 18, "n_rewrites": 5, "n_structural": 23, "automation_only": false...
1
import YulEvmCompiler.SimAsm import YulEvmCompiler.LowerCorrect import YulEvmCompiler.OpStep /-! # YulEvmCompiler.Correctness The **end-to-end correctness theorem** for the labeled-assembly pipeline (`compile = compileProgram ≫ lowerProg`), composing the two proved simulations: * **Phase A** (`YulEvmCompiler.SimA.si...
import YulEvmCompiler.SimAsm import YulEvmCompiler.LowerCorrect import YulEvmCompiler.OpStep /-! # YulEvmCompiler.Correctness The **end-to-end correctness theorem** for the labeled-assembly pipeline (`compile = compileProgram ≫ lowerProg`), composing the two proved simulations: * **Phase A** (`YulEvmCompiler.SimA.si...
@@ -28,6 +28,37 @@ open YulSemantics.EVM (U256 EvmState Op stepOp) open YulSemantics (Outcome Ident VEnv) +/-- Invert a successful `compileProgram`: it hoisted the top scope, +checked its names `Nodup`, compiled the statements, and passed `wfCheck`. -/ +theorem compileProgramAsm_inv {prog : YulSemantics.Block Op} {...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_a44efa43f193_2
83aa07d8aa3106b1
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/Correctness.lean
Correctness
2
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
2
2
[ { "theorem_name": "compile_correct", "depth": 1, "n_commands": 0, "n_lines": 51, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n -- unfold the pipeline\n rcases hpa : compileProgram prog with _ | asm\n · simp [compile, hpa] at hcomp\n · simp only [...
[ { "name": "compileProgramAsm_inv", "text": "/-- Invert a successful `compileProgram`: it hoisted the top scope,\nchecked its names `Nodup`, compiled the statements, and passed `wfCheck`. -/\ntheorem compileProgramAsm_inv {prog : YulSemantics.Block Op} {asm : List Asm}\n (h : compileProgram prog = some as...
[ { "name": "compile_correct_eval", "fan_in": 0, "n_deps_direct": 1, "n_deps_transitive": 2, "n_lines": 59, "n_chars": 2713, "n_subproofs": 11, "n_tactics": 53, "cyclomatic": 6, "n_automation": 11, "n_rewrites": 17, "n_structural": 23, "automation_only": false, ...
2
import YulEvmCompiler.SimAsm import YulEvmCompiler.LowerCorrect import YulEvmCompiler.OpStep /-! # YulEvmCompiler.Correctness The **end-to-end correctness theorem** for the labeled-assembly pipeline (`compile = compileProgram ≫ lowerProg`), composing the two proved simulations: * **Phase A** (`YulEvmCompiler.SimA.si...
import YulEvmCompiler.SimAsm import YulEvmCompiler.LowerCorrect import YulEvmCompiler.OpStep /-! # YulEvmCompiler.Correctness The **end-to-end correctness theorem** for the labeled-assembly pipeline (`compile = compileProgram ≫ lowerProg`), composing the two proved simulations: * **Phase A** (`YulEvmCompiler.SimA.si...
@@ -28,6 +28,37 @@ open YulSemantics.EVM (U256 EvmState Op stepOp) open YulSemantics (Outcome Ident VEnv) +/-- Invert a successful `compileProgram`: it hoisted the top scope, +checked its names `Nodup`, compiled the statements, and passed `wfCheck`. -/ +theorem compileProgramAsm_inv {prog : YulSemantics.Block Op} {...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_b936dd97ab22_0
0a5de09e10c7a61d
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/StateRel.lean
StateRel
0
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
6
1
[ { "theorem_name": "MemMatch.readBytes", "depth": 1, "n_commands": 0, "n_lines": 62, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n unfold YulSemantics.EVM.readBytes MachineState.readPadded\n dsimp only\n rw [ByteArray.toList_eq_data, ByteArray.data...
[ { "name": "nat_min_eq", "text": "/-- `MachineState.readPadded`, characterized pointwise against a matching\nfunctional memory. -/\nprivate theorem nat_min_eq (a b : Nat) : Nat.min a b = min a b := rfl\n\n", "fan_in": 1, "n_lines": 5, "n_chars": 167, "n_subproofs": 0, "n_tactics": 1, ...
[ { "name": "MemMatch.readBytes", "fan_in": 3, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 68, "n_chars": 2716, "n_subproofs": 4, "n_tactics": 63, "cyclomatic": 1, "n_automation": 26, "n_rewrites": 36, "n_structural": 2, "automation_only": false, "max...
1
import YulEvmCompiler.Decode import YulEvmCompiler.Value import YulEvmCompiler.BytesLemmas import EvmSemantics.EVM.BigStep /-! # YulEvmCompiler.StateRel The correspondence between the two machine states: * `MemMatch` — yul-semantics' total `Nat → UInt8` memory vs. evm-semantics' `ByteArray` with zero-padded read...
import YulEvmCompiler.Decode import YulEvmCompiler.Value import YulEvmCompiler.BytesLemmas import EvmSemantics.EVM.BigStep /-! # YulEvmCompiler.StateRel The correspondence between the two machine states: * `MemMatch` — yul-semantics' total `Nat → UInt8` memory vs. evm-semantics' `ByteArray` with zero-padded read...
@@ -32,9 +32,74 @@ def MemMatch (ymem : Nat → UInt8) (m : ByteArray) : Prop := ∀ a : Nat, ymem a = if h : a < m.size then m[a] else 0 +/-- `MachineState.readPadded`, characterized pointwise against a matching +functional memory. -/ +private theorem nat_min_eq (a b : Nat) : Nat.min a b = min a b := rfl + theorem ...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_b936dd97ab22_1
f879b00bc3f5b821
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/StateRel.lean
StateRel
1
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
6
1
[ { "theorem_name": "MemMatch.loadWord", "depth": 1, "n_commands": 0, "n_lines": 24, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n apply u256ext\n have hlen : (YulSemantics.EVM.readBytes ymem p 32).length = 32 := by\n unfold YulSemantics.EVM.readB...
[ { "name": "bitvec_fold_eq", "text": "private theorem bitvec_fold_eq (l : List UInt8) :\n ∀ acc : BitVec 256, l.length ≤ 32 → acc.toNat < 256 ^ (32 - l.length) →\n (l.foldl (fun (acc : BitVec 256) b =>\n (acc <<< (8 : Nat)) ||| BitVec.ofNat 256 b.toNat) acc).toNat\n = l.foldl (fun (ac...
[ { "name": "MemMatch.loadWord", "fan_in": 0, "n_deps_direct": 2, "n_deps_transitive": 2, "n_lines": 30, "n_chars": 1312, "n_subproofs": 5, "n_tactics": 26, "cyclomatic": 1, "n_automation": 6, "n_rewrites": 12, "n_structural": 3, "automation_only": false, "max_n...
2
import YulEvmCompiler.Decode import YulEvmCompiler.Value import YulEvmCompiler.BytesLemmas import EvmSemantics.EVM.BigStep /-! # YulEvmCompiler.StateRel The correspondence between the two machine states: * `MemMatch` — yul-semantics' total `Nat → UInt8` memory vs. evm-semantics' `ByteArray` with zero-padded read...
import YulEvmCompiler.Decode import YulEvmCompiler.Value import YulEvmCompiler.BytesLemmas import EvmSemantics.EVM.BigStep /-! # YulEvmCompiler.StateRel The correspondence between the two machine states: * `MemMatch` — yul-semantics' total `Nat → UInt8` memory vs. evm-semantics' `ByteArray` with zero-padded read...
@@ -121,11 +121,83 @@ have := ih (acc * 256 + b.toNat) (k + 1) hstep simpa [Nat.add_assoc, Nat.add_comm 1 l.length] using this +private theorem bitvec_fold_eq (l : List UInt8) : + ∀ acc : BitVec 256, l.length ≤ 32 → acc.toNat < 256 ^ (32 - l.length) → + (l.foldl (fun (acc : BitVec 256) b => + ...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_b936dd97ab22_2
1d86a0e1863fa911
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/StateRel.lean
StateRel
2
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
6
2
[ { "theorem_name": "MemMatch.storeWord", "depth": 1, "n_commands": 0, "n_lines": 11, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n intro a\n rw [← getD_eq_dite, MachineState.writeBytes_getElem?_getD,\n BytesLemmas.natToBytesPadded_size]\n simp o...
[ { "name": "byteAt_eq", "text": "/-- Yul's big-endian byte extractor as a divide-mod on the underlying `Nat`. -/\ntheorem byteAt_eq (v : YulSemantics.EVM.U256) (j : Nat) :\n YulSemantics.EVM.byteAt v j = UInt8.ofNat (v.toNat / 256 ^ j % 256) := by\n unfold YulSemantics.EVM.byteAt\n rw [BitVec.toNat_ushi...
[ { "name": "MemMatch.storeWord", "fan_in": 0, "n_deps_direct": 2, "n_deps_transitive": 2, "n_lines": 23, "n_chars": 1063, "n_subproofs": 1, "n_tactics": 11, "cyclomatic": 1, "n_automation": 2, "n_rewrites": 4, "n_structural": 2, "automation_only": false, "max_n...
2
import YulEvmCompiler.Decode import YulEvmCompiler.Value import YulEvmCompiler.BytesLemmas import EvmSemantics.EVM.BigStep /-! # YulEvmCompiler.StateRel The correspondence between the two machine states: * `MemMatch` — yul-semantics' total `Nat → UInt8` memory vs. evm-semantics' `ByteArray` with zero-padded read...
import YulEvmCompiler.Decode import YulEvmCompiler.Value import YulEvmCompiler.BytesLemmas import EvmSemantics.EVM.BigStep /-! # YulEvmCompiler.StateRel The correspondence between the two machine states: * `MemMatch` — yul-semantics' total `Nat → UInt8` memory vs. evm-semantics' `ByteArray` with zero-padded read...
@@ -37,6 +37,14 @@ m[a]?.getD 0 = if h : a < m.size then m[a] else 0 := by rw [getElem?_def]; split <;> rfl +/-- Yul's big-endian byte extractor as a divide-mod on the underlying `Nat`. -/ +theorem byteAt_eq (v : YulSemantics.EVM.U256) (j : Nat) : + YulSemantics.EVM.byteAt v j = UInt8.ofNat (v.toNat / 256 ...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_b936dd97ab22_3
b4d6c5d062f8fa72
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/StateRel.lean
StateRel
3
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
6
2
[ { "theorem_name": "MemMatch.storeWord", "depth": 1, "n_commands": 0, "n_lines": 11, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n intro a\n rw [← getD_eq_dite, MachineState.writeBytes_getElem?_getD,\n BytesLemmas.natToBytesPadded_size]\n simp o...
[ { "name": "byteAt_eq", "text": "/-- Yul's big-endian byte extractor as a divide-mod on the underlying `Nat`. -/\ntheorem byteAt_eq (v : YulSemantics.EVM.U256) (j : Nat) :\n YulSemantics.EVM.byteAt v j = UInt8.ofNat (v.toNat / 256 ^ j % 256) := by\n unfold YulSemantics.EVM.byteAt\n rw [BitVec.toNat_ushi...
[ { "name": "MemMatch.storeByte", "fan_in": 0, "n_deps_direct": 2, "n_deps_transitive": 2, "n_lines": 22, "n_chars": 933, "n_subproofs": 2, "n_tactics": 14, "cyclomatic": 1, "n_automation": 8, "n_rewrites": 6, "n_structural": 2, "automation_only": false, "max_ne...
2
import YulEvmCompiler.Decode import YulEvmCompiler.Value import YulEvmCompiler.BytesLemmas import EvmSemantics.EVM.BigStep /-! # YulEvmCompiler.StateRel The correspondence between the two machine states: * `MemMatch` — yul-semantics' total `Nat → UInt8` memory vs. evm-semantics' `ByteArray` with zero-padded read...
import YulEvmCompiler.Decode import YulEvmCompiler.Value import YulEvmCompiler.BytesLemmas import EvmSemantics.EVM.BigStep /-! # YulEvmCompiler.StateRel The correspondence between the two machine states: * `MemMatch` — yul-semantics' total `Nat → UInt8` memory vs. evm-semantics' `ByteArray` with zero-padded read...
@@ -37,6 +37,14 @@ m[a]?.getD 0 = if h : a < m.size then m[a] else 0 := by rw [getElem?_def]; split <;> rfl +/-- Yul's big-endian byte extractor as a divide-mod on the underlying `Nat`. -/ +theorem byteAt_eq (v : YulSemantics.EVM.U256) (j : Nat) : + YulSemantics.EVM.byteAt v j = UInt8.ofNat (v.toNat / 256 ...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_b936dd97ab22_4
827445ae06499dc0
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/StateRel.lean
StateRel
4
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
6
4
[ { "theorem_name": "MemMatch.storeWord", "depth": 1, "n_commands": 0, "n_lines": 11, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n intro a\n rw [← getD_eq_dite, MachineState.writeBytes_getElem?_getD,\n BytesLemmas.natToBytesPadded_size]\n simp o...
[ { "name": "getD_eq_dite", "text": "/-- Zero-padded read as the `dite` form of `MemMatch`. -/\ntheorem getD_eq_dite (m : ByteArray) (a : Nat) :\n m[a]?.getD 0 = if h : a < m.size then m[a] else 0 := by\n rw [getElem?_def]; split <;> rfl\n\n", "fan_in": 4, "n_lines": 6, "n_chars": 203, "n_...
[ { "name": "MemMatch.copyWithin", "fan_in": 0, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 30, "n_chars": 1437, "n_subproofs": 4, "n_tactics": 24, "cyclomatic": 1, "n_automation": 6, "n_rewrites": 5, "n_structural": 3, "automation_only": false, "max_...
1
import YulEvmCompiler.Decode import YulEvmCompiler.Value import YulEvmCompiler.BytesLemmas import EvmSemantics.EVM.BigStep /-! # YulEvmCompiler.StateRel The correspondence between the two machine states: * `MemMatch` — yul-semantics' total `Nat → UInt8` memory vs. evm-semantics' `ByteArray` with zero-padded read...
import YulEvmCompiler.Decode import YulEvmCompiler.Value import YulEvmCompiler.BytesLemmas import EvmSemantics.EVM.BigStep /-! # YulEvmCompiler.StateRel The correspondence between the two machine states: * `MemMatch` — yul-semantics' total `Nat → UInt8` memory vs. evm-semantics' `ByteArray` with zero-padded read...
@@ -103,13 +103,39 @@ /-! ### `MLOAD` agreement -/ +/-- Zero-padded read as the `dite` form of `MemMatch`. -/ +theorem getD_eq_dite (m : ByteArray) (a : Nat) : + m[a]?.getD 0 = if h : a < m.size then m[a] else 0 := by + rw [getElem?_def]; split <;> rfl + /-- `MCOPY` agreement: reading the source range before ...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_b936dd97ab22_5
b4071489c4d7a5b6
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/StateRel.lean
StateRel
5
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
6
4
[ { "theorem_name": "MemMatch.storeWord", "depth": 1, "n_commands": 0, "n_lines": 11, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n intro a\n rw [← getD_eq_dite, MachineState.writeBytes_getElem?_getD,\n BytesLemmas.natToBytesPadded_size]\n simp o...
[ { "name": "getD_eq_dite", "text": "/-- Zero-padded read as the `dite` form of `MemMatch`. -/\ntheorem getD_eq_dite (m : ByteArray) (a : Nat) :\n m[a]?.getD 0 = if h : a < m.size then m[a] else 0 := by\n rw [getElem?_def]; split <;> rfl\n\n", "fan_in": 4, "n_lines": 6, "n_chars": 203, "n_...
[ { "name": "MemMatch.copyFromBytes", "fan_in": 0, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 32, "n_chars": 1670, "n_subproofs": 4, "n_tactics": 22, "cyclomatic": 1, "n_automation": 6, "n_rewrites": 5, "n_structural": 3, "automation_only": false, "m...
1
import YulEvmCompiler.Decode import YulEvmCompiler.Value import YulEvmCompiler.BytesLemmas import EvmSemantics.EVM.BigStep /-! # YulEvmCompiler.StateRel The correspondence between the two machine states: * `MemMatch` — yul-semantics' total `Nat → UInt8` memory vs. evm-semantics' `ByteArray` with zero-padded read...
import YulEvmCompiler.Decode import YulEvmCompiler.Value import YulEvmCompiler.BytesLemmas import EvmSemantics.EVM.BigStep /-! # YulEvmCompiler.StateRel The correspondence between the two machine states: * `MemMatch` — yul-semantics' total `Nat → UInt8` memory vs. evm-semantics' `ByteArray` with zero-padded read...
@@ -103,6 +103,11 @@ /-! ### `MLOAD` agreement -/ +/-- Zero-padded read as the `dite` form of `MemMatch`. -/ +theorem getD_eq_dite (m : ByteArray) (a : Nat) : + m[a]?.getD 0 = if h : a < m.size then m[a] else 0 := by + rw [getElem?_def]; split <;> rfl + /-- Copying `n` bytes from an immutable byte region to m...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_7e2ccd04adb8_0
43e654beed429eee
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/AsmSem.lean
AsmSem
0
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
2
1
[ { "theorem_name": "snoc", "depth": 1, "n_commands": 0, "n_lines": 2, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": "\n h₁.trans (single h₂)", "n_chars": 27, "n_subproofs": 0, "n_tactics": 1, "cyclomatic": 1, "n_automation": 0, "n_re...
[ { "name": "single", "text": "theorem single {prog : List Asm} {a b : AConf} (h : AStep prog a b) :\n ASteps prog a b :=\n .head h (.refl b)\n\n", "fan_in": 1, "n_lines": 5, "n_chars": 114, "n_subproofs": 0, "n_tactics": 1, "cyclomatic": 1, "n_automation": 0, "n_rewrites":...
[ { "name": "snoc", "fan_in": 0, "n_deps_direct": 2, "n_deps_transitive": 2, "n_lines": 5, "n_chars": 149, "n_subproofs": 0, "n_tactics": 1, "cyclomatic": 1, "n_automation": 0, "n_rewrites": 0, "n_structural": 0, "automation_only": false, "max_nesting": 2 } ]
2
import YulEvmCompiler.Asm /-! # YulEvmCompiler.AsmSem The small-step semantics of the labeled assembly layer. A configuration holds the **remaining code** (always a suffix of the whole program `prog`, which parameterizes the step relation), an operand stack of `AVal`s, and the *Yul-side* machine state (`YulSemantics...
import YulEvmCompiler.Asm /-! # YulEvmCompiler.AsmSem The small-step semantics of the labeled assembly layer. A configuration holds the **remaining code** (always a suffix of the whole program `prog`, which parameterizes the step relation), an operand stack of `AVal`s, and the *Yul-side* machine state (`YulSemantics...
@@ -120,6 +120,10 @@ namespace ASteps +theorem single {prog : List Asm} {a b : AConf} (h : AStep prog a b) : + ASteps prog a b := + .head h (.refl b) + theorem trans {prog : List Asm} {a b c : AConf} (h₁ : ASteps prog a b) (h₂ : ASteps prog b c) : ASteps prog a c := by induction h₁ with @@ -127,7 +131...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_e1acfec129b6_0
ff77e89818728312
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/Decode.lean
Decode
0
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
16
1
[ { "theorem_name": "toList_loop_eq", "depth": 1, "n_commands": 0, "n_lines": 24, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n intro n\n induction n with\n | zero =>\n intro i r h\n unfold ByteArray.toList.loop\n rw [if_neg (by show ¬ i < ...
[ { "name": "get!_eq", "text": "private theorem get!_eq (bs : Array UInt8) (i : Nat) (hi : i < bs.toList.length) :\n ByteArray.get! ⟨bs⟩ i = bs.toList[i] := by\n show bs[i]! = _\n have hib : i < bs.size := by simpa using hi\n rw [getElem!_pos bs i hib]\n exact (Array.getElem_toList hib).symm\n\n", ...
[ { "name": "toList_loop_eq", "fan_in": 1, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 28, "n_chars": 975, "n_subproofs": 3, "n_tactics": 29, "cyclomatic": 2, "n_automation": 4, "n_rewrites": 15, "n_structural": 6, "automation_only": false, "max_nesti...
1
import YulEvmCompiler.OpTable import Batteries.Data.ByteArray /-! # YulEvmCompiler.Decode Layout lemmas: decoding assembled code at instruction boundaries. All `ByteArray` index arithmetic of the compiler proof is isolated here. The two main lemmas say that at position `pre.length` of `mkCode (pre ++ i.bytes ++ post...
import YulEvmCompiler.OpTable import Batteries.Data.ByteArray /-! # YulEvmCompiler.Decode Layout lemmas: decoding assembled code at instruction boundaries. All `ByteArray` index arithmetic of the compiler proof is isolated here. The two main lemmas say that at position `pre.length` of `mkCode (pre ++ i.bytes ++ post...
@@ -29,6 +29,13 @@ Core's `ByteArray.toList` is a tail-recursive loop; we relate it to `b.data.toList` once and never look at the loop again. -/ +private theorem get!_eq (bs : Array UInt8) (i : Nat) (hi : i < bs.toList.length) : + ByteArray.get! ⟨bs⟩ i = bs.toList[i] := by + show bs[i]! = _ + have hib : i < b...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_e1acfec129b6_1
a0f977073881a350
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/Decode.lean
Decode
1
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
16
4
[ { "theorem_name": "decodeAt_op", "depth": 1, "n_commands": 0, "n_lines": 13, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n show Decode.decodeAt (mkCode (pre ++ (Instr.opByte o :: []) ++ post)) pre.length = _\n have hsz : pre.length < (mkCode (pre +...
[ { "name": "getElem_boundary", "text": "/-- The byte at the start of an embedded instruction. -/\nprivate theorem getElem_boundary (pre post : List UInt8) (b : UInt8) (rest : List UInt8)\n (h : pre.length < (mkCode (pre ++ (b :: rest) ++ post)).size) :\n (mkCode (pre ++ (b :: rest) ++ post))[pre.length...
[ { "name": "decodeAt_op", "fan_in": 0, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 21, "n_chars": 855, "n_subproofs": 1, "n_tactics": 13, "cyclomatic": 2, "n_automation": 6, "n_rewrites": 4, "n_structural": 5, "automation_only": false, "max_nesting":...
1
import YulEvmCompiler.OpTable import Batteries.Data.ByteArray /-! # YulEvmCompiler.Decode Layout lemmas: decoding assembled code at instruction boundaries. All `ByteArray` index arithmetic of the compiler proof is isolated here. The two main lemmas say that at position `pre.length` of `mkCode (pre ++ i.bytes ++ post...
import YulEvmCompiler.OpTable import Batteries.Data.ByteArray /-! # YulEvmCompiler.Decode Layout lemmas: decoding assembled code at instruction boundaries. All `ByteArray` index arithmetic of the compiler proof is isolated here. The two main lemmas say that at position `pre.length` of `mkCode (pre ++ i.bytes ++ post...
@@ -79,11 +79,39 @@ | .Push _ | .DupN _ | .SwapN _ | .Exchange _ => False | _ => True +/-- The byte at the start of an embedded instruction. -/ +private theorem getElem_boundary (pre post : List UInt8) (b : UInt8) (rest : List UInt8) + (h : pre.length < (mkCode (pre ++ (b :: rest) ++ post)).size) : + (mkC...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_e1acfec129b6_2
80cf7180d201aa1e
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/Decode.lean
Decode
2
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
16
1
[ { "theorem_name": "u256_lt_pow", "depth": 1, "n_commands": 0, "n_lines": 5, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n intro v\n have h : v.toNat < 2 ^ 256 := v.val.isLt\n rw [pow_256_32]\n exact h", "n_chars": 84, "n_subproofs": 1, ...
[ { "name": "pow_256_32", "text": "private theorem pow_256_32 : (256 : Nat) ^ 32 = 2 ^ 256 := by\n have h8 : (256 : Nat) = 2 ^ 8 := by norm_num\n calc (256 : Nat) ^ 32 = (2 ^ 8) ^ 32 := by rw [h8]\n _ = 2 ^ (8 * 32) := (Nat.pow_mul 2 8 32).symm\n _ = 2 ^ 256 := by norm_num\n\n", "fan_in": 1, "...
[ { "name": "u256_lt_pow", "fan_in": 1, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 7, "n_chars": 154, "n_subproofs": 1, "n_tactics": 5, "cyclomatic": 1, "n_automation": 0, "n_rewrites": 1, "n_structural": 2, "automation_only": false, "max_nesting": 2...
1
import YulEvmCompiler.OpTable import Batteries.Data.ByteArray /-! # YulEvmCompiler.Decode Layout lemmas: decoding assembled code at instruction boundaries. All `ByteArray` index arithmetic of the compiler proof is isolated here. The two main lemmas say that at position `pre.length` of `mkCode (pre ++ i.bytes ++ post...
import YulEvmCompiler.OpTable import Batteries.Data.ByteArray /-! # YulEvmCompiler.Decode Layout lemmas: decoding assembled code at instruction boundaries. All `ByteArray` index arithmetic of the compiler proof is isolated here. The two main lemmas say that at position `pre.length` of `mkCode (pre ++ i.bytes ++ post...
@@ -79,8 +79,18 @@ | .Push _ | .DupN _ | .SwapN _ | .Exchange _ => False | _ => True -private theorem u256_lt_pow : ∀ v : UInt256, v.toNat < 256 ^ 32 := sorry +private theorem pow_256_32 : (256 : Nat) ^ 32 = 2 ^ 256 := by + have h8 : (256 : Nat) = 2 ^ 8 := by norm_num + calc (256 : Nat) ^ 32 = (2 ^ 8) ^ 32 :=...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_e1acfec129b6_3
2e31922a60aa3071
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/Decode.lean
Decode
3
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
16
1
[ { "theorem_name": "toList_loop_eq", "depth": 1, "n_commands": 0, "n_lines": 24, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n intro n\n induction n with\n | zero =>\n intro i r h\n unfold ByteArray.toList.loop\n rw [if_neg (by show ¬ i < ...
[ { "name": "get!_eq", "text": "private theorem get!_eq (bs : Array UInt8) (i : Nat) (hi : i < bs.toList.length) :\n ByteArray.get! ⟨bs⟩ i = bs.toList[i] := by\n show bs[i]! = _\n have hib : i < bs.size := by simpa using hi\n rw [getElem!_pos bs i hib]\n exact (Array.getElem_toList hib).symm\n\n", ...
[ { "name": "decodeAt_push", "fan_in": 0, "n_deps_direct": 6, "n_deps_transitive": 9, "n_lines": 28, "n_chars": 1398, "n_subproofs": 2, "n_tactics": 23, "cyclomatic": 1, "n_automation": 5, "n_rewrites": 15, "n_structural": 1, "automation_only": false, "max_nesti...
9
import YulEvmCompiler.OpTable import Batteries.Data.ByteArray /-! # YulEvmCompiler.Decode Layout lemmas: decoding assembled code at instruction boundaries. All `ByteArray` index arithmetic of the compiler proof is isolated here. The two main lemmas say that at position `pre.length` of `mkCode (pre ++ i.bytes ++ post...
import YulEvmCompiler.OpTable import Batteries.Data.ByteArray /-! # YulEvmCompiler.Decode Layout lemmas: decoding assembled code at instruction boundaries. All `ByteArray` index arithmetic of the compiler proof is isolated here. The two main lemmas say that at position `pre.length` of `mkCode (pre ++ i.bytes ++ post...
@@ -29,6 +29,13 @@ Core's `ByteArray.toList` is a tail-recursive loop; we relate it to `b.data.toList` once and never look at the loop again. -/ +private theorem get!_eq (bs : Array UInt8) (i : Nat) (hi : i < bs.toList.length) : + ByteArray.get! ⟨bs⟩ i = bs.toList[i] := by + show bs[i]! = _ + have hib : i < b...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_e1acfec129b6_4
95ee19d6ddae64b4
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/Decode.lean
Decode
4
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
16
3
[ { "theorem_name": "length_le_assembleBytes", "depth": 1, "n_commands": 0, "n_lines": 7, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n induction is with\n | nil => simp\n | cons i is ih =>\n have := bytes_pos i\n simp\n omega", "n_char...
[ { "name": "bytes_pos", "text": "private theorem bytes_pos (i : Instr) : 1 ≤ i.bytes.length := by\n cases i <;> simp\n\n", "fan_in": 3, "n_lines": 4, "n_chars": 87, "n_subproofs": 0, "n_tactics": 3, "cyclomatic": 3, "n_automation": 1, "n_rewrites": 0, "n_structural": 1, ...
[ { "name": "length_le_assembleBytes", "fan_in": 1, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 10, "n_chars": 210, "n_subproofs": 1, "n_tactics": 7, "cyclomatic": 2, "n_automation": 3, "n_rewrites": 0, "n_structural": 1, "automation_only": false, "ma...
1
import YulEvmCompiler.OpTable import Batteries.Data.ByteArray /-! # YulEvmCompiler.Decode Layout lemmas: decoding assembled code at instruction boundaries. All `ByteArray` index arithmetic of the compiler proof is isolated here. The two main lemmas say that at position `pre.length` of `mkCode (pre ++ i.bytes ++ post...
import YulEvmCompiler.OpTable import Batteries.Data.ByteArray /-! # YulEvmCompiler.Decode Layout lemmas: decoding assembled code at instruction boundaries. All `ByteArray` index arithmetic of the compiler proof is isolated here. The two main lemmas say that at position `pre.length` of `mkCode (pre ++ i.bytes ++ post...
@@ -83,8 +83,17 @@ (Operation.Push ⟨32, by decide⟩).availableInFork .Osaka = true := by decide +private theorem bytes_pos (i : Instr) : 1 ≤ i.bytes.length := by + cases i <;> simp + private theorem length_le_assembleBytes (is : List Instr) : - is.length ≤ (assembleBytes is).length := sorry + is.length...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_e1acfec129b6_5
dce23b52f2ae95cb
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/Decode.lean
Decode
5
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
16
1
[ { "theorem_name": "opcodeOf_opByte_not_push", "depth": 1, "n_commands": 0, "n_lines": 22, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n cases o with\n | StopArith op => cases op <;> rfl\n | CompBit op => cases op <;> rfl\n | Keccak op =>\n cas...
[ { "name": "dup_roundtrip", "text": "/-- `DUP1..DUP16` round-trip through their bytes (they are classic opcodes,\navailable on every fork — no EIP-8024 dependency). -/\ntheorem dup_roundtrip (n : Fin 16) :\n Decode.opcodeOf (Instr.opByte (.Dup ⟨n⟩)) = some (.Dup ⟨n⟩) ∧\n plainOp (Operation.Dup ⟨n⟩) ∧...
[ { "name": "opcodeOf_opByte_not_push", "fan_in": 1, "n_deps_direct": 2, "n_deps_transitive": 2, "n_lines": 29, "n_chars": 822, "n_subproofs": 2, "n_tactics": 28, "cyclomatic": 15, "n_automation": 12, "n_rewrites": 2, "n_structural": 10, "automation_only": false, ...
2
import YulEvmCompiler.OpTable import Batteries.Data.ByteArray /-! # YulEvmCompiler.Decode Layout lemmas: decoding assembled code at instruction boundaries. All `ByteArray` index arithmetic of the compiler proof is isolated here. The two main lemmas say that at position `pre.length` of `mkCode (pre ++ i.bytes ++ post...
import YulEvmCompiler.OpTable import Batteries.Data.ByteArray /-! # YulEvmCompiler.Decode Layout lemmas: decoding assembled code at instruction boundaries. All `ByteArray` index arithmetic of the compiler proof is isolated here. The two main lemmas say that at position `pre.length` of `mkCode (pre ++ i.bytes ++ post...
@@ -83,6 +83,14 @@ (Operation.Push ⟨32, by decide⟩).availableInFork .Osaka = true := by decide +/-- `DUP1..DUP16` round-trip through their bytes (they are classic opcodes, +available on every fork — no EIP-8024 dependency). -/ +theorem dup_roundtrip (n : Fin 16) : + Decode.opcodeOf (Instr.opByte (.Dup ⟨n⟩)...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_e1acfec129b6_6
788dd0c72d17c3f0
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/Decode.lean
Decode
6
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
16
4
[ { "theorem_name": "decodeAt_op", "depth": 1, "n_commands": 0, "n_lines": 13, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n show Decode.decodeAt (mkCode (pre ++ (Instr.opByte o :: []) ++ post)) pre.length = _\n have hsz : pre.length < (mkCode (pre +...
[ { "name": "getElem_boundary", "text": "/-- The byte at the start of an embedded instruction. -/\nprivate theorem getElem_boundary (pre post : List UInt8) (b : UInt8) (rest : List UInt8)\n (h : pre.length < (mkCode (pre ++ (b :: rest) ++ post)).size) :\n (mkCode (pre ++ (b :: rest) ++ post))[pre.length...
[ { "name": "pushDataSize_at", "fan_in": 1, "n_deps_direct": 3, "n_deps_transitive": 5, "n_lines": 24, "n_chars": 909, "n_subproofs": 4, "n_tactics": 19, "cyclomatic": 2, "n_automation": 5, "n_rewrites": 5, "n_structural": 2, "automation_only": false, "max_nesti...
5
import YulEvmCompiler.OpTable import Batteries.Data.ByteArray /-! # YulEvmCompiler.Decode Layout lemmas: decoding assembled code at instruction boundaries. All `ByteArray` index arithmetic of the compiler proof is isolated here. The two main lemmas say that at position `pre.length` of `mkCode (pre ++ i.bytes ++ post...
import YulEvmCompiler.OpTable import Batteries.Data.ByteArray /-! # YulEvmCompiler.Decode Layout lemmas: decoding assembled code at instruction boundaries. All `ByteArray` index arithmetic of the compiler proof is isolated here. The two main lemmas say that at position `pre.length` of `mkCode (pre ++ i.bytes ++ post...
@@ -79,6 +79,22 @@ | .Push _ | .DupN _ | .SwapN _ | .Exchange _ => False | _ => True +/-- The byte at the start of an embedded instruction. -/ +private theorem getElem_boundary (pre post : List UInt8) (b : UInt8) (rest : List UInt8) + (h : pre.length < (mkCode (pre ++ (b :: rest) ++ post)).size) : + (mkCo...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_e1acfec129b6_7
899c15c4ea05db0e
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/Decode.lean
Decode
7
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
16
4
[ { "theorem_name": "decodeAt_op", "depth": 1, "n_commands": 0, "n_lines": 13, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n show Decode.decodeAt (mkCode (pre ++ (Instr.opByte o :: []) ++ post)) pre.length = _\n have hsz : pre.length < (mkCode (pre +...
[ { "name": "getElem_boundary", "text": "/-- The byte at the start of an embedded instruction. -/\nprivate theorem getElem_boundary (pre post : List UInt8) (b : UInt8) (rest : List UInt8)\n (h : pre.length < (mkCode (pre ++ (b :: rest) ++ post)).size) :\n (mkCode (pre ++ (b :: rest) ++ post))[pre.length...
[ { "name": "walk_through", "fan_in": 1, "n_deps_direct": 4, "n_deps_transitive": 7, "n_lines": 66, "n_chars": 2556, "n_subproofs": 9, "n_tactics": 60, "cyclomatic": 4, "n_automation": 21, "n_rewrites": 18, "n_structural": 9, "automation_only": false, "max_nesti...
6
import YulEvmCompiler.OpTable import Batteries.Data.ByteArray /-! # YulEvmCompiler.Decode Layout lemmas: decoding assembled code at instruction boundaries. All `ByteArray` index arithmetic of the compiler proof is isolated here. The two main lemmas say that at position `pre.length` of `mkCode (pre ++ i.bytes ++ post...
import YulEvmCompiler.OpTable import Batteries.Data.ByteArray /-! # YulEvmCompiler.Decode Layout lemmas: decoding assembled code at instruction boundaries. All `ByteArray` index arithmetic of the compiler proof is isolated here. The two main lemmas say that at position `pre.length` of `mkCode (pre ++ i.bytes ++ post...
@@ -79,6 +79,22 @@ | .Push _ | .DupN _ | .SwapN _ | .Exchange _ => False | _ => True +/-- The byte at the start of an embedded instruction. -/ +private theorem getElem_boundary (pre post : List UInt8) (b : UInt8) (rest : List UInt8) + (h : pre.length < (mkCode (pre ++ (b :: rest) ++ post)).size) : + (mkCo...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_e1acfec129b6_8
92d6afcb62376327
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulEvmCompiler/Decode.lean
Decode
8
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
16
4
[ { "theorem_name": "decodeAt_op", "depth": 1, "n_commands": 0, "n_lines": 13, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n show Decode.decodeAt (mkCode (pre ++ (Instr.opByte o :: []) ++ post)) pre.length = _\n have hsz : pre.length < (mkCode (pre +...
[ { "name": "getElem_boundary", "text": "/-- The byte at the start of an embedded instruction. -/\nprivate theorem getElem_boundary (pre post : List UInt8) (b : UInt8) (rest : List UInt8)\n (h : pre.length < (mkCode (pre ++ (b :: rest) ++ post)).size) :\n (mkCode (pre ++ (b :: rest) ++ post))[pre.length...
[ { "name": "isValidJumpDest_boundary", "fan_in": 0, "n_deps_direct": 2, "n_deps_transitive": 9, "n_lines": 21, "n_chars": 779, "n_subproofs": 3, "n_tactics": 14, "cyclomatic": 1, "n_automation": 4, "n_rewrites": 3, "n_structural": 0, "automation_only": false, "...
8
import YulEvmCompiler.OpTable import Batteries.Data.ByteArray /-! # YulEvmCompiler.Decode Layout lemmas: decoding assembled code at instruction boundaries. All `ByteArray` index arithmetic of the compiler proof is isolated here. The two main lemmas say that at position `pre.length` of `mkCode (pre ++ i.bytes ++ post...
import YulEvmCompiler.OpTable import Batteries.Data.ByteArray /-! # YulEvmCompiler.Decode Layout lemmas: decoding assembled code at instruction boundaries. All `ByteArray` index arithmetic of the compiler proof is isolated here. The two main lemmas say that at position `pre.length` of `mkCode (pre ++ i.bytes ++ post...
@@ -79,6 +79,22 @@ | .Push _ | .DupN _ | .SwapN _ | .Exchange _ => False | _ => True +/-- The byte at the start of an embedded instruction. -/ +private theorem getElem_boundary (pre post : List UInt8) (b : UInt8) (rest : List UInt8) + (h : pre.length < (mkCode (pre ++ (b :: rest) ++ post)).size) : + (mkCo...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_af542b3ca6e9_0
5fc242b1821b7aaf
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulParser/Atoms.lean
Atoms
0
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
22
1
[ { "theorem_name": "pIdent_soundC", "depth": 1, "n_commands": 0, "n_lines": 3, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n apply pmapC_eq pIdentChars_soundC\n intro d; rw [String.toList_ofList]", "n_chars": 76, "n_subproofs": 0, "n_tac...
[ { "name": "pIdentChars_soundC", "text": "theorem pIdentChars_soundC : SoundC pIdentChars (fun d => d ++ [' ']) := by\n intro cs d rest h\n simp only [pIdentChars, token] at h\n set cs' := YulParser.skipTrivia cs with hcs'\n cases hc : cs' with\n | nil => rw [hc] at h; simp [pWhile1] at h\n | cons c r ...
[ { "name": "pIdent_soundC", "fan_in": 0, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 7, "n_chars": 167, "n_subproofs": 0, "n_tactics": 4, "cyclomatic": 1, "n_automation": 0, "n_rewrites": 1, "n_structural": 2, "automation_only": false, "max_nesting":...
1
import YulParser.SoundC import YulSemantics.Ast /-! # YulParser.Atoms Atomic parsers producing `yul-semantics` values (`Literal`, identifiers as `String`), plus keyword and punctuation tokens. Each atom prints its token followed by a delimiting space (so the printed form is `Closed`), and is proven `SoundC`. -/ name...
import YulParser.SoundC import YulSemantics.Ast /-! # YulParser.Atoms Atomic parsers producing `yul-semantics` values (`Literal`, identifiers as `String`), plus keyword and punctuation tokens. Each atom prints its token followed by a delimiting space (so the printed form is `Closed`), and is proven `SoundC`. -/ name...
@@ -21,10 +21,43 @@ /-- Raw identifier characters (whitespace-skipping). -/ def pIdentChars : Parser (List Char) := token (pWhile1 isIdStart isIdCont) +theorem pIdentChars_soundC : SoundC pIdentChars (fun d => d ++ [' ']) := by + intro cs d rest h + simp only [pIdentChars, token] at h + set cs' := YulParser.skip...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_af542b3ca6e9_1
824ce4c95140ef4c
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulParser/Atoms.lean
Atoms
1
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
22
1
[ { "theorem_name": "decDigits_all_digitC", "depth": 1, "n_commands": 0, "n_lines": 14, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n induction n using Nat.strong_induction_on with\n | _ n ih =>\n rw [decDigits]\n split\n · rename_i h; intro...
[ { "name": "isDigitC_digitChar", "text": "theorem isDigitC_digitChar {d : Nat} (h : d < 10) : isDigitC (digitChar d) = true := by\n interval_cases d <;> decide\n\n", "fan_in": 1, "n_lines": 4, "n_chars": 119, "n_subproofs": 0, "n_tactics": 3, "cyclomatic": 2, "n_automation": 1, ...
[ { "name": "decDigits_all_digitC", "fan_in": 3, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 16, "n_chars": 576, "n_subproofs": 0, "n_tactics": 18, "cyclomatic": 4, "n_automation": 5, "n_rewrites": 4, "n_structural": 7, "automation_only": false, "max_...
1
import YulParser.SoundC import YulSemantics.Ast /-! # YulParser.Atoms Atomic parsers producing `yul-semantics` values (`Literal`, identifiers as `String`), plus keyword and punctuation tokens. Each atom prints its token followed by a delimiting space (so the printed form is `Closed`), and is proven `SoundC`. -/ name...
import YulParser.SoundC import YulSemantics.Ast /-! # YulParser.Atoms Atomic parsers producing `yul-semantics` values (`Literal`, identifiers as `String`), plus keyword and punctuation tokens. Each atom prints its token followed by a delimiting space (so the printed form is `Closed`), and is proven `SoundC`. -/ name...
@@ -33,18 +33,23 @@ termination_by n decreasing_by exact Nat.div_lt_self (by omega) (by omega) +theorem isDigitC_digitChar {d : Nat} (h : d < 10) : isDigitC (digitChar d) = true := by + interval_cases d <;> decide + theorem decDigits_all_digitC (n : Nat) : ∀ x ∈ decDigits n, isDigitC x = true := by inducti...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_af542b3ca6e9_2
db7d55c5e6a7f894
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulParser/Atoms.lean
Atoms
2
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
22
1
[ { "theorem_name": "evalDec_decDigits", "depth": 1, "n_commands": 0, "n_lines": 11, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n induction n using Nat.strong_induction_on with\n | _ n ih =>\n rw [decDigits]\n split\n · rename_i h; simp onl...
[ { "name": "evalDec_concat", "text": "theorem evalDec_concat (a : List Char) (x : Char) :\n evalDec (a ++ [x]) = evalDec a * 10 + decDigitVal x := by\n simp only [evalDec, List.foldl_append, List.foldl_cons, List.foldl_nil]\n\n", "fan_in": 1, "n_lines": 5, "n_chars": 189, "n_subproofs": 0...
[ { "name": "evalDec_decDigits", "fan_in": 1, "n_deps_direct": 2, "n_deps_transitive": 2, "n_lines": 13, "n_chars": 462, "n_subproofs": 0, "n_tactics": 12, "cyclomatic": 3, "n_automation": 5, "n_rewrites": 2, "n_structural": 1, "automation_only": false, "max_nes...
2
import YulParser.SoundC import YulSemantics.Ast /-! # YulParser.Atoms Atomic parsers producing `yul-semantics` values (`Literal`, identifiers as `String`), plus keyword and punctuation tokens. Each atom prints its token followed by a delimiting space (so the printed form is `Closed`), and is proven `SoundC`. -/ name...
import YulParser.SoundC import YulSemantics.Ast /-! # YulParser.Atoms Atomic parsers producing `yul-semantics` values (`Literal`, identifiers as `String`), plus keyword and punctuation tokens. Each atom prints its token followed by a delimiting space (so the printed form is `Closed`), and is proven `SoundC`. -/ name...
@@ -36,6 +36,10 @@ theorem decDigitVal_digitChar {d : Nat} (h : d < 10) : decDigitVal (digitChar d) = d := by interval_cases d <;> decide +theorem evalDec_concat (a : List Char) (x : Char) : + evalDec (a ++ [x]) = evalDec a * 10 + decDigitVal x := by + simp only [evalDec, List.foldl_append, List.foldl_cons, L...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_af542b3ca6e9_3
b63d5e06b7918025
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulParser/Atoms.lean
Atoms
3
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
22
1
[ { "theorem_name": "numVal_decDigits", "depth": 1, "n_commands": 0, "n_lines": 2, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n rw [numVal_eq_evalDec _ (decDigits_all_digitC n), evalDec_decDigits n]", "n_chars": 76, "n_subproofs": 0, "n_t...
[ { "name": "evalDec_decDigits", "text": "theorem evalDec_decDigits (n : Nat) : evalDec (decDigits n) = n := by\n induction n using Nat.strong_induction_on with\n | _ n ih =>\n rw [decDigits]\n split\n · rename_i h; simp only [evalDec, List.foldl_cons, List.foldl_nil, Nat.zero_mul,\n Nat.zer...
[ { "name": "numVal_decDigits", "fan_in": 1, "n_deps_direct": 3, "n_deps_transitive": 6, "n_lines": 4, "n_chars": 142, "n_subproofs": 0, "n_tactics": 2, "cyclomatic": 1, "n_automation": 0, "n_rewrites": 1, "n_structural": 0, "automation_only": false, "max_nestin...
6
import YulParser.SoundC import YulSemantics.Ast /-! # YulParser.Atoms Atomic parsers producing `yul-semantics` values (`Literal`, identifiers as `String`), plus keyword and punctuation tokens. Each atom prints its token followed by a delimiting space (so the printed form is `Closed`), and is proven `SoundC`. -/ name...
import YulParser.SoundC import YulSemantics.Ast /-! # YulParser.Atoms Atomic parsers producing `yul-semantics` values (`Literal`, identifiers as `String`), plus keyword and punctuation tokens. Each atom prints its token followed by a delimiting space (so the printed form is `Closed`), and is proven `SoundC`. -/ name...
@@ -58,6 +58,18 @@ evalDec (a ++ [x]) = evalDec a * 10 + decDigitVal x := by simp only [evalDec, List.foldl_append, List.foldl_cons, List.foldl_nil] +theorem evalDec_decDigits (n : Nat) : evalDec (decDigits n) = n := by + induction n using Nat.strong_induction_on with + | _ n ih => + rw [decDigits] + ...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_af542b3ca6e9_4
e78db3bbe95d3e0b
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulParser/Atoms.lean
Atoms
4
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
22
1
[ { "theorem_name": "evalDec_decDigits", "depth": 1, "n_commands": 0, "n_lines": 11, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n induction n using Nat.strong_induction_on with\n | _ n ih =>\n rw [decDigits]\n split\n · rename_i h; simp onl...
[ { "name": "evalDec_concat", "text": "theorem evalDec_concat (a : List Char) (x : Char) :\n evalDec (a ++ [x]) = evalDec a * 10 + decDigitVal x := by\n simp only [evalDec, List.foldl_append, List.foldl_cons, List.foldl_nil]\n\n", "fan_in": 1, "n_lines": 5, "n_chars": 189, "n_subproofs": 0...
[ { "name": "canon_decDigits", "fan_in": 1, "n_deps_direct": 4, "n_deps_transitive": 9, "n_lines": 17, "n_chars": 1030, "n_subproofs": 4, "n_tactics": 17, "cyclomatic": 2, "n_automation": 7, "n_rewrites": 5, "n_structural": 4, "automation_only": false, "max_nest...
9
import YulParser.SoundC import YulSemantics.Ast /-! # YulParser.Atoms Atomic parsers producing `yul-semantics` values (`Literal`, identifiers as `String`), plus keyword and punctuation tokens. Each atom prints its token followed by a delimiting space (so the printed form is `Closed`), and is proven `SoundC`. -/ name...
import YulParser.SoundC import YulSemantics.Ast /-! # YulParser.Atoms Atomic parsers producing `yul-semantics` values (`Literal`, identifiers as `String`), plus keyword and punctuation tokens. Each atom prints its token followed by a delimiting space (so the printed form is `Closed`), and is proven `SoundC`. -/ name...
@@ -62,6 +62,10 @@ · simp · simp +theorem evalDec_concat (a : List Char) (x : Char) : + evalDec (a ++ [x]) = evalDec a * 10 + decDigitVal x := by + simp only [evalDec, List.foldl_append, List.foldl_cons, List.foldl_nil] + theorem evalDec_decDigits (n : Nat) : evalDec (decDigits n) = n := by induction n ...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_af542b3ca6e9_5
ae5cb437da0efa00
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulParser/Atoms.lean
Atoms
5
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
22
2
[ { "theorem_name": "canon_decDigits", "depth": 1, "n_commands": 0, "n_lines": 14, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n obtain ⟨c, ts, hcts⟩ : ∃ c ts, decDigits n = c :: ts := by\n cases h : decDigits n with\n | nil => exact absurd h (d...
[ { "name": "decDigits_ne_nil", "text": "theorem decDigits_ne_nil (n : Nat) : decDigits n ≠ [] := by\n rw [decDigits]; split\n · simp\n · simp\n\n", "fan_in": 2, "n_lines": 6, "n_chars": 107, "n_subproofs": 0, "n_tactics": 5, "cyclomatic": 2, "n_automation": 2, "n_rewrites":...
[ { "name": "closed_decDigits", "fan_in": 1, "n_deps_direct": 3, "n_deps_transitive": 4, "n_lines": 14, "n_chars": 624, "n_subproofs": 4, "n_tactics": 14, "cyclomatic": 2, "n_automation": 4, "n_rewrites": 4, "n_structural": 5, "automation_only": false, "max_nest...
4
import YulParser.SoundC import YulSemantics.Ast /-! # YulParser.Atoms Atomic parsers producing `yul-semantics` values (`Literal`, identifiers as `String`), plus keyword and punctuation tokens. Each atom prints its token followed by a delimiting space (so the printed form is `Closed`), and is proven `SoundC`. -/ name...
import YulParser.SoundC import YulSemantics.Ast /-! # YulParser.Atoms Atomic parsers producing `yul-semantics` values (`Literal`, identifiers as `String`), plus keyword and punctuation tokens. Each atom prints its token followed by a delimiting space (so the printed form is `Closed`), and is proven `SoundC`. -/ name...
@@ -54,10 +54,15 @@ · simp only [List.mem_singleton] at hx; subst hx exact isDigitC_digitChar (Nat.mod_lt _ (by omega)) +theorem decDigits_ne_nil (n : Nat) : decDigits n ≠ [] := by + rw [decDigits]; split + · simp + · simp + theorem closed_decDigits (n : Nat) : Closed (decDigits n ++ [' ']) := by ...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_af542b3ca6e9_7
a85a10284b773113
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulParser/Atoms.lean
Atoms
7
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
22
1
[ { "theorem_name": "keywordC", "depth": 1, "n_commands": 0, "n_lines": 21, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n intro cs a rest h\n simp only [keyword, token, pmap, YulParser.andThen] at h\n cases hp : pstr (c :: ts) (YulParser.skipTrivia ...
[ { "name": "canon_ident_space", "text": "/-- `canon` of an identifier token followed by a space is a single `ident`. -/\ntheorem canon_ident_space {c : Char} {ts : List Char} (hc : isIdStart c = true)\n (hts : ∀ x ∈ ts, isIdCont x = true) : canon ((c :: ts) ++ [' ']) = [CTok.ident (c :: ts)] := by\n have...
[ { "name": "keywordC", "fan_in": 1, "n_deps_direct": 4, "n_deps_transitive": 5, "n_lines": 26, "n_chars": 1137, "n_subproofs": 5, "n_tactics": 24, "cyclomatic": 3, "n_automation": 6, "n_rewrites": 6, "n_structural": 8, "automation_only": false, "max_nesting": 8...
5
import YulParser.SoundC import YulSemantics.Ast /-! # YulParser.Atoms Atomic parsers producing `yul-semantics` values (`Literal`, identifiers as `String`), plus keyword and punctuation tokens. Each atom prints its token followed by a delimiting space (so the printed form is `Closed`), and is proven `SoundC`. -/ name...
import YulParser.SoundC import YulSemantics.Ast /-! # YulParser.Atoms Atomic parsers producing `yul-semantics` values (`Literal`, identifiers as `String`), plus keyword and punctuation tokens. Each atom prints its token followed by a delimiting space (so the printed form is `Closed`), and is proven `SoundC`. -/ name...
@@ -89,6 +89,16 @@ · rw [List.takeWhile_cons, hcont]; rfl · rw [List.dropWhile_cons, hcont]; rfl +/-- `canon` of an identifier token followed by a space is a single `ident`. -/ +theorem canon_ident_space {c : Char} {ts : List Char} (hc : isIdStart c = true) + (hts : ∀ x ∈ ts, isIdCont x = true) : can...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_af542b3ca6e9_8
77e6a19b986dd085
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulParser/Atoms.lean
Atoms
8
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
22
2
[ { "theorem_name": "keywordC", "depth": 1, "n_commands": 0, "n_lines": 21, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n intro cs a rest h\n simp only [keyword, token, pmap, YulParser.andThen] at h\n cases hp : pstr (c :: ts) (YulParser.skipTrivia ...
[ { "name": "pstr_consumes", "text": "theorem pstr_consumes : ∀ (s cs r : List Char), pstr s cs = some ((), r) → cs = s ++ r\n | [], cs, r, h => by simp only [pstr, YulParser.ppure, Option.some.injEq, Prod.mk.injEq] at h;\n rw [h.2]; rfl\n | c :: s', cs, r, h => by\n simp only [pstr...
[ { "name": "symbolC", "fan_in": 0, "n_deps_direct": 1, "n_deps_transitive": 2, "n_lines": 13, "n_chars": 511, "n_subproofs": 1, "n_tactics": 7, "cyclomatic": 1, "n_automation": 3, "n_rewrites": 1, "n_structural": 2, "automation_only": false, "max_nesting": 4 ...
2
import YulParser.SoundC import YulSemantics.Ast /-! # YulParser.Atoms Atomic parsers producing `yul-semantics` values (`Literal`, identifiers as `String`), plus keyword and punctuation tokens. Each atom prints its token followed by a delimiting space (so the printed form is `Closed`), and is proven `SoundC`. -/ name...
import YulParser.SoundC import YulSemantics.Ast /-! # YulParser.Atoms Atomic parsers producing `yul-semantics` values (`Literal`, identifiers as `String`), plus keyword and punctuation tokens. Each atom prints its token followed by a delimiting space (so the printed form is `Closed`), and is proven `SoundC`. -/ name...
@@ -57,9 +57,28 @@ obtain ⟨rfl, rfl⟩ := h; rw [beq_iff_eq] at hp; rw [hp] · rw [if_neg hp] at h; exact absurd h (by simp) +theorem pstr_consumes : ∀ (s cs r : List Char), pstr s cs = some ((), r) → cs = s ++ r + | [], cs, r, h => by simp only [pstr, YulParser.ppure, Option.some.injEq, Prod.mk.injEq] at h...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_af542b3ca6e9_9
cf2fb31252ececa3
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulParser/Atoms.lean
Atoms
9
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
22
1
[ { "theorem_name": "numVal_decDigits", "depth": 1, "n_commands": 0, "n_lines": 2, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n rw [numVal_eq_evalDec _ (decDigits_all_digitC n), evalDec_decDigits n]", "n_chars": 76, "n_subproofs": 0, "n_t...
[ { "name": "numVal_eq_evalDec", "text": "/-- On an all-decimal token, `numVal` is just `evalDec` (the `0x` guard cannot fire). -/\ntheorem numVal_eq_evalDec (l : List Char) (h : ∀ x ∈ l, isDigitC x = true) :\n numVal l = evalDec l := by\n unfold numVal\n split\n · exact absurd (h 'x' (by simp)) (by dec...
[ { "name": "pNum_soundC", "fan_in": 1, "n_deps_direct": 2, "n_deps_transitive": 11, "n_lines": 29, "n_chars": 1216, "n_subproofs": 5, "n_tactics": 28, "cyclomatic": 3, "n_automation": 10, "n_rewrites": 5, "n_structural": 7, "automation_only": false, "max_nestin...
11
import YulParser.SoundC import YulSemantics.Ast /-! # YulParser.Atoms Atomic parsers producing `yul-semantics` values (`Literal`, identifiers as `String`), plus keyword and punctuation tokens. Each atom prints its token followed by a delimiting space (so the printed form is `Closed`), and is proven `SoundC`. -/ name...
import YulParser.SoundC import YulSemantics.Ast /-! # YulParser.Atoms Atomic parsers producing `yul-semantics` values (`Literal`, identifiers as `String`), plus keyword and punctuation tokens. Each atom prints its token followed by a delimiting space (so the printed form is `Closed`), and is proven `SoundC`. -/ name...
@@ -78,8 +78,18 @@ decDigitVal_digitChar (Nat.mod_lt _ (by omega))] omega -theorem numVal_decDigits (n : Nat) : numVal (decDigits n) = n := sorry +/-- On an all-decimal token, `numVal` is just `evalDec` (the `0x` guard cannot fire). -/ +theorem numVal_eq_evalDec (l : List Char) (h : ∀ x ∈ l, isDigitC ...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_af542b3ca6e9_10
0a17c8af28ee5ee8
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulParser/Atoms.lean
Atoms
10
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
22
1
[ { "theorem_name": "pStr_soundC", "depth": 1, "n_commands": 0, "n_lines": 4, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n apply pmapC_eq pStringChars_soundC\n intro content\n simp [printLitC, printStringC]", "n_chars": 89, "n_subproofs": 0...
[ { "name": "pStringChars_soundC", "text": "theorem pStringChars_soundC : SoundC pStringChars printStringC := by\n intro cs content rest h\n simp only [pStringChars, token] at h\n have hbody := pQuotedChars_body h\n have hp : pQuotedChars (printStringC content) = some (content, [' ']) := by\n show quot...
[ { "name": "pStr_soundC", "fan_in": 1, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 8, "n_chars": 190, "n_subproofs": 0, "n_tactics": 4, "cyclomatic": 1, "n_automation": 1, "n_rewrites": 0, "n_structural": 2, "automation_only": false, "max_nesting": 2...
1
import YulParser.SoundC import YulSemantics.Ast /-! # YulParser.Atoms Atomic parsers producing `yul-semantics` values (`Literal`, identifiers as `String`), plus keyword and punctuation tokens. Each atom prints its token followed by a delimiting space (so the printed form is `Closed`), and is proven `SoundC`. -/ name...
import YulParser.SoundC import YulSemantics.Ast /-! # YulParser.Atoms Atomic parsers producing `yul-semantics` values (`Literal`, identifiers as `String`), plus keyword and punctuation tokens. Each atom prints its token followed by a delimiting space (so the printed form is `Closed`), and is proven `SoundC`. -/ name...
@@ -49,6 +49,19 @@ /-- A quoted string token, retaining the source spelling of escapes. -/ def pStringChars : Parser (List Char) := token pQuotedChars +theorem pStringChars_soundC : SoundC pStringChars printStringC := by + intro cs content rest h + simp only [pStringChars, token] at h + have hbody := pQuotedChar...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_af542b3ca6e9_11
a261d7e8c29d9903
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulParser/Atoms.lean
Atoms
11
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
22
1
[ { "theorem_name": "keywordC", "depth": 1, "n_commands": 0, "n_lines": 21, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n intro cs a rest h\n simp only [keyword, token, pmap, YulParser.andThen] at h\n cases hp : pstr (c :: ts) (YulParser.skipTrivia ...
[ { "name": "canon_ident_boundary", "text": "/-- `canon` of an identifier token followed by a boundary (non-`idCont`) continuation. -/\ntheorem canon_ident_boundary {c : Char} {ts rest : List Char} (hc : isIdStart c = true)\n (hts : ∀ x ∈ ts, isIdCont x = true)\n (htk : rest.takeWhile isIdCont = []) (hd...
[ { "name": "pBool_soundC", "fan_in": 1, "n_deps_direct": 1, "n_deps_transitive": 6, "n_lines": 6, "n_chars": 248, "n_subproofs": 0, "n_tactics": 7, "cyclomatic": 3, "n_automation": 6, "n_rewrites": 0, "n_structural": 2, "automation_only": false, "max_nesting": ...
6
import YulParser.SoundC import YulSemantics.Ast /-! # YulParser.Atoms Atomic parsers producing `yul-semantics` values (`Literal`, identifiers as `String`), plus keyword and punctuation tokens. Each atom prints its token followed by a delimiting space (so the printed form is `Closed`), and is proven `SoundC`. -/ name...
import YulParser.SoundC import YulSemantics.Ast /-! # YulParser.Atoms Atomic parsers producing `yul-semantics` values (`Literal`, identifiers as `String`), plus keyword and punctuation tokens. Each atom prints its token followed by a delimiting space (so the printed form is `Closed`), and is proven `SoundC`. -/ name...
@@ -99,6 +99,17 @@ Bool.false_eq_true, if_false, List.append_nil] rw [canon_ws (by decide : isWs ' ' = true), canon_nil] +/-- `canon` of an identifier token followed by a boundary (non-`idCont`) continuation. -/ +theorem canon_ident_boundary {c : Char} {ts rest : List Char} (hc : isIdStart c = true) + (hts...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_af542b3ca6e9_12
dc38f280a94fcc32
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulParser/Atoms.lean
Atoms
12
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
22
1
[ { "theorem_name": "keywordC", "depth": 1, "n_commands": 0, "n_lines": 21, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n intro cs a rest h\n simp only [keyword, token, pmap, YulParser.andThen] at h\n cases hp : pstr (c :: ts) (YulParser.skipTrivia ...
[ { "name": "canon_ident_space", "text": "/-- `canon` of an identifier token followed by a space is a single `ident`. -/\ntheorem canon_ident_space {c : Char} {ts : List Char} (hc : isIdStart c = true)\n (hts : ∀ x ∈ ts, isIdCont x = true) : canon ((c :: ts) ++ [' ']) = [CTok.ident (c :: ts)] := by\n have...
[ { "name": "pLit_soundC", "fan_in": 0, "n_deps_direct": 3, "n_deps_transitive": 21, "n_lines": 4, "n_chars": 105, "n_subproofs": 0, "n_tactics": 1, "cyclomatic": 1, "n_automation": 0, "n_rewrites": 0, "n_structural": 0, "automation_only": false, "max_nesting": ...
21
import YulParser.SoundC import YulSemantics.Ast /-! # YulParser.Atoms Atomic parsers producing `yul-semantics` values (`Literal`, identifiers as `String`), plus keyword and punctuation tokens. Each atom prints its token followed by a delimiting space (so the printed form is `Closed`), and is proven `SoundC`. -/ name...
import YulParser.SoundC import YulSemantics.Ast /-! # YulParser.Atoms Atomic parsers producing `yul-semantics` values (`Literal`, identifiers as `String`), plus keyword and punctuation tokens. Each atom prints its token followed by a delimiting space (so the printed form is `Closed`), and is proven `SoundC`. -/ name...
@@ -175,6 +175,16 @@ · rw [List.takeWhile_cons, hcont]; rfl · rw [List.dropWhile_cons, hcont]; rfl +/-- `canon` of an identifier token followed by a space is a single `ident`. -/ +theorem canon_ident_space {c : Char} {ts : List Char} (hc : isIdStart c = true) + (hts : ∀ x ∈ ts, isIdCont x = true) : c...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_2e96266555e4_0
c7f1cd2ddd361c56
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulParser/Canon.lean
Canon
0
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
16
2
[ { "theorem_name": "canon_pQuotedChars", "depth": 1, "n_commands": 0, "n_lines": 10, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n cases input with\n | nil => simp [pQuotedChars] at h\n | cons c input =>\n simp only [pQuotedChars] at h\n ...
[ { "name": "canon_str", "text": "theorem canon_str {input body rest : List Char}\n (h : pQuotedChars ('\"' :: input) = some (body, rest)) :\n canon ('\"' :: input) = CTok.str body :: canon rest := by\n have hs : scanQuoted ('\"' :: input) =\n some ⟨body, rest, pQuotedChars_rest_lt h⟩ := by\n u...
[ { "name": "canon_pQuotedChars", "fan_in": 0, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 14, "n_chars": 388, "n_subproofs": 0, "n_tactics": 10, "cyclomatic": 3, "n_automation": 2, "n_rewrites": 1, "n_structural": 2, "automation_only": false, "max_ne...
1
import Mathlib import YulParser.Lexer /-! # YulParser.Canon An **independent** syntactic canonical form for Yul source, defined with no reference to the parser: a total maximal-munch lexer `canon : List Char → List CTok` that * drops all whitespace and C++-style comments (`//…` line, `/* … */` block), and * evaluate...
import Mathlib import YulParser.Lexer /-! # YulParser.Canon An **independent** syntactic canonical form for Yul source, defined with no reference to the parser: a total maximal-munch lexer `canon : List Char → List CTok` that * drops all whitespace and C++-style comments (`//…` line, `/* … */` block), and * evaluate...
@@ -111,6 +111,22 @@ /-! ### One-step equations (reusable unfoldings) -/ +theorem canon_str {input body rest : List Char} + (h : pQuotedChars ('"' :: input) = some (body, rest)) : + canon ('"' :: input) = CTok.str body :: canon rest := by + have hs : scanQuoted ('"' :: input) = + some ⟨body, rest, pQuo...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_2e96266555e4_1
0629f9e5f0739430
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulParser/Canon.lean
Canon
1
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
16
5
[ { "theorem_name": "canon_skipTrivia", "depth": 1, "n_commands": 0, "n_lines": 5, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n fun_induction skipTrivia cs <;> simp_all\n · exact (canon_ws (by assumption)).symm\n · exact canon_line_comment.symm\n ...
[ { "name": "canon_ws", "text": "theorem canon_ws {c : Char} {rest : List Char} (h : isWs c = true) :\n canon (c :: rest) = canon rest := by rw [canon.eq_def]; simp [h]\n\n", "fan_in": 5, "n_lines": 4, "n_chars": 139, "n_subproofs": 0, "n_tactics": 2, "cyclomatic": 1, "n_automat...
[ { "name": "canon_skipTrivia", "fan_in": 1, "n_deps_direct": 3, "n_deps_transitive": 3, "n_lines": 9, "n_chars": 353, "n_subproofs": 0, "n_tactics": 6, "cyclomatic": 2, "n_automation": 2, "n_rewrites": 0, "n_structural": 3, "automation_only": false, "max_nestin...
3
import Mathlib import YulParser.Lexer /-! # YulParser.Canon An **independent** syntactic canonical form for Yul source, defined with no reference to the parser: a total maximal-munch lexer `canon : List Char → List CTok` that * drops all whitespace and C++-style comments (`//…` line, `/* … */` block), and * evaluate...
import Mathlib import YulParser.Lexer /-! # YulParser.Canon An **independent** syntactic canonical form for Yul source, defined with no reference to the parser: a total maximal-munch lexer `canon : List Char → List CTok` that * drops all whitespace and C++-style comments (`//…` line, `/* … */` block), and * evaluate...
@@ -111,6 +111,9 @@ /-! ### One-step equations (reusable unfoldings) -/ +theorem canon_ws {c : Char} {rest : List Char} (h : isWs c = true) : + canon (c :: rest) = canon rest := by rw [canon.eq_def]; simp [h] + /-- `//` line comment: skip to end of line. -/ theorem canon_line_comment {r : List Char} : ca...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_2e96266555e4_2
f536e2b4f795bb36
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulParser/Canon.lean
Canon
2
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
16
5
[ { "theorem_name": "canon_skipTrivia", "depth": 1, "n_commands": 0, "n_lines": 5, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n fun_induction skipTrivia cs <;> simp_all\n · exact (canon_ws (by assumption)).symm\n · exact canon_line_comment.symm\n ...
[ { "name": "canon_ws", "text": "theorem canon_ws {c : Char} {rest : List Char} (h : isWs c = true) :\n canon (c :: rest) = canon rest := by rw [canon.eq_def]; simp [h]\n\n", "fan_in": 5, "n_lines": 4, "n_chars": 139, "n_subproofs": 0, "n_tactics": 2, "cyclomatic": 1, "n_automat...
[ { "name": "canon_eq_nil_of_skipTrivia_eq_nil", "fan_in": 0, "n_deps_direct": 2, "n_deps_transitive": 5, "n_lines": 8, "n_chars": 300, "n_subproofs": 0, "n_tactics": 2, "cyclomatic": 1, "n_automation": 0, "n_rewrites": 1, "n_structural": 0, "automation_only": false...
4
import Mathlib import YulParser.Lexer /-! # YulParser.Canon An **independent** syntactic canonical form for Yul source, defined with no reference to the parser: a total maximal-munch lexer `canon : List Char → List CTok` that * drops all whitespace and C++-style comments (`//…` line, `/* … */` block), and * evaluate...
import Mathlib import YulParser.Lexer /-! # YulParser.Canon An **independent** syntactic canonical form for Yul source, defined with no reference to the parser: a total maximal-munch lexer `canon : List Char → List CTok` that * drops all whitespace and C++-style comments (`//…` line, `/* … */` block), and * evaluate...
@@ -111,6 +111,9 @@ /-! ### One-step equations (reusable unfoldings) -/ +theorem canon_ws {c : Char} {rest : List Char} (h : isWs c = true) : + canon (c :: rest) = canon rest := by rw [canon.eq_def]; simp [h] + /-- `//` line comment: skip to end of line. -/ theorem canon_line_comment {r : List Char} : ca...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_2e96266555e4_3
4a369dfa70167b12
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulParser/Canon.lean
Canon
3
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
16
5
[ { "theorem_name": "canon_skipTrivia", "depth": 1, "n_commands": 0, "n_lines": 5, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n fun_induction skipTrivia cs <;> simp_all\n · exact (canon_ws (by assumption)).symm\n · exact canon_line_comment.symm\n ...
[ { "name": "canon_ws", "text": "theorem canon_ws {c : Char} {rest : List Char} (h : isWs c = true) :\n canon (c :: rest) = canon rest := by rw [canon.eq_def]; simp [h]\n\n", "fan_in": 5, "n_lines": 4, "n_chars": 139, "n_subproofs": 0, "n_tactics": 2, "cyclomatic": 1, "n_automat...
[ { "name": "closed_ws", "fan_in": 0, "n_deps_direct": 2, "n_deps_transitive": 2, "n_lines": 5, "n_chars": 188, "n_subproofs": 0, "n_tactics": 3, "cyclomatic": 1, "n_automation": 0, "n_rewrites": 1, "n_structural": 1, "automation_only": false, "max_nesting": 2 ...
1
import Mathlib import YulParser.Lexer /-! # YulParser.Canon An **independent** syntactic canonical form for Yul source, defined with no reference to the parser: a total maximal-munch lexer `canon : List Char → List CTok` that * drops all whitespace and C++-style comments (`//…` line, `/* … */` block), and * evaluate...
import Mathlib import YulParser.Lexer /-! # YulParser.Canon An **independent** syntactic canonical form for Yul source, defined with no reference to the parser: a total maximal-munch lexer `canon : List Char → List CTok` that * drops all whitespace and C++-style comments (`//…` line, `/* … */` block), and * evaluate...
@@ -111,13 +111,17 @@ /-! ### One-step equations (reusable unfoldings) -/ +theorem canon_ws {c : Char} {rest : List Char} (h : isWs c = true) : + canon (c :: rest) = canon rest := by rw [canon.eq_def]; simp [h] + /-- `x` is *closed* when `canon` splits cleanly at the end of `x`: nothing following `x` can merge...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_2e96266555e4_4
b7c2be8713158eea
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulParser/Canon.lean
Canon
4
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
16
1
[ { "theorem_name": "closed_punct", "depth": 1, "n_commands": 0, "n_lines": 5, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n intro y\n rw [List.singleton_append, canon_punct hw hq hi hd hc hs, canon_punct hw hq hi hd hc hs,\n canon_nil]\n simp", ...
[ { "name": "canon_punct", "text": "theorem canon_punct {c : Char} {rest : List Char}\n (hw : isWs c = false) (hq : (c == '\"') = false) (hi : isIdStart c = false)\n (hd : isDigitC c = false) (hc : (c == ':') = false) (hs : (c == '/') = false) :\n canon (c :: rest) = CTok.punct [c] :: canon rest := b...
[ { "name": "closed_punct", "fan_in": 0, "n_deps_direct": 2, "n_deps_transitive": 2, "n_lines": 10, "n_chars": 403, "n_subproofs": 0, "n_tactics": 5, "cyclomatic": 1, "n_automation": 1, "n_rewrites": 1, "n_structural": 1, "automation_only": false, "max_nesting":...
1
import Mathlib import YulParser.Lexer /-! # YulParser.Canon An **independent** syntactic canonical form for Yul source, defined with no reference to the parser: a total maximal-munch lexer `canon : List Char → List CTok` that * drops all whitespace and C++-style comments (`//…` line, `/* … */` block), and * evaluate...
import Mathlib import YulParser.Lexer /-! # YulParser.Canon An **independent** syntactic canonical form for Yul source, defined with no reference to the parser: a total maximal-munch lexer `canon : List Char → List CTok` that * drops all whitespace and C++-style comments (`//…` line, `/* … */` block), and * evaluate...
@@ -111,6 +111,12 @@ /-! ### One-step equations (reusable unfoldings) -/ +theorem canon_punct {c : Char} {rest : List Char} + (hw : isWs c = false) (hq : (c == '"') = false) (hi : isIdStart c = false) + (hd : isDigitC c = false) (hc : (c == ':') = false) (hs : (c == '/') = false) : + canon (c :: rest) = C...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_2e96266555e4_5
581079bc44a8f897
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulParser/Canon.lean
Canon
5
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
16
1
[ { "theorem_name": "closed_assign", "depth": 1, "n_commands": 0, "n_lines": 6, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n intro y\n have : ([':', '='] ++ y) = ':' :: '=' :: y := rfl\n rw [this, canon_assign]\n show CTok.punct [':', '='] :: cano...
[ { "name": "canon_assign", "text": "theorem canon_assign {r : List Char} :\n canon (':' :: '=' :: r) = CTok.punct [':', '='] :: canon r := by\n rw [canon.eq_def]; simp [isWs, isIdStart, isDigitC]\n\n", "fan_in": 1, "n_lines": 5, "n_chars": 163, "n_subproofs": 0, "n_tactics": 3, "c...
[ { "name": "closed_assign", "fan_in": 0, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 9, "n_chars": 336, "n_subproofs": 1, "n_tactics": 7, "cyclomatic": 1, "n_automation": 3, "n_rewrites": 4, "n_structural": 1, "automation_only": false, "max_nesting":...
1
import Mathlib import YulParser.Lexer /-! # YulParser.Canon An **independent** syntactic canonical form for Yul source, defined with no reference to the parser: a total maximal-munch lexer `canon : List Char → List CTok` that * drops all whitespace and C++-style comments (`//…` line, `/* … */` block), and * evaluate...
import Mathlib import YulParser.Lexer /-! # YulParser.Canon An **independent** syntactic canonical form for Yul source, defined with no reference to the parser: a total maximal-munch lexer `canon : List Char → List CTok` that * drops all whitespace and C++-style comments (`//…` line, `/* … */` block), and * evaluate...
@@ -111,13 +111,22 @@ /-! ### One-step equations (reusable unfoldings) -/ +theorem canon_assign {r : List Char} : + canon (':' :: '=' :: r) = CTok.punct [':', '='] :: canon r := by + rw [canon.eq_def]; simp [isWs, isIdStart, isDigitC] + /-- `x` is *closed* when `canon` splits cleanly at the end of `x`: nothin...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_2e96266555e4_6
c544a1df9e973c49
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulParser/Canon.lean
Canon
6
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
16
5
[ { "theorem_name": "canon_skipTrivia", "depth": 1, "n_commands": 0, "n_lines": 5, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n fun_induction skipTrivia cs <;> simp_all\n · exact (canon_ws (by assumption)).symm\n · exact canon_line_comment.symm\n ...
[ { "name": "canon_ws", "text": "theorem canon_ws {c : Char} {rest : List Char} (h : isWs c = true) :\n canon (c :: rest) = canon rest := by rw [canon.eq_def]; simp [h]\n\n", "fan_in": 5, "n_lines": 4, "n_chars": 139, "n_subproofs": 0, "n_tactics": 2, "cyclomatic": 1, "n_automat...
[ { "name": "closed_ident", "fan_in": 0, "n_deps_direct": 7, "n_deps_transitive": 7, "n_lines": 17, "n_chars": 862, "n_subproofs": 4, "n_tactics": 14, "cyclomatic": 1, "n_automation": 6, "n_rewrites": 3, "n_structural": 2, "automation_only": false, "max_nesting"...
6
import Mathlib import YulParser.Lexer /-! # YulParser.Canon An **independent** syntactic canonical form for Yul source, defined with no reference to the parser: a total maximal-munch lexer `canon : List Char → List CTok` that * drops all whitespace and C++-style comments (`//…` line, `/* … */` block), and * evaluate...
import Mathlib import YulParser.Lexer /-! # YulParser.Canon An **independent** syntactic canonical form for Yul source, defined with no reference to the parser: a total maximal-munch lexer `canon : List Char → List CTok` that * drops all whitespace and C++-style comments (`//…` line, `/* … */` block), and * evaluate...
@@ -111,6 +111,9 @@ /-! ### One-step equations (reusable unfoldings) -/ +theorem canon_ws {c : Char} {rest : List Char} (h : isWs c = true) : + canon (c :: rest) = canon rest := by rw [canon.eq_def]; simp [h] + theorem canon_ident {c : Char} {rest : List Char} (hw : isWs c = false) (hq : (c == '"') = fals...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_2e96266555e4_7
bbbf058ddd203792
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulParser/Canon.lean
Canon
7
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
16
1
[ { "theorem_name": "closed_num", "depth": 1, "n_commands": 0, "n_lines": 14, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n have hnsp : isNumCont ' ' = false := by decide\n have key : ∀ y, canon (c :: (ns ++ ' ' :: y))\n = CTok.num (numVal (c ::...
[ { "name": "canon_num", "text": "theorem canon_num {c : Char} {rest : List Char}\n (hw : isWs c = false) (hq : (c == '\"') = false) (hi : isIdStart c = false)\n (hd : isDigitC c = true) :\n canon (c :: rest)\n = CTok.num (numVal (c :: rest.takeWhile isNumCont)) :: canon (rest.dropWhile isNumCon...
[ { "name": "closed_num", "fan_in": 0, "n_deps_direct": 8, "n_deps_transitive": 8, "n_lines": 18, "n_chars": 888, "n_subproofs": 4, "n_tactics": 15, "cyclomatic": 1, "n_automation": 6, "n_rewrites": 3, "n_structural": 2, "automation_only": false, "max_nesting": ...
7
import Mathlib import YulParser.Lexer /-! # YulParser.Canon An **independent** syntactic canonical form for Yul source, defined with no reference to the parser: a total maximal-munch lexer `canon : List Char → List CTok` that * drops all whitespace and C++-style comments (`//…` line, `/* … */` block), and * evaluate...
import Mathlib import YulParser.Lexer /-! # YulParser.Canon An **independent** syntactic canonical form for Yul source, defined with no reference to the parser: a total maximal-munch lexer `canon : List Char → List CTok` that * drops all whitespace and C++-style comments (`//…` line, `/* … */` block), and * evaluate...
@@ -114,6 +114,13 @@ theorem canon_ws {c : Char} {rest : List Char} (h : isWs c = true) : canon (c :: rest) = canon rest := by rw [canon.eq_def]; simp [h] +theorem canon_num {c : Char} {rest : List Char} + (hw : isWs c = false) (hq : (c == '"') = false) (hi : isIdStart c = false) + (hd : isDigitC c = true...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_2e96266555e4_8
ac98cd4a517f350c
lean
lean
github.com/powdr-labs/yul-compiler
37ead3d1abddd98ef5c69ef434de8bbe6bb868af
YulParser/Canon.lean
Canon
8
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
16
5
[ { "theorem_name": "canon_skipTrivia", "depth": 1, "n_commands": 0, "n_lines": 5, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n fun_induction skipTrivia cs <;> simp_all\n · exact (canon_ws (by assumption)).symm\n · exact canon_line_comment.symm\n ...
[ { "name": "canon_ws", "text": "theorem canon_ws {c : Char} {rest : List Char} (h : isWs c = true) :\n canon (c :: rest) = canon rest := by rw [canon.eq_def]; simp [h]\n\n", "fan_in": 5, "n_lines": 4, "n_chars": 139, "n_subproofs": 0, "n_tactics": 2, "cyclomatic": 1, "n_automat...
[ { "name": "closed_str", "fan_in": 0, "n_deps_direct": 3, "n_deps_transitive": 3, "n_lines": 15, "n_chars": 751, "n_subproofs": 3, "n_tactics": 12, "cyclomatic": 1, "n_automation": 4, "n_rewrites": 4, "n_structural": 3, "automation_only": false, "max_nesting": ...
2
import Mathlib import YulParser.Lexer /-! # YulParser.Canon An **independent** syntactic canonical form for Yul source, defined with no reference to the parser: a total maximal-munch lexer `canon : List Char → List CTok` that * drops all whitespace and C++-style comments (`//…` line, `/* … */` block), and * evaluate...
import Mathlib import YulParser.Lexer /-! # YulParser.Canon An **independent** syntactic canonical form for Yul source, defined with no reference to the parser: a total maximal-munch lexer `canon : List Char → List CTok` that * drops all whitespace and C++-style comments (`//…` line, `/* … */` block), and * evaluate...
@@ -111,6 +111,9 @@ /-! ### One-step equations (reusable unfoldings) -/ +theorem canon_ws {c : Char} {rest : List Char} (h : isWs c = true) : + canon (c :: rest) = canon rest := by rw [canon.eq_def]; simp [h] + theorem canon_str {input body rest : List Char} (h : pQuotedChars ('"' :: input) = some (body, ...
{ "repo": "yul-compiler", "git_repo": "github.com/powdr-labs/yul-compiler", "revision": "37ead3d1abddd98ef5c69ef434de8bbe6bb868af", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollary-...
ablate_834a6157154a_0
45196902a598ac87
lean
lean
github.com/powdr-labs/yul-semantics
f4e6187d684c0ebaee751750c5c368a4226abb73
YulSemantics/FibExample.lean
FibExample
0
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
7
1
[ { "theorem_name": "fibLoop", "depth": 1, "n_commands": 0, "n_lines": 33, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n intro k\n induction k with\n | zero =>\n intro I hI\n have hInv : I = nv.toNat := by omega\n subst hInv\n refine Ste...
[ { "name": "fib_body", "text": "/-- Executing the body block sends `a ↦ b`, `b ↦ a + b` (and drops the block-local `t`); the state\nis untouched (the body is pure). -/\ntheorem fib_body (funs : FunEnv evm) (st : EvmState) (iv av bv nv : U256) :\n ExecStmt evm funs [(\"i\", iv), (\"b\", bv), (\"a\", av), (...
[ { "name": "fibLoop", "fan_in": 1, "n_deps_direct": 5, "n_deps_transitive": 5, "n_lines": 46, "n_chars": 2261, "n_subproofs": 6, "n_tactics": 35, "cyclomatic": 2, "n_automation": 13, "n_rewrites": 7, "n_structural": 7, "automation_only": false, "max_nesting": 1...
5
import YulSemantics.Interp import YulSemantics.Syntax import YulSemantics.BigStep /-! # YulSemantics.FibExample An example Yul contract that reads a number `n` from calldata, computes the `n`-th Fibonacci number (mod `2^256`), writes it to memory, and returns it — together with proofs of its semantics: * **concrete*...
import YulSemantics.Interp import YulSemantics.Syntax import YulSemantics.BigStep /-! # YulSemantics.FibExample An example Yul contract that reads a number `n` from calldata, computes the `n`-th Fibonacci number (mod `2^256`), writes it to memory, and returns it — together with proofs of its semantics: * **concrete*...
@@ -72,6 +72,20 @@ .assign ["a"] (.var "b"), .assign ["b"] (.var "t") ] +/-- Executing the body block sends `a ↦ b`, `b ↦ a + b` (and drops the block-local `t`); the state +is untouched (the body is pure). -/ +theorem fib_body (funs : FunEnv evm) (st : EvmState) (iv av bv nv : U256) : + ExecStmt evm funs...
{ "repo": "yul-semantics", "git_repo": "github.com/powdr-labs/yul-semantics", "revision": "f4e6187d684c0ebaee751750c5c368a4226abb73", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollar...
ablate_834a6157154a_1
952107436a12b71c
lean
lean
github.com/powdr-labs/yul-semantics
f4e6187d684c0ebaee751750c5c368a4226abb73
YulSemantics/FibExample.lean
FibExample
1
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
7
1
[ { "theorem_name": "fibLoop", "depth": 1, "n_commands": 0, "n_lines": 33, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n intro k\n induction k with\n | zero =>\n intro I hI\n have hInv : I = nv.toNat := by omega\n subst hInv\n refine Ste...
[ { "name": "fib_body", "text": "/-- Executing the body block sends `a ↦ b`, `b ↦ a + b` (and drops the block-local `t`); the state\nis untouched (the body is pure). -/\ntheorem fib_body (funs : FunEnv evm) (st : EvmState) (iv av bv nv : U256) :\n ExecStmt evm funs [(\"i\", iv), (\"b\", bv), (\"a\", av), (...
[ { "name": "fibContract_correct", "fan_in": 0, "n_deps_direct": 2, "n_deps_transitive": 7, "n_lines": 39, "n_chars": 2172, "n_subproofs": 1, "n_tactics": 23, "cyclomatic": 1, "n_automation": 11, "n_rewrites": 0, "n_structural": 7, "automation_only": false, "max...
7
import YulSemantics.Interp import YulSemantics.Syntax import YulSemantics.BigStep /-! # YulSemantics.FibExample An example Yul contract that reads a number `n` from calldata, computes the `n`-th Fibonacci number (mod `2^256`), writes it to memory, and returns it — together with proofs of its semantics: * **concrete*...
import YulSemantics.Interp import YulSemantics.Syntax import YulSemantics.BigStep /-! # YulSemantics.FibExample An example Yul contract that reads a number `n` from calldata, computes the `n`-th Fibonacci number (mod `2^256`), writes it to memory, and returns it — together with proofs of its semantics: * **concrete*...
@@ -72,6 +72,20 @@ .assign ["a"] (.var "b"), .assign ["b"] (.var "t") ] +/-- Executing the body block sends `a ↦ b`, `b ↦ a + b` (and drops the block-local `t`); the state +is untouched (the body is pure). -/ +theorem fib_body (funs : FunEnv evm) (st : EvmState) (iv av bv nv : U256) : + ExecStmt evm funs...
{ "repo": "yul-semantics", "git_repo": "github.com/powdr-labs/yul-semantics", "revision": "f4e6187d684c0ebaee751750c5c368a4226abb73", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollar...
ablate_2cbea4068d4e_0
fcf6540a6bc24268
lean
lean
github.com/powdr-labs/yul-semantics
f4e6187d684c0ebaee751750c5c368a4226abb73
YulSemantics/Adequacy.lean
Adequacy
0
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
3
2
[ { "theorem_name": "run_sound", "depth": 1, "n_commands": 0, "n_lines": 2, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": "\n (sound_all hE n).2.2.1 _ _ _ _ _ _ _ h", "n_chars": 41, "n_subproofs": 0, "n_tactics": 1, "cyclomatic": 1, "n_au...
[ { "name": "sound_all", "text": "/-- Soundness of the interpreter, jointly for the five syntactic classes, by induction on fuel:\nwhenever the interpreter answers `.ok`, the big-step judgment holds. -/\ntheorem sound_all (hE : E.Lawful) : ∀ n : Nat,\n (∀ funs V st e r, evalExpr E n funs V st e = .ok r →\n...
[ { "name": "run_sound", "fan_in": 1, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 7, "n_chars": 291, "n_subproofs": 0, "n_tactics": 1, "cyclomatic": 1, "n_automation": 0, "n_rewrites": 0, "n_structural": 0, "automation_only": false, "max_nesting": 2 ...
1
import YulSemantics.BigStep import YulSemantics.Interp import YulSemantics.Dialect.EVM /-! # YulSemantics.Adequacy The fuel-indexed interpreter (`YulSemantics.Interp`) is **adequate** for the big-step relational semantics (`YulSemantics.BigStep`), under the hypothesis that the executable dialect is `Lawful` (its `bui...
import YulSemantics.BigStep import YulSemantics.Interp import YulSemantics.Dialect.EVM /-! # YulSemantics.Adequacy The fuel-indexed interpreter (`YulSemantics.Interp`) is **adequate** for the big-step relational semantics (`YulSemantics.BigStep`), under the hypothesis that the executable dialect is `Lawful` (its `bui...
@@ -28,10 +28,431 @@ variable {E : ExecDialect} [DecidableEq E.toDialect.Value] +/-- Soundness of the interpreter, jointly for the five syntactic classes, by induction on fuel: +whenever the interpreter answers `.ok`, the big-step judgment holds. -/ +theorem sound_all (hE : E.Lawful) : ∀ n : Nat, + (∀ funs V st...
{ "repo": "yul-semantics", "git_repo": "github.com/powdr-labs/yul-semantics", "revision": "f4e6187d684c0ebaee751750c5c368a4226abb73", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollar...
ablate_2cbea4068d4e_1
5b9a5126d4ae22a5
lean
lean
github.com/powdr-labs/yul-semantics
f4e6187d684c0ebaee751750c5c368a4226abb73
YulSemantics/Adequacy.lean
Adequacy
1
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
3
2
[ { "theorem_name": "adequacy", "depth": 1, "n_commands": 0, "n_lines": 28, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n constructor\n · intro h\n obtain ⟨N, hN⟩ := complete hE h\n exact ⟨N, hN N le_rfl⟩\n · rintro ⟨n, h⟩\n have S := sound...
[ { "name": "complete", "text": "/-- Completeness of the interpreter: a big-step derivation is reproduced by the interpreter at\nevery sufficiently large fuel. By rule induction on the derivation; the \"for all `n ≥ N`\" form\nembeds fuel monotonicity, so no separate monotonicity lemma is needed. -/\ntheorem ...
[ { "name": "adequacy", "fan_in": 0, "n_deps_direct": 2, "n_deps_transitive": 2, "n_lines": 32, "n_chars": 1100, "n_subproofs": 2, "n_tactics": 28, "cyclomatic": 9, "n_automation": 5, "n_rewrites": 0, "n_structural": 16, "automation_only": false, "max_nesting": ...
2
import YulSemantics.BigStep import YulSemantics.Interp import YulSemantics.Dialect.EVM /-! # YulSemantics.Adequacy The fuel-indexed interpreter (`YulSemantics.Interp`) is **adequate** for the big-step relational semantics (`YulSemantics.BigStep`), under the hypothesis that the executable dialect is `Lawful` (its `bui...
import YulSemantics.BigStep import YulSemantics.Interp import YulSemantics.Dialect.EVM /-! # YulSemantics.Adequacy The fuel-indexed interpreter (`YulSemantics.Interp`) is **adequate** for the big-step relational semantics (`YulSemantics.BigStep`), under the hypothesis that the executable dialect is `Lawful` (its `bui...
@@ -461,11 +461,282 @@ | .loop c post body, .sres V' st' o => execLoop E n funs V st c post body = .ok (V', st', o) | _, _ => False +/-- Completeness of the interpreter: a big-step derivation is reproduced by the interpreter at +every sufficiently large fuel. By rule induction on the derivation; the "for all `n...
{ "repo": "yul-semantics", "git_repo": "github.com/powdr-labs/yul-semantics", "revision": "f4e6187d684c0ebaee751750c5c368a4226abb73", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollar...
ablate_2cbea4068d4e_2
492547f0bf8613fc
lean
lean
github.com/powdr-labs/yul-semantics
f4e6187d684c0ebaee751750c5c368a4226abb73
YulSemantics/Adequacy.lean
Adequacy
2
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
3
2
[ { "theorem_name": "adequacy", "depth": 1, "n_commands": 0, "n_lines": 28, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n constructor\n · intro h\n obtain ⟨N, hN⟩ := complete hE h\n exact ⟨N, hN N le_rfl⟩\n · rintro ⟨n, h⟩\n have S := sound...
[ { "name": "complete", "text": "/-- Completeness of the interpreter: a big-step derivation is reproduced by the interpreter at\nevery sufficiently large fuel. By rule induction on the derivation; the \"for all `n ≥ N`\" form\nembeds fuel monotonicity, so no separate monotonicity lemma is needed. -/\ntheorem ...
[ { "name": "run_adequacy", "fan_in": 1, "n_deps_direct": 2, "n_deps_transitive": 3, "n_lines": 14, "n_chars": 479, "n_subproofs": 2, "n_tactics": 8, "cyclomatic": 3, "n_automation": 1, "n_rewrites": 0, "n_structural": 6, "automation_only": false, "max_nesting":...
3
import YulSemantics.BigStep import YulSemantics.Interp import YulSemantics.Dialect.EVM /-! # YulSemantics.Adequacy The fuel-indexed interpreter (`YulSemantics.Interp`) is **adequate** for the big-step relational semantics (`YulSemantics.BigStep`), under the hypothesis that the executable dialect is `Lawful` (its `bui...
import YulSemantics.BigStep import YulSemantics.Interp import YulSemantics.Dialect.EVM /-! # YulSemantics.Adequacy The fuel-indexed interpreter (`YulSemantics.Interp`) is **adequate** for the big-step relational semantics (`YulSemantics.BigStep`), under the hypothesis that the executable dialect is `Lawful` (its `bui...
@@ -467,13 +467,285 @@ | .loop c post body, .sres V' st' o => execLoop E n funs V st c post body = .ok (V', st', o) | _, _ => False +/-- Completeness of the interpreter: a big-step derivation is reproduced by the interpreter at +every sufficiently large fuel. By rule induction on the derivation; the "for all `n...
{ "repo": "yul-semantics", "git_repo": "github.com/powdr-labs/yul-semantics", "revision": "f4e6187d684c0ebaee751750c5c368a4226abb73", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollar...
ablate_274d37e02594_0
003d0dd1b2f2ee42
lean
lean
github.com/powdr-labs/yul-semantics
f4e6187d684c0ebaee751750c5c368a4226abb73
YulSemantics/Equiv.lean
Equiv
0
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
16
2
[ { "theorem_name": "EquivArgs.of_forall₂", "depth": 1, "n_commands": 0, "n_lines": 5, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": "\n fun _ _ _ _ =>\n ⟨argsImp (h.imp fun _ _ he funs V st r => (he funs V st r).mp) _ _ _ _,\n argsImp ((forall₂_symm ...
[ { "name": "forall₂_symm", "text": "private theorem forall₂_symm {α : Type _} {R : α → α → Prop} {l₁ l₂ : List α}\n (hsym : ∀ {a b}, R a b → R b a) (h : List.Forall₂ R l₁ l₂) : List.Forall₂ R l₂ l₁ := by\n induction h with\n | nil => exact .nil\n | cons hh _ ih => exact .cons (hsym hh) ih\n\n", "fa...
[ { "name": "EquivArgs.of_forall₂", "fan_in": 1, "n_deps_direct": 2, "n_deps_transitive": 2, "n_lines": 11, "n_chars": 456, "n_subproofs": 0, "n_tactics": 4, "cyclomatic": 1, "n_automation": 0, "n_rewrites": 0, "n_structural": 0, "automation_only": false, "max_n...
2
import Mathlib.Data.List.Forall2 import YulSemantics.BigStep /-! # YulSemantics.Equiv Phase 5 foundations: **semantic equivalence** and its **congruence** properties — the layer Yul→Yul optimization-pass correctness proofs stand on (see `DESIGN.md`). ## Equivalences `EquivExpr`/`EquivArgs`/`EquivStmt`/`EquivStmts`/...
import Mathlib.Data.List.Forall2 import YulSemantics.BigStep /-! # YulSemantics.Equiv Phase 5 foundations: **semantic equivalence** and its **congruence** properties — the layer Yul→Yul optimization-pass correctness proofs stand on (see `DESIGN.md`). ## Equivalences `EquivExpr`/`EquivArgs`/`EquivStmt`/`EquivStmts`/...
@@ -116,9 +116,19 @@ | argsRestHalt ha => exact Step.argsRestHalt (ih _ _ _ _ ha) | argsHeadHalt ha hh => exact Step.argsHeadHalt (ih _ _ _ _ ha) (he _ _ _ _ hh) +private theorem forall₂_symm {α : Type _} {R : α → α → Prop} {l₁ l₂ : List α} + (hsym : ∀ {a b}, R a b → R b a) (h : List.Forall₂ R l₁ l₂)...
{ "repo": "yul-semantics", "git_repo": "github.com/powdr-labs/yul-semantics", "revision": "f4e6187d684c0ebaee751750c5c368a4226abb73", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollar...
ablate_274d37e02594_1
08b3c8b91bab5b7a
lean
lean
github.com/powdr-labs/yul-semantics
f4e6187d684c0ebaee751750c5c368a4226abb73
YulSemantics/Equiv.lean
Equiv
1
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
16
1
[ { "theorem_name": "EquivExpr.builtin_congr", "depth": 1, "n_commands": 0, "n_lines": 2, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": "\n fun _ _ _ _ => ⟨builtinImp h, builtinImp h.symm⟩", "n_chars": 55, "n_subproofs": 0, "n_tactics": 1, "c...
[ { "name": "builtinImp", "text": "private theorem builtinImp {op : D.Op} {es₁ es₂} (ha : EquivArgs D es₁ es₂) {funs V st r}\n (h : EvalExpr D funs V st (.builtin op es₁) r) : EvalExpr D funs V st (.builtin op es₂) r := by\n cases h with\n | builtinOk h₁ h₂ => exact Step.builtinOk (ha.mp h₁) h₂\n | buil...
[ { "name": "EquivExpr.builtin_congr", "fan_in": 0, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 6, "n_chars": 267, "n_subproofs": 0, "n_tactics": 1, "cyclomatic": 1, "n_automation": 0, "n_rewrites": 0, "n_structural": 0, "automation_only": false, "max...
1
import Mathlib.Data.List.Forall2 import YulSemantics.BigStep /-! # YulSemantics.Equiv Phase 5 foundations: **semantic equivalence** and its **congruence** properties — the layer Yul→Yul optimization-pass correctness proofs stand on (see `DESIGN.md`). ## Equivalences `EquivExpr`/`EquivArgs`/`EquivStmt`/`EquivStmts`/...
import Mathlib.Data.List.Forall2 import YulSemantics.BigStep /-! # YulSemantics.Equiv Phase 5 foundations: **semantic equivalence** and its **congruence** properties — the layer Yul→Yul optimization-pass correctness proofs stand on (see `DESIGN.md`). ## Equivalences `EquivExpr`/`EquivArgs`/`EquivStmt`/`EquivStmts`/...
@@ -98,9 +98,17 @@ /-! ### Behavior: whole-program runs -/ +private theorem builtinImp {op : D.Op} {es₁ es₂} (ha : EquivArgs D es₁ es₂) {funs V st r} + (h : EvalExpr D funs V st (.builtin op es₁) r) : EvalExpr D funs V st (.builtin op es₂) r := by + cases h with + | builtinOk h₁ h₂ => exact Step.builtinOk (ha...
{ "repo": "yul-semantics", "git_repo": "github.com/powdr-labs/yul-semantics", "revision": "f4e6187d684c0ebaee751750c5c368a4226abb73", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollar...
ablate_274d37e02594_2
98b0415a79b7ff09
lean
lean
github.com/powdr-labs/yul-semantics
f4e6187d684c0ebaee751750c5c368a4226abb73
YulSemantics/Equiv.lean
Equiv
2
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
16
1
[ { "theorem_name": "EquivExpr.call_congr", "depth": 1, "n_commands": 0, "n_lines": 2, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": "\n fun _ _ _ _ => ⟨callImp h, callImp h.symm⟩", "n_chars": 49, "n_subproofs": 0, "n_tactics": 1, "cyclomatic...
[ { "name": "callImp", "text": "private theorem callImp {fn : Ident} {es₁ es₂} (ha : EquivArgs D es₁ es₂) {funs V st r}\n (h : EvalExpr D funs V st (.call fn es₁) r) : EvalExpr D funs V st (.call fn es₂) r := by\n cases h with\n | callOk h₁ h₂ h₃ h₄ h₅ => exact Step.callOk (ha.mp h₁) h₂ h₃ h₄ h₅\n | cal...
[ { "name": "EquivExpr.call_congr", "fan_in": 0, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 8, "n_chars": 313, "n_subproofs": 0, "n_tactics": 1, "cyclomatic": 1, "n_automation": 0, "n_rewrites": 0, "n_structural": 0, "automation_only": false, "max_ne...
1
import Mathlib.Data.List.Forall2 import YulSemantics.BigStep /-! # YulSemantics.Equiv Phase 5 foundations: **semantic equivalence** and its **congruence** properties — the layer Yul→Yul optimization-pass correctness proofs stand on (see `DESIGN.md`). ## Equivalences `EquivExpr`/`EquivArgs`/`EquivStmt`/`EquivStmts`/...
import Mathlib.Data.List.Forall2 import YulSemantics.BigStep /-! # YulSemantics.Equiv Phase 5 foundations: **semantic equivalence** and its **congruence** properties — the layer Yul→Yul optimization-pass correctness proofs stand on (see `DESIGN.md`). ## Equivalences `EquivExpr`/`EquivArgs`/`EquivStmt`/`EquivStmts`/...
@@ -98,9 +98,17 @@ /-! ### Behavior: whole-program runs -/ +private theorem callImp {fn : Ident} {es₁ es₂} (ha : EquivArgs D es₁ es₂) {funs V st r} + (h : EvalExpr D funs V st (.call fn es₁) r) : EvalExpr D funs V st (.call fn es₂) r := by + cases h with + | callOk h₁ h₂ h₃ h₄ h₅ => exact Step.callOk (ha.mp h...
{ "repo": "yul-semantics", "git_repo": "github.com/powdr-labs/yul-semantics", "revision": "f4e6187d684c0ebaee751750c5c368a4226abb73", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollar...
ablate_274d37e02594_3
6cef8ef71c2171d0
lean
lean
github.com/powdr-labs/yul-semantics
f4e6187d684c0ebaee751750c5c368a4226abb73
YulSemantics/Equiv.lean
Equiv
3
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
16
1
[ { "theorem_name": "EquivStmts.cons_congr", "depth": 1, "n_commands": 0, "n_lines": 2, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": "\n fun _ _ _ _ _ _ => ⟨consImp hs hss, consImp hs.symm hss.symm⟩", "n_chars": 68, "n_subproofs": 0, "n_tactics"...
[ { "name": "consImp", "text": "private theorem consImp {s₁ s₂ : Stmt D.Op} {ss₁ ss₂} (hs : EquivStmt D s₁ s₂)\n (hss : EquivStmts D ss₁ ss₂) {funs V st V' st' o}\n (h : ExecStmts D funs V st (s₁ :: ss₁) V' st' o) :\n ExecStmts D funs V st (s₂ :: ss₂) V' st' o := by\n cases h with\n | seqCons h₁ h₂...
[ { "name": "EquivStmts.cons_congr", "fan_in": 1, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 6, "n_chars": 316, "n_subproofs": 0, "n_tactics": 1, "cyclomatic": 1, "n_automation": 0, "n_rewrites": 0, "n_structural": 0, "automation_only": false, "max_n...
1
import Mathlib.Data.List.Forall2 import YulSemantics.BigStep /-! # YulSemantics.Equiv Phase 5 foundations: **semantic equivalence** and its **congruence** properties — the layer Yul→Yul optimization-pass correctness proofs stand on (see `DESIGN.md`). ## Equivalences `EquivExpr`/`EquivArgs`/`EquivStmt`/`EquivStmts`/...
import Mathlib.Data.List.Forall2 import YulSemantics.BigStep /-! # YulSemantics.Equiv Phase 5 foundations: **semantic equivalence** and its **congruence** properties — the layer Yul→Yul optimization-pass correctness proofs stand on (see `DESIGN.md`). ## Equivalences `EquivExpr`/`EquivArgs`/`EquivStmt`/`EquivStmts`/...
@@ -98,9 +98,18 @@ /-! ### Behavior: whole-program runs -/ +private theorem consImp {s₁ s₂ : Stmt D.Op} {ss₁ ss₂} (hs : EquivStmt D s₁ s₂) + (hss : EquivStmts D ss₁ ss₂) {funs V st V' st' o} + (h : ExecStmts D funs V st (s₁ :: ss₁) V' st' o) : + ExecStmts D funs V st (s₂ :: ss₂) V' st' o := by + cases h ...
{ "repo": "yul-semantics", "git_repo": "github.com/powdr-labs/yul-semantics", "revision": "f4e6187d684c0ebaee751750c5c368a4226abb73", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollar...
ablate_274d37e02594_4
f50c419922c8f7e6
lean
lean
github.com/powdr-labs/yul-semantics
f4e6187d684c0ebaee751750c5c368a4226abb73
YulSemantics/Equiv.lean
Equiv
4
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
16
1
[ { "theorem_name": "EquivStmts.of_forall₂", "depth": 1, "n_commands": 0, "n_lines": 4, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n induction h with\n | nil => exact EquivStmts.refl []\n | cons hh _ ih => exact EquivStmts.cons_congr hh ih", "n...
[ { "name": "EquivStmts.cons_congr", "text": "/-- Congruence: sequences extend equivalences element-wise. -/\ntheorem EquivStmts.cons_congr {s₁ s₂ : Stmt D.Op} {ss₁ ss₂} (hs : EquivStmt D s₁ s₂)\n (hss : EquivStmts D ss₁ ss₂) : EquivStmts D (s₁ :: ss₁) (s₂ :: ss₂) :=\n fun _ _ _ _ _ _ => ⟨consImp hs hss, ...
[ { "name": "EquivStmts.of_forall₂", "fan_in": 1, "n_deps_direct": 2, "n_deps_transitive": 3, "n_lines": 8, "n_chars": 322, "n_subproofs": 0, "n_tactics": 4, "cyclomatic": 2, "n_automation": 0, "n_rewrites": 0, "n_structural": 3, "automation_only": false, "max_n...
2
import Mathlib.Data.List.Forall2 import YulSemantics.BigStep /-! # YulSemantics.Equiv Phase 5 foundations: **semantic equivalence** and its **congruence** properties — the layer Yul→Yul optimization-pass correctness proofs stand on (see `DESIGN.md`). ## Equivalences `EquivExpr`/`EquivArgs`/`EquivStmt`/`EquivStmts`/...
import Mathlib.Data.List.Forall2 import YulSemantics.BigStep /-! # YulSemantics.Equiv Phase 5 foundations: **semantic equivalence** and its **congruence** properties — the layer Yul→Yul optimization-pass correctness proofs stand on (see `DESIGN.md`). ## Equivalences `EquivExpr`/`EquivArgs`/`EquivStmt`/`EquivStmts`/...
@@ -140,12 +140,17 @@ | seqCons h₁ h₂ => exact Step.seqCons (hs.mp h₁) (hss.mp h₂) | seqStop h₁ h₂ => exact Step.seqStop (hs.mp h₁) h₂ +/-- Congruence: sequences extend equivalences element-wise. -/ +theorem EquivStmts.cons_congr {s₁ s₂ : Stmt D.Op} {ss₁ ss₂} (hs : EquivStmt D s₁ s₂) + (hss : EquivStmts D ss...
{ "repo": "yul-semantics", "git_repo": "github.com/powdr-labs/yul-semantics", "revision": "f4e6187d684c0ebaee751750c5c368a4226abb73", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollar...
ablate_274d37e02594_5
761b5e70990d8a16
lean
lean
github.com/powdr-labs/yul-semantics
f4e6187d684c0ebaee751750c5c368a4226abb73
YulSemantics/Equiv.lean
Equiv
5
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
16
1
[ { "theorem_name": "EquivBlock.of_stmts", "depth": 1, "n_commands": 0, "n_lines": 2, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": "\n fun _ _ _ _ _ _ => ⟨blockImp hss hh, blockImp hss.symm hh.symm⟩", "n_chars": 70, "n_subproofs": 0, "n_tactics"...
[ { "name": "blockImp", "text": "private theorem blockImp {b₁ b₂ : Block D.Op} (hss : EquivStmts D b₁ b₂)\n (hh : hoist D b₁ = hoist D b₂) {funs V st V' st' o}\n (h : ExecStmt D funs V st (.block b₁) V' st' o) :\n ExecStmt D funs V st (.block b₂) V' st' o := by\n cases h with\n | block hb => exact ...
[ { "name": "EquivBlock.of_stmts", "fan_in": 1, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 9, "n_chars": 543, "n_subproofs": 0, "n_tactics": 1, "cyclomatic": 1, "n_automation": 0, "n_rewrites": 0, "n_structural": 0, "automation_only": false, "max_nes...
1
import Mathlib.Data.List.Forall2 import YulSemantics.BigStep /-! # YulSemantics.Equiv Phase 5 foundations: **semantic equivalence** and its **congruence** properties — the layer Yul→Yul optimization-pass correctness proofs stand on (see `DESIGN.md`). ## Equivalences `EquivExpr`/`EquivArgs`/`EquivStmt`/`EquivStmts`/...
import Mathlib.Data.List.Forall2 import YulSemantics.BigStep /-! # YulSemantics.Equiv Phase 5 foundations: **semantic equivalence** and its **congruence** properties — the layer Yul→Yul optimization-pass correctness proofs stand on (see `DESIGN.md`). ## Equivalences `EquivExpr`/`EquivArgs`/`EquivStmt`/`EquivStmts`/...
@@ -98,12 +98,20 @@ /-! ### Behavior: whole-program runs -/ +private theorem blockImp {b₁ b₂ : Block D.Op} (hss : EquivStmts D b₁ b₂) + (hh : hoist D b₁ = hoist D b₂) {funs V st V' st' o} + (h : ExecStmt D funs V st (.block b₁) V' st' o) : + ExecStmt D funs V st (.block b₂) V' st' o := by + cases h with ...
{ "repo": "yul-semantics", "git_repo": "github.com/powdr-labs/yul-semantics", "revision": "f4e6187d684c0ebaee751750c5c368a4226abb73", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollar...
ablate_274d37e02594_6
362e0c35494cf445
lean
lean
github.com/powdr-labs/yul-semantics
f4e6187d684c0ebaee751750c5c368a4226abb73
YulSemantics/Equiv.lean
Equiv
6
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
16
1
[ { "theorem_name": "EquivBlock.of_forall₂", "depth": 1, "n_commands": 0, "n_lines": 2, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": "\n EquivBlock.of_stmts (EquivStmts.of_forall₂ h) hh", "n_chars": 53, "n_subproofs": 0, "n_tactics": 1, "cyc...
[ { "name": "EquivBlock.of_stmts", "text": "/-- Congruence for blocks: equivalent bodies that hoist the **same function scope** form\nequivalent blocks. The hoist condition is `rfl` whenever the rewrite does not touch top-level\n`funDef` statements; rewrites *inside* function bodies need the (deferred) functi...
[ { "name": "EquivBlock.of_forall₂", "fan_in": 0, "n_deps_direct": 2, "n_deps_transitive": 6, "n_lines": 8, "n_chars": 355, "n_subproofs": 0, "n_tactics": 1, "cyclomatic": 1, "n_automation": 0, "n_rewrites": 0, "n_structural": 0, "automation_only": false, "max_n...
4
import Mathlib.Data.List.Forall2 import YulSemantics.BigStep /-! # YulSemantics.Equiv Phase 5 foundations: **semantic equivalence** and its **congruence** properties — the layer Yul→Yul optimization-pass correctness proofs stand on (see `DESIGN.md`). ## Equivalences `EquivExpr`/`EquivArgs`/`EquivStmt`/`EquivStmts`/...
import Mathlib.Data.List.Forall2 import YulSemantics.BigStep /-! # YulSemantics.Equiv Phase 5 foundations: **semantic equivalence** and its **congruence** properties — the layer Yul→Yul optimization-pass correctness proofs stand on (see `DESIGN.md`). ## Equivalences `EquivExpr`/`EquivArgs`/`EquivStmt`/`EquivStmts`/...
@@ -159,9 +159,18 @@ cases h with | block hb => exact Step.block (hh ▸ hss.mp hb) +/-- Congruence for blocks: equivalent bodies that hoist the **same function scope** form +equivalent blocks. The hoist condition is `rfl` whenever the rewrite does not touch top-level +`funDef` statements; rewrites *inside* funct...
{ "repo": "yul-semantics", "git_repo": "github.com/powdr-labs/yul-semantics", "revision": "f4e6187d684c0ebaee751750c5c368a4226abb73", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollar...
ablate_274d37e02594_7
c171d9f510f9c4c3
lean
lean
github.com/powdr-labs/yul-semantics
f4e6187d684c0ebaee751750c5c368a4226abb73
YulSemantics/Equiv.lean
Equiv
7
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
16
1
[ { "theorem_name": "EquivStmt.letDecl_congr", "depth": 1, "n_commands": 0, "n_lines": 2, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": "\n fun _ _ _ _ _ _ => ⟨letImp he, letImp he.symm⟩", "n_chars": 53, "n_subproofs": 0, "n_tactics": 1, "cyc...
[ { "name": "letImp", "text": "private theorem letImp {vars} {e₁ e₂ : Expr D.Op} (he : EquivExpr D e₁ e₂) {funs V st V' st' o}\n (h : ExecStmt D funs V st (.letDecl vars (some e₁)) V' st' o) :\n ExecStmt D funs V st (.letDecl vars (some e₂)) V' st' o := by\n cases h with\n | letVal h₁ h₂ => exact Step...
[ { "name": "EquivStmt.letDecl_congr", "fan_in": 0, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 6, "n_chars": 293, "n_subproofs": 0, "n_tactics": 1, "cyclomatic": 1, "n_automation": 0, "n_rewrites": 0, "n_structural": 0, "automation_only": false, "max...
1
import Mathlib.Data.List.Forall2 import YulSemantics.BigStep /-! # YulSemantics.Equiv Phase 5 foundations: **semantic equivalence** and its **congruence** properties — the layer Yul→Yul optimization-pass correctness proofs stand on (see `DESIGN.md`). ## Equivalences `EquivExpr`/`EquivArgs`/`EquivStmt`/`EquivStmts`/...
import Mathlib.Data.List.Forall2 import YulSemantics.BigStep /-! # YulSemantics.Equiv Phase 5 foundations: **semantic equivalence** and its **congruence** properties — the layer Yul→Yul optimization-pass correctness proofs stand on (see `DESIGN.md`). ## Equivalences `EquivExpr`/`EquivArgs`/`EquivStmt`/`EquivStmts`/...
@@ -98,9 +98,17 @@ /-! ### Behavior: whole-program runs -/ +private theorem letImp {vars} {e₁ e₂ : Expr D.Op} (he : EquivExpr D e₁ e₂) {funs V st V' st' o} + (h : ExecStmt D funs V st (.letDecl vars (some e₁)) V' st' o) : + ExecStmt D funs V st (.letDecl vars (some e₂)) V' st' o := by + cases h with + | le...
{ "repo": "yul-semantics", "git_repo": "github.com/powdr-labs/yul-semantics", "revision": "f4e6187d684c0ebaee751750c5c368a4226abb73", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollar...
ablate_274d37e02594_8
3717c5b34509cb6c
lean
lean
github.com/powdr-labs/yul-semantics
f4e6187d684c0ebaee751750c5c368a4226abb73
YulSemantics/Equiv.lean
Equiv
8
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
16
1
[ { "theorem_name": "EquivStmt.assign_congr", "depth": 1, "n_commands": 0, "n_lines": 2, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": "\n fun _ _ _ _ _ _ => ⟨assignImp he, assignImp he.symm⟩", "n_chars": 59, "n_subproofs": 0, "n_tactics": 1, ...
[ { "name": "assignImp", "text": "private theorem assignImp {vars} {e₁ e₂ : Expr D.Op} (he : EquivExpr D e₁ e₂) {funs V st V' st' o}\n (h : ExecStmt D funs V st (.assign vars e₁) V' st' o) :\n ExecStmt D funs V st (.assign vars e₂) V' st' o := by\n cases h with\n | assignVal h₁ h₂ => exact Step.assign...
[ { "name": "EquivStmt.assign_congr", "fan_in": 0, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 6, "n_chars": 291, "n_subproofs": 0, "n_tactics": 1, "cyclomatic": 1, "n_automation": 0, "n_rewrites": 0, "n_structural": 0, "automation_only": false, "max_...
1
import Mathlib.Data.List.Forall2 import YulSemantics.BigStep /-! # YulSemantics.Equiv Phase 5 foundations: **semantic equivalence** and its **congruence** properties — the layer Yul→Yul optimization-pass correctness proofs stand on (see `DESIGN.md`). ## Equivalences `EquivExpr`/`EquivArgs`/`EquivStmt`/`EquivStmts`/...
import Mathlib.Data.List.Forall2 import YulSemantics.BigStep /-! # YulSemantics.Equiv Phase 5 foundations: **semantic equivalence** and its **congruence** properties — the layer Yul→Yul optimization-pass correctness proofs stand on (see `DESIGN.md`). ## Equivalences `EquivExpr`/`EquivArgs`/`EquivStmt`/`EquivStmts`/...
@@ -98,9 +98,17 @@ /-! ### Behavior: whole-program runs -/ +private theorem assignImp {vars} {e₁ e₂ : Expr D.Op} (he : EquivExpr D e₁ e₂) {funs V st V' st' o} + (h : ExecStmt D funs V st (.assign vars e₁) V' st' o) : + ExecStmt D funs V st (.assign vars e₂) V' st' o := by + cases h with + | assignVal h₁ h₂...
{ "repo": "yul-semantics", "git_repo": "github.com/powdr-labs/yul-semantics", "revision": "f4e6187d684c0ebaee751750c5c368a4226abb73", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollar...
ablate_274d37e02594_9
7cb277821546874c
lean
lean
github.com/powdr-labs/yul-semantics
f4e6187d684c0ebaee751750c5c368a4226abb73
YulSemantics/Equiv.lean
Equiv
9
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
16
1
[ { "theorem_name": "EquivStmt.exprStmt_congr", "depth": 1, "n_commands": 0, "n_lines": 2, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": "\n fun _ _ _ _ _ _ => ⟨exprStmtImp he, exprStmtImp he.symm⟩", "n_chars": 63, "n_subproofs": 0, "n_tactics": ...
[ { "name": "exprStmtImp", "text": "private theorem exprStmtImp {e₁ e₂ : Expr D.Op} (he : EquivExpr D e₁ e₂) {funs V st V' st' o}\n (h : ExecStmt D funs V st (.exprStmt e₁) V' st' o) :\n ExecStmt D funs V st (.exprStmt e₂) V' st' o := by\n cases h with\n | exprStmt h₁ => exact Step.exprStmt (he.mp h₁)...
[ { "name": "EquivStmt.exprStmt_congr", "fan_in": 0, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 6, "n_chars": 247, "n_subproofs": 0, "n_tactics": 1, "cyclomatic": 1, "n_automation": 0, "n_rewrites": 0, "n_structural": 0, "automation_only": false, "ma...
1
import Mathlib.Data.List.Forall2 import YulSemantics.BigStep /-! # YulSemantics.Equiv Phase 5 foundations: **semantic equivalence** and its **congruence** properties — the layer Yul→Yul optimization-pass correctness proofs stand on (see `DESIGN.md`). ## Equivalences `EquivExpr`/`EquivArgs`/`EquivStmt`/`EquivStmts`/...
import Mathlib.Data.List.Forall2 import YulSemantics.BigStep /-! # YulSemantics.Equiv Phase 5 foundations: **semantic equivalence** and its **congruence** properties — the layer Yul→Yul optimization-pass correctness proofs stand on (see `DESIGN.md`). ## Equivalences `EquivExpr`/`EquivArgs`/`EquivStmt`/`EquivStmts`/...
@@ -98,9 +98,17 @@ /-! ### Behavior: whole-program runs -/ +private theorem exprStmtImp {e₁ e₂ : Expr D.Op} (he : EquivExpr D e₁ e₂) {funs V st V' st' o} + (h : ExecStmt D funs V st (.exprStmt e₁) V' st' o) : + ExecStmt D funs V st (.exprStmt e₂) V' st' o := by + cases h with + | exprStmt h₁ => exact Step....
{ "repo": "yul-semantics", "git_repo": "github.com/powdr-labs/yul-semantics", "revision": "f4e6187d684c0ebaee751750c5c368a4226abb73", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollar...
ablate_274d37e02594_10
c200a91c3694a4af
lean
lean
github.com/powdr-labs/yul-semantics
f4e6187d684c0ebaee751750c5c368a4226abb73
YulSemantics/Equiv.lean
Equiv
10
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
16
1
[ { "theorem_name": "EquivStmt.cond_congr", "depth": 1, "n_commands": 0, "n_lines": 2, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": "\n fun _ _ _ _ _ _ => ⟨condImp hc hb, condImp hc.symm hb.symm⟩", "n_chars": 66, "n_subproofs": 0, "n_tactics": 1...
[ { "name": "condImp", "text": "private theorem condImp {c₁ c₂ : Expr D.Op} {b₁ b₂ : Block D.Op} (hc : EquivExpr D c₁ c₂)\n (hb : EquivBlock D b₁ b₂) {funs V st V' st' o}\n (h : ExecStmt D funs V st (.cond c₁ b₁) V' st' o) :\n ExecStmt D funs V st (.cond c₂ b₂) V' st' o := by\n cases h with\n | ifT...
[ { "name": "EquivStmt.cond_congr", "fan_in": 0, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 6, "n_chars": 324, "n_subproofs": 0, "n_tactics": 1, "cyclomatic": 1, "n_automation": 0, "n_rewrites": 0, "n_structural": 0, "automation_only": false, "max_ne...
1
import Mathlib.Data.List.Forall2 import YulSemantics.BigStep /-! # YulSemantics.Equiv Phase 5 foundations: **semantic equivalence** and its **congruence** properties — the layer Yul→Yul optimization-pass correctness proofs stand on (see `DESIGN.md`). ## Equivalences `EquivExpr`/`EquivArgs`/`EquivStmt`/`EquivStmts`/...
import Mathlib.Data.List.Forall2 import YulSemantics.BigStep /-! # YulSemantics.Equiv Phase 5 foundations: **semantic equivalence** and its **congruence** properties — the layer Yul→Yul optimization-pass correctness proofs stand on (see `DESIGN.md`). ## Equivalences `EquivExpr`/`EquivArgs`/`EquivStmt`/`EquivStmts`/...
@@ -98,9 +98,19 @@ /-! ### Behavior: whole-program runs -/ +private theorem condImp {c₁ c₂ : Expr D.Op} {b₁ b₂ : Block D.Op} (hc : EquivExpr D c₁ c₂) + (hb : EquivBlock D b₁ b₂) {funs V st V' st' o} + (h : ExecStmt D funs V st (.cond c₁ b₁) V' st' o) : + ExecStmt D funs V st (.cond c₂ b₂) V' st' o := by +...
{ "repo": "yul-semantics", "git_repo": "github.com/powdr-labs/yul-semantics", "revision": "f4e6187d684c0ebaee751750c5c368a4226abb73", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollar...
ablate_274d37e02594_11
837b8177986e6103
lean
lean
github.com/powdr-labs/yul-semantics
f4e6187d684c0ebaee751750c5c368a4226abb73
YulSemantics/Equiv.lean
Equiv
11
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
16
1
[ { "theorem_name": "EquivStmt.switch_congr", "depth": 1, "n_commands": 0, "n_lines": 7, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n have hcases' := forall₂_symm\n (R := fun (p q : Literal × Block D.Op) => p.1 = q.1 ∧ EquivBlock D p.2 q.2)\n (...
[ { "name": "switchImp", "text": "private theorem switchImp {c₁ c₂ : Expr D.Op} {cs₁ cs₂ dflt₁ dflt₂} (hc : EquivExpr D c₁ c₂)\n (hsel : ∀ cv, EquivBlock D (selectSwitch D cv cs₁ dflt₁) (selectSwitch D cv cs₂ dflt₂))\n {funs V st V' st' o} (h : ExecStmt D funs V st (.switch c₁ cs₁ dflt₁) V' st' o) :\n ...
[ { "name": "EquivStmt.switch_congr", "fan_in": 0, "n_deps_direct": 3, "n_deps_transitive": 3, "n_lines": 15, "n_chars": 881, "n_subproofs": 1, "n_tactics": 7, "cyclomatic": 1, "n_automation": 0, "n_rewrites": 0, "n_structural": 1, "automation_only": false, "max...
3
import Mathlib.Data.List.Forall2 import YulSemantics.BigStep /-! # YulSemantics.Equiv Phase 5 foundations: **semantic equivalence** and its **congruence** properties — the layer Yul→Yul optimization-pass correctness proofs stand on (see `DESIGN.md`). ## Equivalences `EquivExpr`/`EquivArgs`/`EquivStmt`/`EquivStmts`/...
import Mathlib.Data.List.Forall2 import YulSemantics.BigStep /-! # YulSemantics.Equiv Phase 5 foundations: **semantic equivalence** and its **congruence** properties — the layer Yul→Yul optimization-pass correctness proofs stand on (see `DESIGN.md`). ## Equivalences `EquivExpr`/`EquivArgs`/`EquivStmt`/`EquivStmts`/...
@@ -128,13 +128,27 @@ List.find?_cons_of_neg (by simp [← hl, hcv]) simpa only [selectSwitch, h₁, h₂] using ih +private theorem switchImp {c₁ c₂ : Expr D.Op} {cs₁ cs₂ dflt₁ dflt₂} (hc : EquivExpr D c₁ c₂) + (hsel : ∀ cv, EquivBlock D (selectSwitch D cv cs₁ dflt₁) (selectSwitch D cv cs₂ dflt₂)) +...
{ "repo": "yul-semantics", "git_repo": "github.com/powdr-labs/yul-semantics", "revision": "f4e6187d684c0ebaee751750c5c368a4226abb73", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollar...
ablate_274d37e02594_12
da3637d89e8df1ea
lean
lean
github.com/powdr-labs/yul-semantics
f4e6187d684c0ebaee751750c5c368a4226abb73
YulSemantics/Equiv.lean
Equiv
12
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
16
1
[ { "theorem_name": "forImp", "depth": 1, "n_commands": 0, "n_lines": 4, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n cases h with\n | forLoop hinit hloop => exact Step.forLoop hinit (loopImp hc hpost hbody hloop rfl)\n | forInitHalt hinit => exact...
[ { "name": "loopImp", "text": "private theorem loopImp {c₁ c₂ : Expr D.Op} {post₁ post₂ body₁ body₂ : Block D.Op}\n (hc : EquivExpr D c₁ c₂) (hpost : EquivBlock D post₁ post₂) (hbody : EquivBlock D body₁ body₂) :\n ∀ {funs V st code res}, Step D funs V st code res →\n code = .loop c₁ post₁ body₁ →...
[ { "name": "forImp", "fan_in": 1, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 9, "n_chars": 546, "n_subproofs": 0, "n_tactics": 4, "cyclomatic": 2, "n_automation": 1, "n_rewrites": 0, "n_structural": 3, "automation_only": false, "max_nesting": 2 } ...
1
import Mathlib.Data.List.Forall2 import YulSemantics.BigStep /-! # YulSemantics.Equiv Phase 5 foundations: **semantic equivalence** and its **congruence** properties — the layer Yul→Yul optimization-pass correctness proofs stand on (see `DESIGN.md`). ## Equivalences `EquivExpr`/`EquivArgs`/`EquivStmt`/`EquivStmts`/...
import Mathlib.Data.List.Forall2 import YulSemantics.BigStep /-! # YulSemantics.Equiv Phase 5 foundations: **semantic equivalence** and its **congruence** properties — the layer Yul→Yul optimization-pass correctness proofs stand on (see `DESIGN.md`). ## Equivalences `EquivExpr`/`EquivArgs`/`EquivStmt`/`EquivStmts`/...
@@ -89,12 +89,49 @@ /-! ### Behavior: whole-program runs -/ +private theorem loopImp {c₁ c₂ : Expr D.Op} {post₁ post₂ body₁ body₂ : Block D.Op} + (hc : EquivExpr D c₁ c₂) (hpost : EquivBlock D post₁ post₂) (hbody : EquivBlock D body₁ body₂) : + ∀ {funs V st code res}, Step D funs V st code res → + code ...
{ "repo": "yul-semantics", "git_repo": "github.com/powdr-labs/yul-semantics", "revision": "f4e6187d684c0ebaee751750c5c368a4226abb73", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollar...
ablate_274d37e02594_13
11dba1dfd42df38a
lean
lean
github.com/powdr-labs/yul-semantics
f4e6187d684c0ebaee751750c5c368a4226abb73
YulSemantics/Equiv.lean
Equiv
13
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
16
1
[ { "theorem_name": "EquivStmt.forLoop_congr", "depth": 1, "n_commands": 0, "n_lines": 3, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": "\n fun _ _ _ _ _ _ =>\n ⟨forImp hc hpost hbody, forImp hc.symm hpost.symm hbody.symm⟩", "n_chars": 91, "n_subp...
[ { "name": "forImp", "text": "private theorem forImp {init} {c₁ c₂ : Expr D.Op} {post₁ post₂ body₁ body₂ : Block D.Op}\n (hc : EquivExpr D c₁ c₂) (hpost : EquivBlock D post₁ post₂) (hbody : EquivBlock D body₁ body₂)\n {funs V st V' st' o} (h : ExecStmt D funs V st (.forLoop init c₁ post₁ body₁) V' st' ...
[ { "name": "EquivStmt.forLoop_congr", "fan_in": 0, "n_deps_direct": 1, "n_deps_transitive": 2, "n_lines": 11, "n_chars": 657, "n_subproofs": 0, "n_tactics": 2, "cyclomatic": 1, "n_automation": 0, "n_rewrites": 0, "n_structural": 0, "automation_only": false, "ma...
2
import Mathlib.Data.List.Forall2 import YulSemantics.BigStep /-! # YulSemantics.Equiv Phase 5 foundations: **semantic equivalence** and its **congruence** properties — the layer Yul→Yul optimization-pass correctness proofs stand on (see `DESIGN.md`). ## Equivalences `EquivExpr`/`EquivArgs`/`EquivStmt`/`EquivStmts`/...
import Mathlib.Data.List.Forall2 import YulSemantics.BigStep /-! # YulSemantics.Equiv Phase 5 foundations: **semantic equivalence** and its **congruence** properties — the layer Yul→Yul optimization-pass correctness proofs stand on (see `DESIGN.md`). ## Equivalences `EquivExpr`/`EquivArgs`/`EquivStmt`/`EquivStmts`/...
@@ -135,13 +135,23 @@ exact Step.loopBodyHalt (hc.mp hcv) hnz (hbody.mp hb) all_goals exact nofun +private theorem forImp {init} {c₁ c₂ : Expr D.Op} {post₁ post₂ body₁ body₂ : Block D.Op} + (hc : EquivExpr D c₁ c₂) (hpost : EquivBlock D post₁ post₂) (hbody : EquivBlock D body₁ body₂) + {funs V st V' s...
{ "repo": "yul-semantics", "git_repo": "github.com/powdr-labs/yul-semantics", "revision": "f4e6187d684c0ebaee751750c5c368a4226abb73", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollar...
ablate_27763110deb1_0
fd998a58df907617
lean
lean
github.com/powdr-labs/yul-semantics
f4e6187d684c0ebaee751750c5c368a4226abb73
YulSemantics/Rewrites.lean
Rewrites
0
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
3
1
[ { "theorem_name": "fold_add_2_3", "depth": 1, "n_commands": 0, "n_lines": 27, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n have hval : EVM.litValue (.number 2) + EVM.litValue (.number 3) = EVM.litValue (.number 5) := by\n decide\n intro funs V ...
[ { "name": "two_lits_inv", "text": "/-- Two literal arguments always evaluate to their values, unchanged state. -/\nprivate theorem two_lits_inv {funs V st l₁ l₂ r}\n (h : EvalArgs EVM.evm funs V st [.lit l₁, .lit l₂] r) :\n r = .vals [EVM.litValue l₁, EVM.litValue l₂] st := by\n cases h with\n | arg...
[ { "name": "fold_add_2_3", "fan_in": 0, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 32, "n_chars": 1005, "n_subproofs": 5, "n_tactics": 31, "cyclomatic": 4, "n_automation": 7, "n_rewrites": 5, "n_structural": 9, "automation_only": false, "max_nesting...
1
import YulSemantics.Equiv import YulSemantics.Syntax /-! # YulSemantics.Rewrites Sample **local rewrites** for the EVM dialect, proven as semantic equivalences and lifted through the congruence lemmas of `YulSemantics.Equiv` — validating that the Phase 5 framework can carry an optimizer's proof obligations: * consta...
import YulSemantics.Equiv import YulSemantics.Syntax /-! # YulSemantics.Rewrites Sample **local rewrites** for the EVM dialect, proven as semantic equivalences and lifted through the congruence lemmas of `YulSemantics.Equiv` — validating that the Phase 5 framework can carry an optimizer's proof obligations: * consta...
@@ -25,6 +25,24 @@ /-! ### Inversion helpers for two-element EVM argument lists -/ +/-- Two literal arguments always evaluate to their values, unchanged state. -/ +private theorem two_lits_inv {funs V st l₁ l₂ r} + (h : EvalArgs EVM.evm funs V st [.lit l₁, .lit l₂] r) : + r = .vals [EVM.litValue l₁, EVM.litV...
{ "repo": "yul-semantics", "git_repo": "github.com/powdr-labs/yul-semantics", "revision": "f4e6187d684c0ebaee751750c5c368a4226abb73", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollar...
ablate_27763110deb1_1
9e7200cdc6d6cbe2
lean
lean
github.com/powdr-labs/yul-semantics
f4e6187d684c0ebaee751750c5c368a4226abb73
YulSemantics/Rewrites.lean
Rewrites
1
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
3
1
[ { "theorem_name": "add_zero", "depth": 1, "n_commands": 0, "n_lines": 28, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n have hz : ∀ v : EVM.U256, v + EVM.litValue (.number 0) = v := fun v => by\n have h0 : EVM.litValue (.number 0) = 0 := by decid...
[ { "name": "var_lit_inv", "text": "/-- A variable and a literal always evaluate to the variable's value and the literal, unchanged\nstate. -/\nprivate theorem var_lit_inv {funs V st x l r}\n (h : EvalArgs EVM.evm funs V st [.var x, .lit l] r) :\n ∃ v, VEnv.get V x = some v ∧ r = .vals [v, EVM.litValue ...
[ { "name": "add_zero", "fan_in": 1, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 33, "n_chars": 1119, "n_subproofs": 6, "n_tactics": 33, "cyclomatic": 4, "n_automation": 7, "n_rewrites": 6, "n_structural": 13, "automation_only": false, "max_nesting": ...
1
import YulSemantics.Equiv import YulSemantics.Syntax /-! # YulSemantics.Rewrites Sample **local rewrites** for the EVM dialect, proven as semantic equivalences and lifted through the congruence lemmas of `YulSemantics.Equiv` — validating that the Phase 5 framework can carry an optimizer's proof obligations: * consta...
import YulSemantics.Equiv import YulSemantics.Syntax /-! # YulSemantics.Rewrites Sample **local rewrites** for the EVM dialect, proven as semantic equivalences and lifted through the congruence lemmas of `YulSemantics.Equiv` — validating that the Phase 5 framework can carry an optimizer's proof obligations: * consta...
@@ -25,6 +25,27 @@ /-! ### Inversion helpers for two-element EVM argument lists -/ +/-- A variable and a literal always evaluate to the variable's value and the literal, unchanged +state. -/ +private theorem var_lit_inv {funs V st x l r} + (h : EvalArgs EVM.evm funs V st [.var x, .lit l] r) : + ∃ v, VEnv.get...
{ "repo": "yul-semantics", "git_repo": "github.com/powdr-labs/yul-semantics", "revision": "f4e6187d684c0ebaee751750c5c368a4226abb73", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollar...
ablate_57aa5e0a77cb_0
76e48f3e3fd8aa86
lean
lean
github.com/powdr-labs/yul-semantics
f4e6187d684c0ebaee751750c5c368a4226abb73
YulSemantics/Determinism.lean
Determinism
0
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
1
1
[ { "theorem_name": "EVM.run_det", "depth": 1, "n_commands": 0, "n_lines": 2, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": "\n Run.det EVM.evm_deterministic h₁ h₂", "n_chars": 42, "n_subproofs": 0, "n_tactics": 1, "cyclomatic": 1, "n_aut...
[ { "name": "EVM.evm_deterministic", "text": "/-- Every EVM built-in is deterministic: `Builtin` is defined by the function `stepOp`. -/\ntheorem EVM.evm_deterministic (op : EVM.Op) : EVM.evm.Deterministic op := by\n intro args st r₁ r₂ h₁ h₂\n have h₁' : EVM.stepOp op args st = some r₁ := h₁\n have h₂' : ...
[ { "name": "EVM.run_det", "fan_in": 0, "n_deps_direct": 2, "n_deps_transitive": 4, "n_lines": 7, "n_chars": 311, "n_subproofs": 0, "n_tactics": 1, "cyclomatic": 1, "n_automation": 0, "n_rewrites": 0, "n_structural": 0, "automation_only": false, "max_nesting": 2...
1
import YulSemantics.BigStep import YulSemantics.Dialect.EVM /-! # YulSemantics.Determinism The big-step judgment is **deterministic**: a configuration evaluates to at most one result, provided every built-in is deterministic (`∀ op, D.Deterministic op`). `switch` needs no side condition — it is deterministic by const...
import YulSemantics.BigStep import YulSemantics.Dialect.EVM /-! # YulSemantics.Determinism The big-step judgment is **deterministic**: a configuration evaluates to at most one result, provided every built-in is deterministic (`∀ op, D.Deterministic op`). `switch` needs no side condition — it is deterministic by const...
@@ -415,10 +415,19 @@ /-! ### The EVM dialect satisfies the hypothesis -/ +/-- Every EVM built-in is deterministic: `Builtin` is defined by the function `stepOp`. -/ +theorem EVM.evm_deterministic (op : EVM.Op) : EVM.evm.Deterministic op := by + intro args st r₁ r₂ h₁ h₂ + have h₁' : EVM.stepOp op args st = some...
{ "repo": "yul-semantics", "git_repo": "github.com/powdr-labs/yul-semantics", "revision": "f4e6187d684c0ebaee751750c5c368a4226abb73", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollar...
ablate_7a5f39910c5e_0
ca7127165d77f8cb
lean
lean
github.com/powdr-labs/yul-semantics
f4e6187d684c0ebaee751750c5c368a4226abb73
YulSemantics/ObjectRun.lean
ObjectRun
0
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
4
2
[ { "theorem_name": "datacopy_copies_data", "depth": 1, "n_commands": 0, "n_lines": 4, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n obtain ⟨_, hbytes⟩ := hc (n, d) hmem\n rw [readBytes_copyInto]\n exact hbytes", "n_chars": 87, "n_subproofs"...
[ { "name": "readBytes_copyInto", "text": "/-- Reading back the region a `copyInto` just wrote reproduces the source bytes. -/\ntheorem readBytes_copyInto (mem : Nat → UInt8) (bytes : List UInt8) (t off sz : Nat) :\n readBytes (copyInto mem t off sz bytes) t sz = readBytes (byteFrom bytes) off sz := by\n ...
[ { "name": "datacopy_copies_data", "fan_in": 0, "n_deps_direct": 1, "n_deps_transitive": 1, "n_lines": 19, "n_chars": 1007, "n_subproofs": 1, "n_tactics": 4, "cyclomatic": 1, "n_automation": 0, "n_rewrites": 1, "n_structural": 2, "automation_only": false, "max_...
1
import YulSemantics.Interp import YulSemantics.Dialect.EVM import YulSemantics.Object import YulSemantics.Syntax /-! # YulSemantics.ObjectRun Running a Yul **object** under a bytecode **layout**, and the consistency condition linking the two. An object's `code` references its data segments and sub-objects by name th...
import YulSemantics.Interp import YulSemantics.Dialect.EVM import YulSemantics.Object import YulSemantics.Syntax /-! # YulSemantics.ObjectRun Running a Yul **object** under a bytecode **layout**, and the consistency condition linking the two. An object's `code` references its data segments and sub-objects by name th...
@@ -64,13 +64,28 @@ /-! ### Correctness of `datacopy` under a consistent layout -/ +/-- Reading back the region a `copyInto` just wrote reproduces the source bytes. -/ +theorem readBytes_copyInto (mem : Nat → UInt8) (bytes : List UInt8) (t off sz : Nat) : + readBytes (copyInto mem t off sz bytes) t sz = readByt...
{ "repo": "yul-semantics", "git_repo": "github.com/powdr-labs/yul-semantics", "revision": "f4e6187d684c0ebaee751750c5c368a4226abb73", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollar...
ablate_7a5f39910c5e_1
16eaad1f17760423
lean
lean
github.com/powdr-labs/yul-semantics
f4e6187d684c0ebaee751750c5c368a4226abb73
YulSemantics/ObjectRun.lean
ObjectRun
1
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
4
1
[ { "theorem_name": "constructorCode_returns", "depth": 1, "n_commands": 0, "n_lines": 14, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n refine ⟨[], _, Step.block (Step.seqCons\n (Step.exprStmt (Step.builtinOk\n (Step.argsCons (Step.argsCo...
[ { "name": "eval_datasize", "text": "/-- `datasize(name)` evaluates (at any configuration) to the environment's recorded size. -/\ntheorem eval_datasize (funs : FunEnv evm) (V : VEnv evm) (st : EvmState) (n : Ident) :\n EvalExpr evm funs V st (.builtin .datasize [.lit (.string n)])\n (.vals [st.env.d...
[ { "name": "constructorCode_returns", "fan_in": 1, "n_deps_direct": 3, "n_deps_transitive": 3, "n_lines": 24, "n_chars": 1295, "n_subproofs": 1, "n_tactics": 13, "cyclomatic": 1, "n_automation": 4, "n_rewrites": 2, "n_structural": 1, "automation_only": false, "...
3
import YulSemantics.Interp import YulSemantics.Dialect.EVM import YulSemantics.Object import YulSemantics.Syntax /-! # YulSemantics.ObjectRun Running a Yul **object** under a bytecode **layout**, and the consistency condition linking the two. An object's `code` references its data segments and sub-objects by name th...
import YulSemantics.Interp import YulSemantics.Dialect.EVM import YulSemantics.Object import YulSemantics.Syntax /-! # YulSemantics.ObjectRun Running a Yul **object** under a bytecode **layout**, and the consistency condition linking the two. An object's `code` references its data segments and sub-objects by name th...
@@ -82,6 +82,12 @@ [.lit (.number 0), .builtin .dataoffset [.lit (.string n)], .builtin .datasize [.lit (.string n)]]), .exprStmt (.builtin .ret [.lit (.number 0), .builtin .datasize [.lit (.string n)]]) ] +/-- `datasize(name)` evaluates (at any configuration) to the environment's recorded size. -/ +theor...
{ "repo": "yul-semantics", "git_repo": "github.com/powdr-labs/yul-semantics", "revision": "f4e6187d684c0ebaee751750c5c368a4226abb73", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollar...
ablate_7a5f39910c5e_2
f5ea97a5a8335b4a
lean
lean
github.com/powdr-labs/yul-semantics
f4e6187d684c0ebaee751750c5c368a4226abb73
YulSemantics/ObjectRun.lean
ObjectRun
2
lemma_delete
null
null
false
0.5
1
1
false
0
inf
0
inf
42
4
1
[ { "theorem_name": "constructorCode_returns", "depth": 1, "n_commands": 0, "n_lines": 14, "is_leaf": true, "centrality": 0, "method": "deleted-dep", "proof_text": " by\n refine ⟨[], _, Step.block (Step.seqCons\n (Step.exprStmt (Step.builtinOk\n (Step.argsCons (Step.argsCo...
[ { "name": "eval_dataoffset", "text": "/-- `dataoffset(name)` evaluates to the environment's recorded offset. -/\ntheorem eval_dataoffset (funs : FunEnv evm) (V : VEnv evm) (st : EvmState) (n : Ident) :\n EvalExpr evm funs V st (.builtin .dataoffset [.lit (.string n)])\n (.vals [st.env.dataOffset (li...
[ { "name": "constructorCode_returns_of_consistent", "fan_in": 0, "n_deps_direct": 1, "n_deps_transitive": 4, "n_lines": 15, "n_chars": 655, "n_subproofs": 1, "n_tactics": 2, "cyclomatic": 1, "n_automation": 0, "n_rewrites": 0, "n_structural": 0, "automation_only": ...
4
import YulSemantics.Interp import YulSemantics.Dialect.EVM import YulSemantics.Object import YulSemantics.Syntax /-! # YulSemantics.ObjectRun Running a Yul **object** under a bytecode **layout**, and the consistency condition linking the two. An object's `code` references its data segments and sub-objects by name th...
import YulSemantics.Interp import YulSemantics.Dialect.EVM import YulSemantics.Object import YulSemantics.Syntax /-! # YulSemantics.ObjectRun Running a Yul **object** under a bytecode **layout**, and the consistency condition linking the two. An object's `code` references its data segments and sub-objects by name th...
@@ -88,6 +88,12 @@ (.vals [st.env.dataSize (litValue (.string n))] st) := Step.builtinOk (Step.argsCons Step.argsNil Step.lit) rfl +/-- `dataoffset(name)` evaluates to the environment's recorded offset. -/ +theorem eval_dataoffset (funs : FunEnv evm) (V : VEnv evm) (st : EvmState) (n : Ident) : + EvalExp...
{ "repo": "yul-semantics", "git_repo": "github.com/powdr-labs/yul-semantics", "revision": "f4e6187d684c0ebaee751750c5c368a4226abb73", "lean_toolchain": "leanprover/lean4:v4.31.0", "proof_assistant": "lean", "ablator": "ablators/lean (corollary-delete-lemmas-leaves-all)", "ablator_flags": [ "--corollar...