gdp-wired 0.48.0 → 0.49.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/dist/core/bmc.js +10 -7
- package/dist/core/check.js +7 -2
- package/dist/core/count-attempt-work.d.ts +29 -0
- package/dist/core/count-attempt-work.js +96 -0
- package/dist/core/count-boolean-partition.d.ts +5 -0
- package/dist/core/count-boolean-partition.js +47 -0
- package/dist/core/count-bounded-quotient.d.ts +2 -0
- package/dist/core/count-bounded-quotient.js +13 -0
- package/dist/core/count-case-compose.d.ts +20 -0
- package/dist/core/count-case-compose.js +289 -0
- package/dist/core/count-cases.js +3 -2
- package/dist/core/count-cert-rename.d.ts +10 -0
- package/dist/core/count-cert-rename.js +69 -0
- package/dist/core/count-cert-transport.d.ts +10 -2
- package/dist/core/count-cert-transport.js +60 -9
- package/dist/core/count-certificate-minimize.d.ts +57 -0
- package/dist/core/count-certificate-minimize.js +263 -0
- package/dist/core/count-closed-family.d.ts +32 -0
- package/dist/core/count-closed-family.js +143 -0
- package/dist/core/count-closing-budget.d.ts +10 -0
- package/dist/core/count-closing-budget.js +49 -0
- package/dist/core/count-closing-needs.d.ts +5 -0
- package/dist/core/count-closing-needs.js +9 -0
- package/dist/core/count-component-budget.d.ts +5 -0
- package/dist/core/count-component-budget.js +9 -0
- package/dist/core/count-copy-shape.d.ts +11 -0
- package/dist/core/count-copy-shape.js +40 -0
- package/dist/core/count-disjoint-funding.d.ts +75 -0
- package/dist/core/count-disjoint-funding.js +284 -0
- package/dist/core/count-emitter-frame-pool.d.ts +23 -0
- package/dist/core/count-emitter-frame-pool.js +87 -0
- package/dist/core/count-final-step.d.ts +5 -0
- package/dist/core/count-final-step.js +20 -0
- package/dist/core/count-fixed-frame.d.ts +4 -0
- package/dist/core/count-fixed-frame.js +30 -0
- package/dist/core/count-frames.d.ts +25 -0
- package/dist/core/count-frames.js +118 -0
- package/dist/core/count-frozen-guard.d.ts +2 -0
- package/dist/core/count-frozen-guard.js +31 -0
- package/dist/core/count-generation-phase.d.ts +7 -0
- package/dist/core/count-generation-phase.js +33 -0
- package/dist/core/count-guard-composition.d.ts +12 -0
- package/dist/core/count-guard-composition.js +48 -0
- package/dist/core/count-guard-context.d.ts +11 -0
- package/dist/core/count-guard-context.js +50 -0
- package/dist/core/count-guard-facts.d.ts +50 -0
- package/dist/core/count-guard-facts.js +97 -0
- package/dist/core/count-guard-proposals.d.ts +7 -0
- package/dist/core/count-guard-proposals.js +106 -0
- package/dist/core/count-guard-shape.d.ts +18 -0
- package/dist/core/count-guard-shape.js +100 -0
- package/dist/core/count-guard-tree.d.ts +17 -0
- package/dist/core/count-guard-tree.js +125 -0
- package/dist/core/count-leader-facts.d.ts +10 -0
- package/dist/core/count-leader-facts.js +52 -0
- package/dist/core/count-leader.d.ts +10 -0
- package/dist/core/count-leader.js +331 -0
- package/dist/core/count-lemma-transport.d.ts +8 -0
- package/dist/core/count-lemma-transport.js +47 -0
- package/dist/core/count-lifted-budget.d.ts +54 -0
- package/dist/core/count-lifted-budget.js +97 -0
- package/dist/core/count-lifted-copy.d.ts +3 -0
- package/dist/core/count-lifted-copy.js +166 -0
- package/dist/core/count-lifted-increment.d.ts +3 -0
- package/dist/core/count-lifted-increment.js +146 -0
- package/dist/core/count-lifted-load.d.ts +5 -0
- package/dist/core/count-lifted-load.js +179 -0
- package/dist/core/count-lifted-prerequisite.d.ts +14 -0
- package/dist/core/count-lifted-prerequisite.js +53 -0
- package/dist/core/count-lifted-replacement.d.ts +3 -0
- package/dist/core/count-lifted-replacement.js +540 -0
- package/dist/core/count-lifted-shape.d.ts +63 -0
- package/dist/core/count-lifted-shape.js +115 -0
- package/dist/core/count-lifted-strategy.d.ts +7 -0
- package/dist/core/count-lifted-strategy.js +226 -0
- package/dist/core/count-lifted-transports.d.ts +32 -0
- package/dist/core/count-lifted-transports.js +293 -0
- package/dist/core/count-load-shape.d.ts +17 -0
- package/dist/core/count-load-shape.js +67 -0
- package/dist/core/count-minimal-view.d.ts +26 -0
- package/dist/core/count-minimal-view.js +46 -0
- package/dist/core/count-operation-observation.d.ts +9 -0
- package/dist/core/count-operation-observation.js +22 -0
- package/dist/core/count-operation-order.d.ts +5 -0
- package/dist/core/count-operation-order.js +4 -0
- package/dist/core/count-phase.d.ts +9 -0
- package/dist/core/count-phase.js +127 -0
- package/dist/core/count-premise-search.d.ts +9 -0
- package/dist/core/count-premise-search.js +41 -0
- package/dist/core/count-premise-view.d.ts +19 -0
- package/dist/core/count-premise-view.js +220 -0
- package/dist/core/count-prerequisite-components.d.ts +67 -0
- package/dist/core/count-prerequisite-components.js +239 -0
- package/dist/core/count-prerequisite-memory.d.ts +24 -0
- package/dist/core/count-prerequisite-memory.js +37 -0
- package/dist/core/count-prerequisite-plan.d.ts +12 -0
- package/dist/core/count-prerequisite-plan.js +88 -0
- package/dist/core/count-primitive-budget.d.ts +1 -0
- package/dist/core/count-primitive-budget.js +8 -0
- package/dist/core/count-project-free.d.ts +3 -0
- package/dist/core/count-project-free.js +24 -0
- package/dist/core/count-project-witness.d.ts +4 -0
- package/dist/core/count-project-witness.js +48 -0
- package/dist/core/count-proof-rescope.d.ts +14 -0
- package/dist/core/count-proof-rescope.js +71 -0
- package/dist/core/count-proof-scope.d.ts +68 -0
- package/dist/core/count-proof-scope.js +333 -0
- package/dist/core/count-prune-owned-root.d.ts +5 -0
- package/dist/core/count-prune-owned-root.js +27 -0
- package/dist/core/count-query-context.d.ts +3 -0
- package/dist/core/count-query-context.js +7 -0
- package/dist/core/count-query.d.ts +15 -0
- package/dist/core/count-query.js +59 -0
- package/dist/core/count-quorum-leaf.d.ts +9 -0
- package/dist/core/count-quorum-leaf.js +38 -0
- package/dist/core/count-reachability-budget.d.ts +1 -0
- package/dist/core/count-reachability-budget.js +7 -0
- package/dist/core/count-reachability-reconcile.d.ts +11 -0
- package/dist/core/count-reachability-reconcile.js +19 -0
- package/dist/core/count-reachability.d.ts +50 -0
- package/dist/core/count-reachability.js +351 -0
- package/dist/core/count-rebase-path.d.ts +9 -0
- package/dist/core/count-rebase-path.js +68 -0
- package/dist/core/count-recipe-context.d.ts +45 -0
- package/dist/core/count-recipe-context.js +71 -0
- package/dist/core/count-recipe-controller.d.ts +115 -0
- package/dist/core/count-recipe-controller.js +417 -0
- package/dist/core/count-recipe-graph.d.ts +36 -0
- package/dist/core/count-recipe-graph.js +211 -0
- package/dist/core/count-recovery/conditional-check-cache.js +3 -2
- package/dist/core/count-recovery/conditional-cuts.js +5 -4
- package/dist/core/count-recovery/conditional-proof.d.ts +37 -3
- package/dist/core/count-recovery/conditional-proof.js +72 -30
- package/dist/core/count-recovery/derivability-closure.js +2 -1
- package/dist/core/count-recovery/guard-cases.js +2 -1
- package/dist/core/count-recovery/reframe-tree.d.ts +2 -0
- package/dist/core/count-recovery/reframe-tree.js +24 -0
- package/dist/core/count-recovery/replay-linear-skeleton.d.ts +2 -0
- package/dist/core/count-recovery/replay-linear-skeleton.js +28 -0
- package/dist/core/count-recovery/row-cases.js +2 -1
- package/dist/core/count-rejection-budget.d.ts +8 -0
- package/dist/core/count-rejection-budget.js +15 -0
- package/dist/core/count-replacement.d.ts +5 -0
- package/dist/core/count-replacement.js +129 -0
- package/dist/core/count-replay-diagnostic.d.ts +21 -0
- package/dist/core/count-replay-diagnostic.js +49 -0
- package/dist/core/count-replay-skeleton.d.ts +4 -0
- package/dist/core/count-replay-skeleton.js +28 -0
- package/dist/core/count-rescope-funding.d.ts +3 -0
- package/dist/core/count-rescope-funding.js +17 -0
- package/dist/core/count-restrictions.d.ts +11 -0
- package/dist/core/count-restrictions.js +31 -0
- package/dist/core/count-retry-budget.d.ts +67 -0
- package/dist/core/count-retry-budget.js +114 -0
- package/dist/core/count-retry-round.d.ts +24 -0
- package/dist/core/count-retry-round.js +44 -0
- package/dist/core/count-row-agreement.d.ts +35 -0
- package/dist/core/count-row-agreement.js +270 -0
- package/dist/core/count-row-aliases.d.ts +3 -0
- package/dist/core/count-row-aliases.js +59 -0
- package/dist/core/count-row-composition.d.ts +6 -0
- package/dist/core/count-row-composition.js +55 -0
- package/dist/core/count-row-copy-linear.d.ts +4 -0
- package/dist/core/count-row-copy-linear.js +83 -0
- package/dist/core/count-row-copy.d.ts +4 -0
- package/dist/core/count-row-copy.js +94 -0
- package/dist/core/count-row-policy.d.ts +3 -0
- package/dist/core/count-row-policy.js +56 -0
- package/dist/core/count-row-reindex.d.ts +11 -0
- package/dist/core/count-row-reindex.js +126 -0
- package/dist/core/count-row-support.d.ts +9 -0
- package/dist/core/count-row-support.js +42 -0
- package/dist/core/count-row-symmetry.d.ts +7 -0
- package/dist/core/count-row-symmetry.js +100 -0
- package/dist/core/count-scope-hyps.d.ts +2 -0
- package/dist/core/count-scope-hyps.js +163 -0
- package/dist/core/count-scope-row-reuse.d.ts +3 -0
- package/dist/core/count-scope-row-reuse.js +92 -0
- package/dist/core/count-search-allowance.d.ts +1 -0
- package/dist/core/count-search-allowance.js +17 -0
- package/dist/core/count-stabilize-tree.d.ts +9 -0
- package/dist/core/count-stabilize-tree.js +35 -0
- package/dist/core/count-stage-trace.d.ts +8 -0
- package/dist/core/count-stage-trace.js +45 -0
- package/dist/core/count-strategies.d.ts +16 -0
- package/dist/core/count-strategies.js +155 -0
- package/dist/core/count-strategy-premises.d.ts +5 -0
- package/dist/core/count-strategy-premises.js +14 -0
- package/dist/core/count-strategy.d.ts +41 -0
- package/dist/core/count-strategy.js +76 -0
- package/dist/core/count-support.js +3 -2
- package/dist/core/count-tier-budget.d.ts +14 -0
- package/dist/core/count-tier-budget.js +64 -0
- package/dist/core/count-unwritten-prefix.d.ts +24 -0
- package/dist/core/count-unwritten-prefix.js +97 -0
- package/dist/core/count-write-shape.d.ts +15 -0
- package/dist/core/count-write-shape.js +73 -0
- package/dist/core/counts.d.ts +37 -13
- package/dist/core/counts.js +990 -127
- package/dist/core/cycles.js +5 -4
- package/dist/core/cyclic.js +11 -10
- package/dist/core/data.js +16 -15
- package/dist/core/dsl-deadline.d.ts +3 -0
- package/dist/core/dsl-deadline.js +27 -0
- package/dist/core/dsl.d.ts +9 -0
- package/dist/core/dsl.js +156 -51
- package/dist/core/evaluation-admission.d.ts +1 -0
- package/dist/core/evaluation-admission.js +3 -0
- package/dist/core/exists.d.ts +6 -1
- package/dist/core/exists.js +51 -9
- package/dist/core/field-laws.d.ts +3 -1
- package/dist/core/field-laws.js +140 -2
- package/dist/core/finite-houdini.d.ts +6 -0
- package/dist/core/finite-houdini.js +63 -21
- package/dist/core/finite-tiny.js +95 -67
- package/dist/core/fixtures/count-completion/paxos-decision.json +1 -0
- package/dist/core/fresh.js +5 -1
- package/dist/core/infer.js +45 -30
- package/dist/core/kind.js +2 -1
- package/dist/core/lemma-cuts.js +11 -10
- package/dist/core/linear-admission.d.ts +14 -0
- package/dist/core/linear-admission.js +151 -0
- package/dist/core/machine.d.ts +5 -2
- package/dist/core/machine.js +105 -31
- package/dist/core/meter.d.ts +22 -0
- package/dist/core/meter.js +34 -0
- package/dist/core/nonterm.js +4 -3
- package/dist/core/prover-row-budget.d.ts +3 -0
- package/dist/core/prover-row-budget.js +106 -0
- package/dist/core/quorum-laws.d.ts +21 -1
- package/dist/core/quorum-laws.js +27 -3
- package/dist/core/rationals.js +3 -2
- package/dist/core/rejection-discovery.d.ts +34 -0
- package/dist/core/rejection-discovery.js +36 -0
- package/dist/core/rejection-stage.d.ts +39 -0
- package/dist/core/rejection-stage.js +205 -0
- package/dist/core/request-quotient.d.ts +8 -0
- package/dist/core/request-quotient.js +299 -0
- package/dist/core/row-agreement-shape.d.ts +15 -0
- package/dist/core/row-agreement-shape.js +68 -0
- package/dist/core/runtime-wall.d.ts +2 -0
- package/dist/core/search-policy.d.ts +15 -0
- package/dist/core/search-policy.js +68 -0
- package/dist/core/solver.d.ts +1 -1
- package/dist/core/solver.js +40 -6
- package/dist/core/step-work.d.ts +12 -0
- package/dist/core/step-work.js +14 -0
- package/dist/core/strategy-premises.d.ts +8 -0
- package/dist/core/strategy-premises.js +64 -0
- package/dist/core/system.js +4 -3
- package/dist/core/table-admission.d.ts +1 -0
- package/dist/core/table-admission.js +3 -0
- package/dist/core/trace-clock.d.ts +3 -0
- package/dist/core/trace-clock.js +16 -0
- package/dist/core/transfer.js +3 -2
- package/dist/core/translate.js +16 -3
- package/dist/core/wall.d.ts +6 -1
- package/dist/core/wall.js +23 -9
- package/dist/core/watch.d.ts +1 -1
- package/dist/core/watch.js +13 -4
- package/dist/core/work-admission.d.ts +164 -0
- package/dist/core/work-admission.js +418 -0
- package/dist/core/work-amount.d.ts +21 -0
- package/dist/core/work-amount.js +80 -0
- package/dist/core/work-collections.d.ts +11 -0
- package/dist/core/work-collections.js +198 -0
- package/dist/core/work-kinds.d.ts +11 -0
- package/dist/core/work-kinds.js +9 -0
- package/dist/core/work-meter.d.ts +8 -0
- package/dist/core/work-meter.js +83 -0
- package/dist/core/work-observe.d.ts +12 -0
- package/dist/core/work-observe.js +39 -0
- package/dist/core/work-profile.d.ts +10 -0
- package/dist/core/work-profile.js +21 -0
- package/dist/core/work-refusal.d.ts +1 -0
- package/dist/core/work-refusal.js +6 -0
- package/dist/interchange/format.js +2 -0
- package/dist/kernel/cdcl.js +93 -40
- package/dist/kernel/epr.js +23 -8
- package/dist/kernel/kernel.d.ts +47 -1
- package/dist/kernel/kernel.js +417 -68
- package/dist/kernel/prove.d.ts +49 -3
- package/dist/kernel/prove.js +468 -122
- package/dist/kernel/prover-rows.d.ts +1 -0
- package/dist/kernel/prover-rows.js +12 -1
- package/dist/kernel/reader.d.ts +1 -1
- package/dist/kernel/reader.js +57 -12
- package/dist/kernel/simplex.js +9 -2
- package/dist/lean-kernel/emit.d.ts +9 -1
- package/dist/lean-kernel/emit.js +144 -22
- package/dist/lean-kernel/legacy-family-library.d.ts +1 -0
- package/dist/lean-kernel/legacy-family-library.js +5 -0
- package/dist/lean-kernel/library.js +3 -3
- package/package.json +1 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"schema":1,"source":"97463c564351448373ca49f6af980b31b1a0f0c5","m":{"name":"paxos epr","params":["none","size"],"inputs":["op","n","r","v","maxr","w"],"state":{"busy":{"op":"const","value":0},"cnt":{"op":"const","value":0},"pr":{"op":"const","value":0},"pmaxr":{"op":"const","value":0},"pv":{"op":"const","value":0}},"maps":{"OneA":0,"OneB":0,"Left":0,"Proposal":0,"Vote":0,"Decision":0,"Qs":0},"inputMaps":["Q"],"counts":{"members":{"j":"members$x","key":"members$k","below":{"op":"var","name":"size"},"body":{"op":"if","c":{"op":"<=","a":{"op":"const","value":1},"b":{"op":"get","map":"Q","key":{"op":"var","name":"members$k"}}},"then":{"op":"const","value":1},"else":{"op":"const","value":0}}},"missing":{"j":"missing$x","key":"missing$k","below":{"op":"var","name":"size"},"body":{"op":"if","c":{"op":"and","xs":[{"op":"<=","a":{"op":"const","value":1},"b":{"op":"get","map":"Q","key":{"op":"var","name":"missing$k"}}},{"op":"not","x":{"op":"=","a":{"op":"get","map":"Vote","key":{"op":"add","a":{"op":"add","a":{"op":"mul","k":4096,"a":{"op":"var","name":"missing$k"}},"b":{"op":"mul","k":64,"a":{"op":"var","name":"r"}}},"b":{"op":"var","name":"v"}}},"b":{"op":"const","value":1}}}]},"then":{"op":"const","value":1},"else":{"op":"const","value":0}}},"members$Qs":{"j":"members$Qs$x","key":"members$Qs$k","below":{"op":"var","name":"size"},"body":{"op":"if","c":{"op":"=","a":{"op":"get","map":"Qs","key":{"op":"var","name":"members$Qs$k"}},"b":{"op":"const","value":1}},"then":{"op":"const","value":1},"else":{"op":"const","value":0}}},"members$Decision":{"j":"members$Decision$x","key":"members$Decision$k","below":{"op":"var","name":"size"},"body":{"op":"if","c":{"op":"=","a":{"op":"get","map":"Vote","key":{"op":"add","a":{"op":"add","a":{"op":"mul","k":4096,"a":{"op":"var","name":"members$Decision$k"}},"b":{"op":"mul","k":64,"a":{"op":"var","name":"members$Decision$x"}}},"b":{"op":"var","name":"members$Decision$y"}}},"b":{"op":"const","value":1}},"then":{"op":"const","value":1},"else":{"op":"const","value":0}},"lo":"members$Decision$y","base":64},"can$Vote$members":{"j":"can$Vote$members$x","key":"can$Vote$members$k","lo":"can$Vote$members$y","base":64,"below":{"op":"var","name":"size"},"body":{"op":"if","c":{"op":"or","xs":[{"op":"and","xs":[{"op":"not","x":{"op":"=","a":{"op":"get","map":"Left","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"can$Vote$members$k"}},"b":{"op":"var","name":"can$Vote$members$x"}}},"b":{"op":"const","value":1}}}]},{"op":"<=","a":{"op":"const","value":1},"b":{"op":"get","map":"Vote","key":{"op":"add","a":{"op":"add","a":{"op":"mul","k":4096,"a":{"op":"var","name":"can$Vote$members$k"}},"b":{"op":"mul","k":64,"a":{"op":"var","name":"can$Vote$members$x"}}},"b":{"op":"var","name":"can$Vote$members$y"}}}}]},"then":{"op":"const","value":1},"else":{"op":"const","value":0}}}},"step":{"flags":{"noProposal":{"op":"all","key":"k$19","c":{"op":"or","xs":[{"op":"not","x":{"op":"<","a":{"op":"var","name":"k$19"},"b":{"op":"const","value":64}}},{"op":"not","x":{"op":"=","a":{"op":"get","map":"Proposal","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"r"}},"b":{"op":"var","name":"k$19"}}},"b":{"op":"const","value":1}}}]}},"joined":{"op":"all","key":"k$20","c":{"op":"or","xs":[{"op":"not","x":{"op":"<=","a":{"op":"const","value":1},"b":{"op":"get","map":"Q","key":{"op":"var","name":"k$20"}}}},{"op":"=","a":{"op":"get","map":"OneB","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"r"}},"b":{"op":"var","name":"k$20"}}},"b":{"op":"const","value":1}}]}},"rowOk":{"op":"all","key":"k$21","c":{"op":"or","xs":[{"op":"not","x":{"op":"and","xs":[{"op":"=","a":{"op":"get","map":"Vote","key":{"op":"add","a":{"op":"mul","k":4096,"a":{"op":"var","name":"cnt"}},"b":{"op":"var","name":"k$21"}}},"b":{"op":"const","value":1}},{"op":"<","a":{"op":"var","name":"k$21"},"b":{"op":"mul","k":64,"a":{"op":"var","name":"pr"}}}]}},{"op":"and","xs":[{"op":"not","x":{"op":"=","a":{"op":"var","name":"pmaxr"},"b":{"op":"var","name":"none"}}},{"op":"<","a":{"op":"var","name":"k$21"},"b":{"op":"mul","k":64,"a":{"op":"add","a":{"op":"var","name":"pmaxr"},"b":{"op":"const","value":1}}}}]}]}},"sends":{"op":"and","xs":[{"op":"=","a":{"op":"var","name":"op"},"b":{"op":"const","value":0}},{"op":"and","xs":[{"op":"=","a":{"op":"var","name":"busy"},"b":{"op":"const","value":0}},{"op":"not","x":{"op":"=","a":{"op":"var","name":"r"},"b":{"op":"var","name":"none"}}}]}]},"joins":{"op":"and","xs":[{"op":"=","a":{"op":"var","name":"op"},"b":{"op":"const","value":1}},{"op":"and","xs":[{"op":"=","a":{"op":"var","name":"busy"},"b":{"op":"const","value":0}},{"op":"not","x":{"op":"=","a":{"op":"var","name":"r"},"b":{"op":"var","name":"none"}}}]},{"op":"=","a":{"op":"get","map":"OneA","key":{"op":"var","name":"r"}},"b":{"op":"const","value":1}},{"op":"not","x":{"op":"=","a":{"op":"get","map":"Left","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"n"}},"b":{"op":"var","name":"r"}}},"b":{"op":"const","value":1}}}]},"proposes":{"op":"and","xs":[{"op":"=","a":{"op":"var","name":"op"},"b":{"op":"const","value":2}},{"op":"and","xs":[{"op":"=","a":{"op":"var","name":"busy"},"b":{"op":"const","value":0}},{"op":"not","x":{"op":"=","a":{"op":"var","name":"r"},"b":{"op":"var","name":"none"}}}]},{"op":"flag","name":"noProposal"},{"op":"flag","name":"joined"},{"op":"or","xs":[{"op":"=","a":{"op":"var","name":"maxr"},"b":{"op":"var","name":"none"}},{"op":"and","xs":[{"op":"<=","a":{"op":"const","value":1},"b":{"op":"get","map":"Q","key":{"op":"var","name":"w"}}},{"op":"<","a":{"op":"var","name":"maxr"},"b":{"op":"var","name":"r"}},{"op":"=","a":{"op":"get","map":"Vote","key":{"op":"add","a":{"op":"add","a":{"op":"mul","k":4096,"a":{"op":"var","name":"w"}},"b":{"op":"mul","k":64,"a":{"op":"var","name":"maxr"}}},"b":{"op":"var","name":"v"}}},"b":{"op":"const","value":1}}]}]}]},"checks":{"op":"and","xs":[{"op":"=","a":{"op":"var","name":"op"},"b":{"op":"const","value":3}},{"op":"=","a":{"op":"var","name":"busy"},"b":{"op":"const","value":1}}]},"fails":{"op":"and","xs":[{"op":"and","xs":[{"op":"=","a":{"op":"var","name":"op"},"b":{"op":"const","value":3}},{"op":"=","a":{"op":"var","name":"busy"},"b":{"op":"const","value":1}}]},{"op":"=","a":{"op":"get","map":"Qs","key":{"op":"var","name":"cnt"}},"b":{"op":"const","value":1}},{"op":"not","x":{"op":"flag","name":"rowOk"}}]},"commits":{"op":"and","xs":[{"op":"and","xs":[{"op":"=","a":{"op":"var","name":"op"},"b":{"op":"const","value":3}},{"op":"=","a":{"op":"var","name":"busy"},"b":{"op":"const","value":1}}]},{"op":"not","x":{"op":"and","xs":[{"op":"and","xs":[{"op":"=","a":{"op":"var","name":"op"},"b":{"op":"const","value":3}},{"op":"=","a":{"op":"var","name":"busy"},"b":{"op":"const","value":1}}]},{"op":"=","a":{"op":"get","map":"Qs","key":{"op":"var","name":"cnt"}},"b":{"op":"const","value":1}},{"op":"not","x":{"op":"flag","name":"rowOk"}}]}},{"op":"=","a":{"op":"add","a":{"op":"var","name":"cnt"},"b":{"op":"const","value":1}},"b":{"op":"var","name":"size"}}]},"casts":{"op":"and","xs":[{"op":"=","a":{"op":"var","name":"op"},"b":{"op":"const","value":4}},{"op":"and","xs":[{"op":"=","a":{"op":"var","name":"busy"},"b":{"op":"const","value":0}},{"op":"not","x":{"op":"=","a":{"op":"var","name":"r"},"b":{"op":"var","name":"none"}}}]},{"op":"not","x":{"op":"=","a":{"op":"get","map":"Left","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"n"}},"b":{"op":"var","name":"r"}}},"b":{"op":"const","value":1}}},{"op":"=","a":{"op":"get","map":"Proposal","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"r"}},"b":{"op":"var","name":"v"}}},"b":{"op":"const","value":1}}]},"decides":{"op":"and","xs":[{"op":"=","a":{"op":"var","name":"op"},"b":{"op":"const","value":5}},{"op":"and","xs":[{"op":"=","a":{"op":"var","name":"busy"},"b":{"op":"const","value":0}},{"op":"not","x":{"op":"=","a":{"op":"var","name":"r"},"b":{"op":"var","name":"none"}}}]},{"op":"=","a":{"op":"get","map":"missing","key":{"op":"const","value":0}},"b":{"op":"const","value":0}}]},"all$1":{"op":"all","key":"k$24","c":{"op":"and","xs":[{"op":"<=","a":{"op":"get","map":"Q","key":{"op":"var","name":"k$24"}},"b":{"op":"const","value":1}},{"op":"or","xs":[{"op":"not","x":{"op":"<=","a":{"op":"const","value":1},"b":{"op":"get","map":"Q","key":{"op":"var","name":"k$24"}}}},{"op":"<","a":{"op":"var","name":"k$24"},"b":{"op":"var","name":"size"}}]}]}}},"state":{"busy":{"op":"if","c":{"op":"flag","name":"proposes"},"then":{"op":"const","value":1},"else":{"op":"if","c":{"op":"or","xs":[{"op":"flag","name":"fails"},{"op":"flag","name":"commits"}]},"then":{"op":"const","value":0},"else":{"op":"var","name":"busy"}}},"cnt":{"op":"if","c":{"op":"and","xs":[{"op":"flag","name":"checks"},{"op":"not","x":{"op":"or","xs":[{"op":"flag","name":"fails"},{"op":"flag","name":"commits"}]}}]},"then":{"op":"add","a":{"op":"var","name":"cnt"},"b":{"op":"const","value":1}},"else":{"op":"if","c":{"op":"or","xs":[{"op":"flag","name":"fails"},{"op":"flag","name":"commits"}]},"then":{"op":"const","value":0},"else":{"op":"var","name":"cnt"}}},"pr":{"op":"if","c":{"op":"flag","name":"proposes"},"then":{"op":"var","name":"r"},"else":{"op":"if","c":{"op":"or","xs":[{"op":"flag","name":"fails"},{"op":"flag","name":"commits"}]},"then":{"op":"const","value":0},"else":{"op":"var","name":"pr"}}},"pmaxr":{"op":"if","c":{"op":"flag","name":"proposes"},"then":{"op":"var","name":"maxr"},"else":{"op":"if","c":{"op":"or","xs":[{"op":"flag","name":"fails"},{"op":"flag","name":"commits"}]},"then":{"op":"const","value":0},"else":{"op":"var","name":"pmaxr"}}},"pv":{"op":"if","c":{"op":"flag","name":"proposes"},"then":{"op":"var","name":"v"},"else":{"op":"if","c":{"op":"or","xs":[{"op":"flag","name":"fails"},{"op":"flag","name":"commits"}]},"then":{"op":"const","value":0},"else":{"op":"var","name":"pv"}}}},"maps":{"Qs":{"each":"k$22","value":{"op":"if","c":{"op":"or","xs":[{"op":"and","xs":[{"op":"flag","name":"proposes"},{"op":"<=","a":{"op":"const","value":1},"b":{"op":"get","map":"Q","key":{"op":"var","name":"k$22"}}}]},{"op":"and","xs":[{"op":"not","x":{"op":"flag","name":"proposes"}},{"op":"or","xs":[{"op":"and","xs":[{"op":"or","xs":[{"op":"flag","name":"fails"},{"op":"flag","name":"commits"}]},{"op":"<","a":{"op":"const","value":0},"b":{"op":"const","value":0}}]},{"op":"and","xs":[{"op":"not","x":{"op":"or","xs":[{"op":"flag","name":"fails"},{"op":"flag","name":"commits"}]}},{"op":"=","a":{"op":"get","map":"Qs","key":{"op":"var","name":"k$22"}},"b":{"op":"const","value":1}}]}]}]}]},"then":{"op":"const","value":1},"else":{"op":"const","value":0}}},"OneA":{"key":{"op":"var","name":"r"},"value":{"op":"if","c":{"op":"or","xs":[{"op":"and","xs":[{"op":"flag","name":"sends"},{"op":"<=","a":{"op":"const","value":0},"b":{"op":"const","value":0}}]},{"op":"and","xs":[{"op":"not","x":{"op":"flag","name":"sends"}},{"op":"=","a":{"op":"get","map":"OneA","key":{"op":"var","name":"r"}},"b":{"op":"const","value":1}}]}]},"then":{"op":"const","value":1},"else":{"op":"const","value":0}}},"OneB":{"key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"r"}},"b":{"op":"var","name":"n"}},"value":{"op":"if","c":{"op":"or","xs":[{"op":"and","xs":[{"op":"flag","name":"joins"},{"op":"<=","a":{"op":"const","value":0},"b":{"op":"const","value":0}}]},{"op":"and","xs":[{"op":"not","x":{"op":"flag","name":"joins"}},{"op":"=","a":{"op":"get","map":"OneB","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"r"}},"b":{"op":"var","name":"n"}}},"b":{"op":"const","value":1}}]}]},"then":{"op":"const","value":1},"else":{"op":"const","value":0}}},"Left":{"each":"k$23","value":{"op":"if","c":{"op":"or","xs":[{"op":"and","xs":[{"op":"and","xs":[{"op":"flag","name":"joins"},{"op":"<=","a":{"op":"mul","k":64,"a":{"op":"var","name":"n"}},"b":{"op":"var","name":"k$23"}},{"op":"<","a":{"op":"var","name":"k$23"},"b":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"n"}},"b":{"op":"var","name":"r"}}}]},{"op":"<=","a":{"op":"const","value":0},"b":{"op":"const","value":0}}]},{"op":"and","xs":[{"op":"not","x":{"op":"and","xs":[{"op":"flag","name":"joins"},{"op":"<=","a":{"op":"mul","k":64,"a":{"op":"var","name":"n"}},"b":{"op":"var","name":"k$23"}},{"op":"<","a":{"op":"var","name":"k$23"},"b":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"n"}},"b":{"op":"var","name":"r"}}}]}},{"op":"=","a":{"op":"get","map":"Left","key":{"op":"var","name":"k$23"}},"b":{"op":"const","value":1}}]}]},"then":{"op":"const","value":1},"else":{"op":"const","value":0}}},"Proposal":{"key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"pr"}},"b":{"op":"var","name":"pv"}},"value":{"op":"if","c":{"op":"or","xs":[{"op":"and","xs":[{"op":"flag","name":"commits"},{"op":"<=","a":{"op":"const","value":0},"b":{"op":"const","value":0}}]},{"op":"and","xs":[{"op":"not","x":{"op":"flag","name":"commits"}},{"op":"=","a":{"op":"get","map":"Proposal","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"pr"}},"b":{"op":"var","name":"pv"}}},"b":{"op":"const","value":1}}]}]},"then":{"op":"const","value":1},"else":{"op":"const","value":0}}},"Vote":{"key":{"op":"add","a":{"op":"add","a":{"op":"mul","k":4096,"a":{"op":"var","name":"n"}},"b":{"op":"mul","k":64,"a":{"op":"var","name":"r"}}},"b":{"op":"var","name":"v"}},"value":{"op":"if","c":{"op":"or","xs":[{"op":"and","xs":[{"op":"flag","name":"casts"},{"op":"<=","a":{"op":"const","value":0},"b":{"op":"const","value":0}}]},{"op":"and","xs":[{"op":"not","x":{"op":"flag","name":"casts"}},{"op":"=","a":{"op":"get","map":"Vote","key":{"op":"add","a":{"op":"add","a":{"op":"mul","k":4096,"a":{"op":"var","name":"n"}},"b":{"op":"mul","k":64,"a":{"op":"var","name":"r"}}},"b":{"op":"var","name":"v"}}},"b":{"op":"const","value":1}}]}]},"then":{"op":"const","value":1},"else":{"op":"const","value":0}}},"Decision":{"key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"r"}},"b":{"op":"var","name":"v"}},"value":{"op":"if","c":{"op":"or","xs":[{"op":"and","xs":[{"op":"flag","name":"decides"},{"op":"<=","a":{"op":"const","value":0},"b":{"op":"const","value":0}}]},{"op":"and","xs":[{"op":"not","x":{"op":"flag","name":"decides"}},{"op":"=","a":{"op":"get","map":"Decision","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"r"}},"b":{"op":"var","name":"v"}}},"b":{"op":"const","value":1}}]}]},"then":{"op":"const","value":1},"else":{"op":"const","value":0}}}}},"pre":{"op":"and","xs":[{"op":"<","a":{"op":"var","name":"none"},"b":{"op":"const","value":64}},{"op":"<=","a":{"op":"var","name":"size"},"b":{"op":"const","value":64}}]},"assume":{"op":"and","xs":[{"op":"<","a":{"op":"var","name":"op"},"b":{"op":"const","value":6}},{"op":"and","xs":[{"op":"and","xs":[{"op":"<","a":{"op":"var","name":"n"},"b":{"op":"var","name":"size"}},{"op":"<","a":{"op":"var","name":"w"},"b":{"op":"var","name":"size"}},{"op":"and","xs":[{"op":"and","xs":[{"op":"<","a":{"op":"var","name":"r"},"b":{"op":"const","value":64}},{"op":"<","a":{"op":"var","name":"v"},"b":{"op":"const","value":64}}]},{"op":"<","a":{"op":"var","name":"maxr"},"b":{"op":"const","value":64}}]}]},{"op":"or","xs":[{"op":"not","x":{"op":"or","xs":[{"op":"=","a":{"op":"var","name":"op"},"b":{"op":"const","value":2}},{"op":"=","a":{"op":"var","name":"op"},"b":{"op":"const","value":5}}]}},{"op":"and","xs":[{"op":"flag","name":"all$1"},{"op":"<","a":{"op":"var","name":"size"},"b":{"op":"mul","k":2,"a":{"op":"get","map":"members","key":{"op":"const","value":0}}}}]}]}]}]}},"laws":[{"name":"every OneA cell is a value of its kind","forall":"key$7","holds":{"op":"<=","a":{"op":"get","map":"OneA","key":{"op":"var","name":"key$7"}},"b":{"op":"const","value":1}}},{"name":"every OneB cell is a value of its kind","forall":"key$9","holds":{"op":"<=","a":{"op":"get","map":"OneB","key":{"op":"var","name":"key$9"}},"b":{"op":"const","value":1}}},{"name":"every Left cell is a value of its kind","forall":"key$11","holds":{"op":"<=","a":{"op":"get","map":"Left","key":{"op":"var","name":"key$11"}},"b":{"op":"const","value":1}}},{"name":"every Proposal cell is a value of its kind","forall":"key$13","holds":{"op":"<=","a":{"op":"get","map":"Proposal","key":{"op":"var","name":"key$13"}},"b":{"op":"const","value":1}}},{"name":"every Vote cell is a value of its kind","forall":"key$15","holds":{"op":"<=","a":{"op":"get","map":"Vote","key":{"op":"var","name":"key$15"}},"b":{"op":"const","value":1}}},{"name":"every Decision cell is a value of its kind","forall":"key$17","holds":{"op":"<=","a":{"op":"get","map":"Decision","key":{"op":"var","name":"key$17"}},"b":{"op":"const","value":1}}},{"name":"every Qs cell is a value of its kind","forall":"key$19","holds":{"op":"<=","a":{"op":"get","map":"Qs","key":{"op":"var","name":"key$19"}},"b":{"op":"const","value":1}}},{"name":"one value decided","forall":"key$2","keys":["key$3","key$4","key$5"],"holds":{"op":"or","xs":[{"op":"not","x":{"op":"and","xs":[{"op":"and","xs":[{"op":"and","xs":[{"op":"and","xs":[{"op":"<","a":{"op":"var","name":"key$2"},"b":{"op":"const","value":64}},{"op":"<","a":{"op":"var","name":"key$3"},"b":{"op":"const","value":64}}]},{"op":"<","a":{"op":"var","name":"key$4"},"b":{"op":"const","value":64}}]},{"op":"<","a":{"op":"var","name":"key$5"},"b":{"op":"const","value":64}}]},{"op":"=","a":{"op":"get","map":"Decision","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"key$2"}},"b":{"op":"var","name":"key$3"}}},"b":{"op":"const","value":1}},{"op":"=","a":{"op":"get","map":"Decision","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"key$4"}},"b":{"op":"var","name":"key$5"}}},"b":{"op":"const","value":1}}]}},{"op":"=","a":{"op":"var","name":"key$3"},"b":{"op":"var","name":"key$5"}}]}},{"name":"members$Qs keeps members's bound 0","forall":"a$c","holds":{"op":"or","xs":[{"op":"not","x":{"op":"=","a":{"op":"get","map":"Qs","key":{"op":"var","name":"a$c"}},"b":{"op":"const","value":1}}},{"op":"<","a":{"op":"var","name":"size"},"b":{"op":"mul","k":2,"a":{"op":"get","map":"members$Qs","key":{"op":"var","name":"a$c"}}}}]}},{"name":"members$Qs keeps members's bound 2","forall":"a$c","holds":{"op":"or","xs":[{"op":"not","x":{"op":"=","a":{"op":"var","name":"busy"},"b":{"op":"const","value":1}}},{"op":"<","a":{"op":"var","name":"size"},"b":{"op":"mul","k":2,"a":{"op":"get","map":"members$Qs","key":{"op":"var","name":"a$c"}}}}]}},{"name":"Decision keeps members's bound through members$Decision","forall":"a$c","keys":["b$c"],"holds":{"op":"or","xs":[{"op":"not","x":{"op":"and","xs":[{"op":"<=","a":{"op":"const","value":1},"b":{"op":"get","map":"Decision","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"a$c"}},"b":{"op":"var","name":"b$c"}}}},{"op":"<","a":{"op":"var","name":"b$c"},"b":{"op":"const","value":64}}]}},{"op":"<","a":{"op":"var","name":"size"},"b":{"op":"mul","k":2,"a":{"op":"get","map":"members$Decision","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"a$c"}},"b":{"op":"var","name":"b$c"}}}}}]}},{"name":"Proposal at (c, d) bounds can$Vote$members at (a, b): a < c, b ≠ d","forall":"a$c","keys":["b$c","c$c","d$c"],"holds":{"op":"or","xs":[{"op":"not","x":{"op":"and","xs":[{"op":"<=","a":{"op":"const","value":1},"b":{"op":"get","map":"Proposal","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"c$c"}},"b":{"op":"var","name":"d$c"}}}},{"op":"<","a":{"op":"var","name":"a$c"},"b":{"op":"var","name":"c$c"}},{"op":"not","x":{"op":"=","a":{"op":"var","name":"b$c"},"b":{"op":"var","name":"d$c"}}},{"op":"<","a":{"op":"var","name":"b$c"},"b":{"op":"const","value":64}},{"op":"<","a":{"op":"var","name":"d$c"},"b":{"op":"const","value":64}}]}},{"op":"not","x":{"op":"<","a":{"op":"var","name":"size"},"b":{"op":"mul","k":2,"a":{"op":"get","map":"can$Vote$members","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"a$c"}},"b":{"op":"var","name":"b$c"}}}}}}]}},{"name":"Proposal at (c, d) bounds can$Vote$members at (a, b): a < c","forall":"a$c","keys":["b$c","c$c","d$c"],"holds":{"op":"or","xs":[{"op":"not","x":{"op":"and","xs":[{"op":"<=","a":{"op":"const","value":1},"b":{"op":"get","map":"Proposal","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"c$c"}},"b":{"op":"var","name":"d$c"}}}},{"op":"<","a":{"op":"var","name":"a$c"},"b":{"op":"var","name":"c$c"}},{"op":"<","a":{"op":"var","name":"b$c"},"b":{"op":"const","value":64}},{"op":"<","a":{"op":"var","name":"d$c"},"b":{"op":"const","value":64}}]}},{"op":"not","x":{"op":"<","a":{"op":"var","name":"size"},"b":{"op":"mul","k":2,"a":{"op":"get","map":"can$Vote$members","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"a$c"}},"b":{"op":"var","name":"b$c"}}}}}}]}},{"name":"scan-prefix:cnt:rowOk:d93992f463f488aa:entry","holds":{"op":"or","xs":[{"op":"not","x":{"op":"=","a":{"op":"var","name":"busy"},"b":{"op":"const","value":0}}},{"op":"=","a":{"op":"var","name":"cnt"},"b":{"op":"const","value":0}}]}},{"name":"scan-prefix:cnt:rowOk:d93992f463f488aa","forall":"scanKey","keys":["k$21"],"holds":{"op":"or","xs":[{"op":"not","x":{"op":"and","xs":[{"op":"=","a":{"op":"var","name":"busy"},"b":{"op":"const","value":1}},{"op":"<","a":{"op":"var","name":"scanKey"},"b":{"op":"var","name":"cnt"}},{"op":"=","a":{"op":"get","map":"Qs","key":{"op":"var","name":"scanKey"}},"b":{"op":"const","value":1}}]}},{"op":"or","xs":[{"op":"not","x":{"op":"and","xs":[{"op":"=","a":{"op":"get","map":"Vote","key":{"op":"add","a":{"op":"mul","k":4096,"a":{"op":"var","name":"scanKey"}},"b":{"op":"var","name":"k$21"}}},"b":{"op":"const","value":1}},{"op":"<","a":{"op":"var","name":"k$21"},"b":{"op":"mul","k":64,"a":{"op":"var","name":"pr"}}}]}},{"op":"and","xs":[{"op":"not","x":{"op":"=","a":{"op":"var","name":"pmaxr"},"b":{"op":"var","name":"none"}}},{"op":"<","a":{"op":"var","name":"k$21"},"b":{"op":"mul","k":64,"a":{"op":"add","a":{"op":"var","name":"pmaxr"},"b":{"op":"const","value":1}}}}]}]}]}},{"name":"every x, y with x < 64 ∧ y < 64: never OneA[x] is 0 and 1 <= Decision[64·x + y]","holds":{"op":"or","xs":[{"op":"not","x":{"op":"and","xs":[{"op":"<","a":{"op":"var","name":"key1$enum"},"b":{"op":"const","value":64}},{"op":"<","a":{"op":"var","name":"key2$enum"},"b":{"op":"const","value":64}}]}},{"op":"not","x":{"op":"and","xs":[{"op":"=","a":{"op":"get","map":"OneA","key":{"op":"var","name":"key1$enum"}},"b":{"op":"const","value":0}},{"op":"<=","a":{"op":"add","a":{"op":"const","value":0},"b":{"op":"const","value":1}},"b":{"op":"add","a":{"op":"const","value":0},"b":{"op":"get","map":"Decision","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"key1$enum"}},"b":{"op":"var","name":"key2$enum"}}}}}]}}]},"forall":"key1$enum","keys":["key2$enum"]},{"name":"every x, y with x < 64 ∧ y < 64: never OneA[x] is 0 and 1 <= Proposal[64·x + y]","holds":{"op":"or","xs":[{"op":"not","x":{"op":"and","xs":[{"op":"<","a":{"op":"var","name":"key1$enum"},"b":{"op":"const","value":64}},{"op":"<","a":{"op":"var","name":"key2$enum"},"b":{"op":"const","value":64}}]}},{"op":"not","x":{"op":"and","xs":[{"op":"=","a":{"op":"get","map":"OneA","key":{"op":"var","name":"key1$enum"}},"b":{"op":"const","value":0}},{"op":"<=","a":{"op":"add","a":{"op":"const","value":0},"b":{"op":"const","value":1}},"b":{"op":"add","a":{"op":"const","value":0},"b":{"op":"get","map":"Proposal","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"key1$enum"}},"b":{"op":"var","name":"key2$enum"}}}}}]}}]},"forall":"key1$enum","keys":["key2$enum"]},{"name":"every x, y with x < 64 ∧ y < 64: never 1 <= Decision[64·x + y] and Proposal[64·x + y] is 0","holds":{"op":"or","xs":[{"op":"not","x":{"op":"and","xs":[{"op":"<","a":{"op":"var","name":"key1$enum"},"b":{"op":"const","value":64}},{"op":"<","a":{"op":"var","name":"key2$enum"},"b":{"op":"const","value":64}}]}},{"op":"not","x":{"op":"and","xs":[{"op":"<=","a":{"op":"add","a":{"op":"const","value":0},"b":{"op":"const","value":1}},"b":{"op":"add","a":{"op":"const","value":0},"b":{"op":"get","map":"Decision","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"key1$enum"}},"b":{"op":"var","name":"key2$enum"}}}}},{"op":"=","a":{"op":"get","map":"Proposal","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"key1$enum"}},"b":{"op":"var","name":"key2$enum"}}},"b":{"op":"const","value":0}}]}}]},"forall":"key1$enum","keys":["key2$enum"]},{"name":"every x, y, z with x < 64 ∧ y < 64 ∧ z < 64 ∧ ¬(y = z): never 1 <= Decision[64·x + y] and 1 <= Decision[64·x + z]","holds":{"op":"or","xs":[{"op":"not","x":{"op":"and","xs":[{"op":"<","a":{"op":"var","name":"key1$enum"},"b":{"op":"const","value":64}},{"op":"<","a":{"op":"var","name":"key2$enum"},"b":{"op":"const","value":64}},{"op":"<","a":{"op":"var","name":"key3$enum"},"b":{"op":"const","value":64}},{"op":"not","x":{"op":"=","a":{"op":"var","name":"key2$enum"},"b":{"op":"var","name":"key3$enum"}}}]}},{"op":"not","x":{"op":"and","xs":[{"op":"<=","a":{"op":"add","a":{"op":"const","value":0},"b":{"op":"const","value":1}},"b":{"op":"add","a":{"op":"const","value":0},"b":{"op":"get","map":"Decision","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"key1$enum"}},"b":{"op":"var","name":"key2$enum"}}}}},{"op":"<=","a":{"op":"add","a":{"op":"const","value":0},"b":{"op":"const","value":1}},"b":{"op":"add","a":{"op":"const","value":0},"b":{"op":"get","map":"Decision","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"key1$enum"}},"b":{"op":"var","name":"key3$enum"}}}}}]}}]},"forall":"key1$enum","keys":["key2$enum","key3$enum"]},{"name":"every x, y, z with x < 64 ∧ y < 64 ∧ z < 64 ∧ ¬(y = z): never 1 <= Decision[64·x + y] and 1 <= Proposal[64·x + z]","holds":{"op":"or","xs":[{"op":"not","x":{"op":"and","xs":[{"op":"<","a":{"op":"var","name":"key1$enum"},"b":{"op":"const","value":64}},{"op":"<","a":{"op":"var","name":"key2$enum"},"b":{"op":"const","value":64}},{"op":"<","a":{"op":"var","name":"key3$enum"},"b":{"op":"const","value":64}},{"op":"not","x":{"op":"=","a":{"op":"var","name":"key2$enum"},"b":{"op":"var","name":"key3$enum"}}}]}},{"op":"not","x":{"op":"and","xs":[{"op":"<=","a":{"op":"add","a":{"op":"const","value":0},"b":{"op":"const","value":1}},"b":{"op":"add","a":{"op":"const","value":0},"b":{"op":"get","map":"Decision","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"key1$enum"}},"b":{"op":"var","name":"key2$enum"}}}}},{"op":"<=","a":{"op":"add","a":{"op":"const","value":0},"b":{"op":"const","value":1}},"b":{"op":"add","a":{"op":"const","value":0},"b":{"op":"get","map":"Proposal","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"key1$enum"}},"b":{"op":"var","name":"key3$enum"}}}}}]}}]},"forall":"key1$enum","keys":["key2$enum","key3$enum"]},{"name":"every x, y, z with x < 64 ∧ y < 64 ∧ z < 64 ∧ ¬(y = z): never 1 <= Proposal[64·x + y] and 1 <= Proposal[64·x + z]","holds":{"op":"or","xs":[{"op":"not","x":{"op":"and","xs":[{"op":"<","a":{"op":"var","name":"key1$enum"},"b":{"op":"const","value":64}},{"op":"<","a":{"op":"var","name":"key2$enum"},"b":{"op":"const","value":64}},{"op":"<","a":{"op":"var","name":"key3$enum"},"b":{"op":"const","value":64}},{"op":"not","x":{"op":"=","a":{"op":"var","name":"key2$enum"},"b":{"op":"var","name":"key3$enum"}}}]}},{"op":"not","x":{"op":"and","xs":[{"op":"<=","a":{"op":"add","a":{"op":"const","value":0},"b":{"op":"const","value":1}},"b":{"op":"add","a":{"op":"const","value":0},"b":{"op":"get","map":"Proposal","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"key1$enum"}},"b":{"op":"var","name":"key2$enum"}}}}},{"op":"<=","a":{"op":"add","a":{"op":"const","value":0},"b":{"op":"const","value":1}},"b":{"op":"add","a":{"op":"const","value":0},"b":{"op":"get","map":"Proposal","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"key1$enum"}},"b":{"op":"var","name":"key3$enum"}}}}}]}}]},"forall":"key1$enum","keys":["key2$enum","key3$enum"]},{"name":"every x, y, z with x < 64 ∧ y < 64 ∧ ¬(x = y) ∧ z < 64: never 1 <= Decision[64·x + z] and 1 <= Decision[64·y + z]","holds":{"op":"or","xs":[{"op":"not","x":{"op":"and","xs":[{"op":"<","a":{"op":"var","name":"key1$enum"},"b":{"op":"const","value":64}},{"op":"<","a":{"op":"var","name":"key2$enum"},"b":{"op":"const","value":64}},{"op":"not","x":{"op":"=","a":{"op":"var","name":"key1$enum"},"b":{"op":"var","name":"key2$enum"}}},{"op":"<","a":{"op":"var","name":"key3$enum"},"b":{"op":"const","value":64}}]}},{"op":"not","x":{"op":"and","xs":[{"op":"<=","a":{"op":"add","a":{"op":"const","value":0},"b":{"op":"const","value":1}},"b":{"op":"add","a":{"op":"const","value":0},"b":{"op":"get","map":"Decision","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"key1$enum"}},"b":{"op":"var","name":"key3$enum"}}}}},{"op":"<=","a":{"op":"add","a":{"op":"const","value":0},"b":{"op":"const","value":1}},"b":{"op":"add","a":{"op":"const","value":0},"b":{"op":"get","map":"Decision","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"key2$enum"}},"b":{"op":"var","name":"key3$enum"}}}}}]}}]},"forall":"key1$enum","keys":["key2$enum","key3$enum"]},{"name":"every x, y, z with x < 64 ∧ y < 64 ∧ ¬(x = y) ∧ z < 64: never 1 <= Decision[64·x + z] and 1 <= Proposal[64·y + z]","holds":{"op":"or","xs":[{"op":"not","x":{"op":"and","xs":[{"op":"<","a":{"op":"var","name":"key1$enum"},"b":{"op":"const","value":64}},{"op":"<","a":{"op":"var","name":"key2$enum"},"b":{"op":"const","value":64}},{"op":"not","x":{"op":"=","a":{"op":"var","name":"key1$enum"},"b":{"op":"var","name":"key2$enum"}}},{"op":"<","a":{"op":"var","name":"key3$enum"},"b":{"op":"const","value":64}}]}},{"op":"not","x":{"op":"and","xs":[{"op":"<=","a":{"op":"add","a":{"op":"const","value":0},"b":{"op":"const","value":1}},"b":{"op":"add","a":{"op":"const","value":0},"b":{"op":"get","map":"Decision","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"key1$enum"}},"b":{"op":"var","name":"key3$enum"}}}}},{"op":"<=","a":{"op":"add","a":{"op":"const","value":0},"b":{"op":"const","value":1}},"b":{"op":"add","a":{"op":"const","value":0},"b":{"op":"get","map":"Proposal","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"key2$enum"}},"b":{"op":"var","name":"key3$enum"}}}}}]}}]},"forall":"key1$enum","keys":["key2$enum","key3$enum"]},{"name":"every x, y with x <= 63 ∧ y < 64: never OneA[y] is 0 and 1 <= OneB[64·y + x]","holds":{"op":"or","xs":[{"op":"not","x":{"op":"and","xs":[{"op":"<=","a":{"op":"var","name":"key1$enum"},"b":{"op":"const","value":63}},{"op":"<","a":{"op":"var","name":"key2$enum"},"b":{"op":"const","value":64}}]}},{"op":"not","x":{"op":"and","xs":[{"op":"=","a":{"op":"get","map":"OneA","key":{"op":"var","name":"key2$enum"}},"b":{"op":"const","value":0}},{"op":"<=","a":{"op":"add","a":{"op":"const","value":0},"b":{"op":"const","value":1}},"b":{"op":"add","a":{"op":"const","value":0},"b":{"op":"get","map":"OneB","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"key2$enum"}},"b":{"op":"var","name":"key1$enum"}}}}}]}}]},"forall":"key1$enum","keys":["key2$enum"]},{"name":"every x, y, z with x <= 63 ∧ y < 64 ∧ z < 64: never 1 <= Qs[x] and 1 <= Decision[64·y + z]","holds":{"op":"or","xs":[{"op":"not","x":{"op":"and","xs":[{"op":"<=","a":{"op":"var","name":"key1$enum"},"b":{"op":"const","value":63}},{"op":"<","a":{"op":"var","name":"key2$enum"},"b":{"op":"const","value":64}},{"op":"<","a":{"op":"var","name":"key3$enum"},"b":{"op":"const","value":64}}]}},{"op":"not","x":{"op":"and","xs":[{"op":"<=","a":{"op":"add","a":{"op":"const","value":0},"b":{"op":"const","value":1}},"b":{"op":"add","a":{"op":"const","value":0},"b":{"op":"get","map":"Qs","key":{"op":"var","name":"key1$enum"}}}},{"op":"<=","a":{"op":"add","a":{"op":"const","value":0},"b":{"op":"const","value":1}},"b":{"op":"add","a":{"op":"const","value":0},"b":{"op":"get","map":"Decision","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"key2$enum"}},"b":{"op":"var","name":"key3$enum"}}}}}]}}]},"forall":"key1$enum","keys":["key2$enum","key3$enum"]},{"name":"every x, y, z with x <= 63 ∧ y < 64 ∧ z < 64: never OneA[y] is 0 and 1 <= Vote[64·64·x + y + z]","holds":{"op":"or","xs":[{"op":"not","x":{"op":"and","xs":[{"op":"<=","a":{"op":"var","name":"key1$enum"},"b":{"op":"const","value":63}},{"op":"<","a":{"op":"var","name":"key2$enum"},"b":{"op":"const","value":64}},{"op":"<","a":{"op":"var","name":"key3$enum"},"b":{"op":"const","value":64}}]}},{"op":"not","x":{"op":"and","xs":[{"op":"=","a":{"op":"get","map":"OneA","key":{"op":"var","name":"key2$enum"}},"b":{"op":"const","value":0}},{"op":"<=","a":{"op":"add","a":{"op":"const","value":0},"b":{"op":"const","value":1}},"b":{"op":"add","a":{"op":"const","value":0},"b":{"op":"get","map":"Vote","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"key1$enum"}},"b":{"op":"var","name":"key2$enum"}}},"b":{"op":"var","name":"key3$enum"}}}}}]}}]},"forall":"key1$enum","keys":["key2$enum","key3$enum"]},{"name":"every x, y, z with x <= 63 ∧ y < 64 ∧ z < 64: never OneB[64·y + x] is 0 and 1 <= Vote[64·64·x + y + z]","holds":{"op":"or","xs":[{"op":"not","x":{"op":"and","xs":[{"op":"<=","a":{"op":"var","name":"key1$enum"},"b":{"op":"const","value":63}},{"op":"<","a":{"op":"var","name":"key2$enum"},"b":{"op":"const","value":64}},{"op":"<","a":{"op":"var","name":"key3$enum"},"b":{"op":"const","value":64}}]}},{"op":"not","x":{"op":"and","xs":[{"op":"=","a":{"op":"get","map":"OneB","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"key2$enum"}},"b":{"op":"var","name":"key1$enum"}}},"b":{"op":"const","value":0}},{"op":"<=","a":{"op":"add","a":{"op":"const","value":0},"b":{"op":"const","value":1}},"b":{"op":"add","a":{"op":"const","value":0},"b":{"op":"get","map":"Vote","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"key1$enum"}},"b":{"op":"var","name":"key2$enum"}}},"b":{"op":"var","name":"key3$enum"}}}}}]}}]},"forall":"key1$enum","keys":["key2$enum","key3$enum"]},{"name":"every x, y, z with x <= 63 ∧ y < 64 ∧ z < 64: never 1 <= Vote[64·64·x + y + z] and Proposal[64·y + z] is 0","holds":{"op":"or","xs":[{"op":"not","x":{"op":"and","xs":[{"op":"<=","a":{"op":"var","name":"key1$enum"},"b":{"op":"const","value":63}},{"op":"<","a":{"op":"var","name":"key2$enum"},"b":{"op":"const","value":64}},{"op":"<","a":{"op":"var","name":"key3$enum"},"b":{"op":"const","value":64}}]}},{"op":"not","x":{"op":"and","xs":[{"op":"<=","a":{"op":"add","a":{"op":"const","value":0},"b":{"op":"const","value":1}},"b":{"op":"add","a":{"op":"const","value":0},"b":{"op":"get","map":"Vote","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"key1$enum"}},"b":{"op":"var","name":"key2$enum"}}},"b":{"op":"var","name":"key3$enum"}}}}},{"op":"=","a":{"op":"get","map":"Proposal","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"key2$enum"}},"b":{"op":"var","name":"key3$enum"}}},"b":{"op":"const","value":0}}]}}]},"forall":"key1$enum","keys":["key2$enum","key3$enum"]},{"name":"carry:guard:e11bb2856a4188b5","holds":{"op":"or","xs":[{"op":"not","x":{"op":"=","a":{"op":"var","name":"busy"},"b":{"op":"const","value":1}}},{"op":"or","xs":[{"op":"not","x":{"op":"=","a":{"op":"var","name":"pr"},"b":{"op":"var","name":"none"}}}]}]}},{"name":"carry:guard:71517ec714847e1e","holds":{"op":"or","xs":[{"op":"not","x":{"op":"=","a":{"op":"var","name":"busy"},"b":{"op":"const","value":1}}},{"op":"or","xs":[{"op":"not","x":{"op":"<","a":{"op":"var","name":"k$19"},"b":{"op":"const","value":64}}},{"op":"not","x":{"op":"=","a":{"op":"get","map":"Proposal","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"pr"}},"b":{"op":"var","name":"k$19"}}},"b":{"op":"const","value":1}}}]}]},"forall":"k$19"},{"name":"carry:guard:f8fa169d60df315a","holds":{"op":"or","xs":[{"op":"not","x":{"op":"=","a":{"op":"var","name":"busy"},"b":{"op":"const","value":1}}},{"op":"or","xs":[{"op":"not","x":{"op":"<=","a":{"op":"const","value":1},"b":{"op":"get","map":"Qs","key":{"op":"var","name":"k$20"}}}},{"op":"=","a":{"op":"get","map":"OneB","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"pr"}},"b":{"op":"var","name":"k$20"}}},"b":{"op":"const","value":1}}]}]},"forall":"k$20"},{"name":"carry:guard:faa607cf227d2883","holds":{"op":"or","xs":[{"op":"not","x":{"op":"=","a":{"op":"var","name":"busy"},"b":{"op":"const","value":1}}},{"op":"or","xs":[{"op":"not","x":{"op":"<=","a":{"op":"const","value":1},"b":{"op":"get","map":"Qs","key":{"op":"var","name":"k$20"}}}},{"op":"<=","a":{"op":"const","value":1},"b":{"op":"get","map":"OneA","key":{"op":"var","name":"pr"}}}]}]},"forall":"k$20"},{"name":"carry:guard:8c4667f43952b1a7","holds":{"op":"or","xs":[{"op":"not","x":{"op":"=","a":{"op":"var","name":"busy"},"b":{"op":"const","value":1}}},{"op":"or","xs":[{"op":"=","a":{"op":"var","name":"pmaxr"},"b":{"op":"var","name":"none"}},{"op":"<","a":{"op":"var","name":"pmaxr"},"b":{"op":"var","name":"pr"}}]}]}},{"name":"carry:guard:4817748873bf0d3a","holds":{"op":"or","xs":[{"op":"not","x":{"op":"=","a":{"op":"var","name":"busy"},"b":{"op":"const","value":1}}},{"op":"or","xs":[{"op":"=","a":{"op":"var","name":"pmaxr"},"b":{"op":"var","name":"none"}},{"op":"<=","a":{"op":"const","value":1},"b":{"op":"get","map":"OneA","key":{"op":"var","name":"pmaxr"}}}]}]}},{"name":"carry:guard:a1aac0f2b5acf946","holds":{"op":"or","xs":[{"op":"not","x":{"op":"=","a":{"op":"var","name":"busy"},"b":{"op":"const","value":1}}},{"op":"or","xs":[{"op":"=","a":{"op":"var","name":"pmaxr"},"b":{"op":"var","name":"none"}},{"op":"<=","a":{"op":"const","value":1},"b":{"op":"get","map":"Proposal","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"pmaxr"}},"b":{"op":"var","name":"pv"}}}}]}]}},{"name":"carry:guard:69834f3e58d5e918","holds":{"op":"or","xs":[{"op":"not","x":{"op":"=","a":{"op":"var","name":"busy"},"b":{"op":"const","value":1}}},{"op":"or","xs":[{"op":"<","a":{"op":"var","name":"pr"},"b":{"op":"const","value":64}}]}]}},{"name":"carry:guard:e6d2937e4bcb51dc","holds":{"op":"or","xs":[{"op":"not","x":{"op":"=","a":{"op":"var","name":"busy"},"b":{"op":"const","value":1}}},{"op":"or","xs":[{"op":"<","a":{"op":"var","name":"pv"},"b":{"op":"const","value":64}}]}]}},{"name":"carry:guard:980373f5503cf4c6","holds":{"op":"or","xs":[{"op":"not","x":{"op":"=","a":{"op":"var","name":"busy"},"b":{"op":"const","value":1}}},{"op":"or","xs":[{"op":"<","a":{"op":"var","name":"pmaxr"},"b":{"op":"const","value":64}}]}]}},{"name":"carry:co-write:6282256ba10ee781","holds":{"op":"or","xs":[{"op":"not","x":{"op":"and","xs":[{"op":"or","xs":[{"op":"<","a":{"op":"var","name":"carryKeyXX"},"b":{"op":"var","name":"size"}}]},{"op":"or","xs":[{"op":"<","a":{"op":"var","name":"carryKeyX"},"b":{"op":"const","value":64}}]},{"op":"<","a":{"op":"var","name":"carryKey"},"b":{"op":"var","name":"carryKeyX"}},{"op":"<=","a":{"op":"const","value":1},"b":{"op":"get","map":"OneB","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"carryKeyX"}},"b":{"op":"var","name":"carryKeyXX"}}}}]}},{"op":"<=","a":{"op":"const","value":1},"b":{"op":"get","map":"Left","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"carryKeyXX"}},"b":{"op":"var","name":"carryKey"}}}}]},"forall":"carryKeyXX","keys":["carryKeyX","carryKey"]},{"name":"carry:global-range:f29c323756a78a95","holds":{"op":"<","a":{"op":"var","name":"pr"},"b":{"op":"const","value":64}}},{"name":"carry:global-range:345c4e9ce3eda2e1","holds":{"op":"<","a":{"op":"var","name":"pmaxr"},"b":{"op":"const","value":64}}},{"name":"carry:global-range:4d9ef1fb20062861","holds":{"op":"<","a":{"op":"var","name":"pv"},"b":{"op":"const","value":64}}},{"name":"carry:global-frame:ef4514c87a594d2c","holds":{"op":"or","xs":[{"op":"not","x":{"op":"<=","a":{"op":"const","value":1},"b":{"op":"get","map":"Qs","key":{"op":"var","name":"k$20"}}}},{"op":"=","a":{"op":"get","map":"OneB","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"pr"}},"b":{"op":"var","name":"k$20"}}},"b":{"op":"const","value":1}}]},"forall":"k$20"},{"name":"carry:point-guard:dbae780daebdcb74","holds":{"op":"or","xs":[{"op":"not","x":{"op":"and","xs":[{"op":"<","a":{"op":"var","name":"carryKeyXXXXX"},"b":{"op":"var","name":"size"}},{"op":"<","a":{"op":"var","name":"carryKeyXXXX"},"b":{"op":"const","value":64}},{"op":"<=","a":{"op":"const","value":1},"b":{"op":"get","map":"OneB","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"carryKeyXXXX"}},"b":{"op":"var","name":"carryKeyXXXXX"}}}}]}},{"op":"=","a":{"op":"get","map":"OneA","key":{"op":"var","name":"carryKeyXXXX"}},"b":{"op":"const","value":1}}]},"forall":"carryKeyXXXXX","keys":["carryKeyXXXX"]},{"name":"carry:point-guard:42b72ece9101070e","holds":{"op":"or","xs":[{"op":"not","x":{"op":"and","xs":[{"op":"<","a":{"op":"var","name":"carryKeyXXXXXX"},"b":{"op":"var","name":"size"}},{"op":"<","a":{"op":"var","name":"carryKeyXXXXXXX"},"b":{"op":"const","value":64}},{"op":"<","a":{"op":"var","name":"carryKeyXXXXXXXX"},"b":{"op":"const","value":64}},{"op":"<=","a":{"op":"const","value":1},"b":{"op":"get","map":"Vote","key":{"op":"add","a":{"op":"add","a":{"op":"mul","k":4096,"a":{"op":"var","name":"carryKeyXXXXXX"}},"b":{"op":"mul","k":64,"a":{"op":"var","name":"carryKeyXXXXXXX"}}},"b":{"op":"var","name":"carryKeyXXXXXXXX"}}}}]}},{"op":"=","a":{"op":"get","map":"Proposal","key":{"op":"add","a":{"op":"mul","k":64,"a":{"op":"var","name":"carryKeyXXXXXXX"}},"b":{"op":"var","name":"carryKeyXXXXXXXX"}}},"b":{"op":"const","value":1}}]},"forall":"carryKeyXXXXXX","keys":["carryKeyXXXXXXX","carryKeyXXXXXXXX"]}],"target":10,"caller":[0,1,2,3,4,5,6,7],"support":[13,14,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44],"pass":1,"ms":896.1170999515151,"houdini":true}
|
package/dist/core/fresh.js
CHANGED
|
@@ -11,12 +11,14 @@
|
|
|
11
11
|
import { evalC, interpret, seeded } from "./machine.js";
|
|
12
12
|
import { clock, counted, fullRate, proveSetFast, withDeadline } from "../kernel/prove.js";
|
|
13
13
|
import { allowed, watch } from "./watch.js";
|
|
14
|
+
import { checkWorkEndpoint } from "./wall.js";
|
|
14
15
|
const v = (name) => ({ op: 'var', name }), get = (map, key) => ({ op: 'get', map, key });
|
|
15
16
|
// The budget is counted (kernel/prove.ts's cost model), as the invariant search's is: what is found is the same on any
|
|
16
17
|
// machine. Houdini's set proofs are proveSetFast's, each round reusing the goals the last one settled.
|
|
17
18
|
// (the deadline too, so a round's goals stop at the budget's end)
|
|
18
19
|
export const freshLaws = (m, kinds, draws, opts = {}) => counted(fullRate, () => withDeadline(clock() + (opts.ms ?? 5000), () => fresh(m, kinds, draws, opts)), true);
|
|
19
20
|
function fresh(m, kinds, draws, opts) {
|
|
21
|
+
checkWorkEndpoint('fresh entry');
|
|
20
22
|
const maps = Object.entries(m.maps ?? {}).filter(([n]) => !(m.inputMaps ?? []).includes(n));
|
|
21
23
|
if (!maps.length || m.history)
|
|
22
24
|
return [];
|
|
@@ -27,6 +29,7 @@ function fresh(m, kinds, draws, opts) {
|
|
|
27
29
|
// a cell written at b): each map no step wrote past it, and each it was seen bounding
|
|
28
30
|
const past = new Set(), bounds = new Set();
|
|
29
31
|
for (let trial = 0; trial < 60 && clock() < until; trial++) {
|
|
32
|
+
checkWorkEndpoint('fresh trial');
|
|
30
33
|
let ps, st;
|
|
31
34
|
try {
|
|
32
35
|
ps = draws.params(rand, bound);
|
|
@@ -38,6 +41,7 @@ function fresh(m, kinds, draws, opts) {
|
|
|
38
41
|
continue;
|
|
39
42
|
}
|
|
40
43
|
for (let d = 0, tries = 0; d < 20 && tries < 60; tries++) {
|
|
44
|
+
checkWorkEndpoint('fresh step');
|
|
41
45
|
try {
|
|
42
46
|
const input = draws.input(rand, bound, ps);
|
|
43
47
|
if (!allowed(m, run, ps, st, input))
|
|
@@ -85,7 +89,7 @@ function fresh(m, kinds, draws, opts) {
|
|
|
85
89
|
const init = m.maps[map];
|
|
86
90
|
cands.push({ law: { name: `keys up to ${c}: ${map} unset past it`, holds: { op: 'or', xs: [{ op: '<=', a: v(key), b: v(c) }, { op: '=', a: get(map, v(key)), b: { op: 'const', value: init } }] }, forall: key }, text: `∀k. ${c} < k → ${map}[k] = ${init}` });
|
|
87
91
|
}
|
|
88
|
-
let alive = cands.filter(f => states.every(({ ps, st }) => { try {
|
|
92
|
+
let alive = cands.filter(f => states.every(({ ps, st }) => { checkWorkEndpoint('fresh validation'); try {
|
|
89
93
|
return watch(m, run, f.law, ps, bound).start(st);
|
|
90
94
|
}
|
|
91
95
|
catch {
|
package/dist/core/infer.js
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { searchNow as countedSearchNow, checkWorkEndpoint } from "./wall.js";
|
|
1
2
|
// Invariants nobody wrote: a law that holds but isn't inductive, proven with laws the search finds. Nothing here is
|
|
2
3
|
// trusted; what it finds is proven by the kernel with the rule's own laws, as laws of the same rule.
|
|
3
4
|
// - runs: random runs from the start (params and requests by their kinds, the assumption met) give reachable states,
|
|
@@ -32,13 +33,15 @@
|
|
|
32
33
|
// rules it out (and the most of those seen) is added; a chosen candidate that nothing supports, or that makes a proof slow, is dropped; the set proven as a whole
|
|
33
34
|
// is the answer, after each chosen candidate the proof doesn't need is taken out again
|
|
34
35
|
import { quietly } from "./cyclic.js";
|
|
36
|
+
import { observeCubeTest } from "./meter.js";
|
|
37
|
+
import { withEvaluationAdmission } from "./evaluation-admission.js";
|
|
35
38
|
import { bitIntersection, bitIntersects } from "./bitsets.js";
|
|
36
39
|
import { samplePredicates, sampleStateText } from "./sample-cache.js";
|
|
37
40
|
import { sampleStep } from "./sample-step.js";
|
|
38
|
-
import { all, any, atMost, carriedView, compileC, compileE, cpair, fastStep, divisorsIn, evalC, evalE, get, interpret, machineTerms, fnValue, modName, n, not, partsOf as tupleOf, plus, same, seeded, times, walk, withArithmetic, x } from "./machine.js";
|
|
41
|
+
import { all, any, atMost, carriedView, compileC, compileE, cpair, fastStep, divisorsIn, evalC, evalE, get, hasFinite, interpret, machineTerms, fnValue, modName, n, not, partsOf as tupleOf, plus, same, seeded, times, walk, withArithmetic, x } from "./machine.js";
|
|
39
42
|
import { bool, refuteModelByRuns, verdictOf } from "./dsl.js";
|
|
40
43
|
import { allowed, keysOf, linKey, watch } from "./watch.js";
|
|
41
|
-
import { clock, counted, fullWork, decideLaw, decideNote, machineKey, memoHits, withStrict, fullRate, grow, keyValue, lawInstances, proveLaw, proveLaws, proveSetFast, proveStepLaws, stepLawInstances, usedHyps, withDeadline, withModels, withTrees, withWall,
|
|
44
|
+
import { clock, counted, fullWork, searchWork, decideLaw, decideNote, machineKey, memoHits, withStrict, fullRate, grow, keyValue, lawInstances, proveLaw, proveLaws, proveSetFast, proveStepLaws, stepLawInstances, usedHyps, withDeadline, withModels, withTrees, withWall, withSearchWork } from "../kernel/prove.js";
|
|
42
45
|
import { assumed, eachParts, obligations, plainOf, stepLawObligations, substC, tuple, tupleParts } from "../kernel/kernel.js";
|
|
43
46
|
import { env, gcd, work } from "./solver.js";
|
|
44
47
|
import { bgcd } from "./q.js";
|
|
@@ -179,6 +182,8 @@ const few = (vals) => vals.length <= 4 && vals.every(x => x <= 8);
|
|
|
179
182
|
// interpreted evaluations); the rest of the step the interpreter's. Its first steps are checked against the
|
|
180
183
|
// interpreter's, and one that differs, or a domain past `most` tuples, leaves the interpreter's.
|
|
181
184
|
export function domainStep(m, most = 20_000) {
|
|
185
|
+
if (hasFinite(m))
|
|
186
|
+
return undefined; // use the exact interpreter, never the speculative domain bound
|
|
182
187
|
// (every write at every key, a relation's at its tuples and a plain map's at its keys, n 1; a write at one key as itself)
|
|
183
188
|
const tupled = (mp) => (m.relations?.[mp]?.length ?? 0) > 1;
|
|
184
189
|
if (!Object.entries(m.step.maps ?? {}).some(([mp, w]) => 'each' in w && tupled(mp)) || m.history || m.leasts || m.inputMaps?.length || m.counts || m.fns)
|
|
@@ -360,7 +365,7 @@ export function domainStep(m, most = 20_000) {
|
|
|
360
365
|
for (const r of each) {
|
|
361
366
|
const far = r.names.map(() => D + 1);
|
|
362
367
|
r.names.forEach((nm, i) => (env[nm] = far[i]));
|
|
363
|
-
const fallback = r.f(env, st), cells = new Map(), at = (xs) => { r.names.forEach((nm, i) => (env[nm] = xs[i])); const v = r.f(env, st); if (v !== fallback)
|
|
368
|
+
const fallback = r.f(env, st), cells = new Map(), at = (xs) => { checkWorkEndpoint('inference relation tuple'); r.names.forEach((nm, i) => (env[nm] = xs[i])); const v = r.f(env, st); if (v !== fallback)
|
|
364
369
|
cells.set(xs.slice(0, -1).reduceRight((b, a) => cpair(a, b), xs.at(-1)), v); };
|
|
365
370
|
// (the tuples it holds and those its pins allow, where its cells are 0 by default; else every tuple below D)
|
|
366
371
|
const pins = fallback === 0 && !st.defaults?.[r.mp] && !m.maps?.[r.mp] ? pinsOf(r, env, st) : undefined;
|
|
@@ -1019,19 +1024,23 @@ function comparisons(m, laws, atoms, coords, more = []) {
|
|
|
1019
1024
|
export function inferLaws(target, laws, stepLaws = [], opts = {}) {
|
|
1020
1025
|
// Repeated rounds and minimization can ask the same root goal again. Keep only
|
|
1021
1026
|
// completed trees for this search, keyed by exact hypotheses and prover modes.
|
|
1022
|
-
return withTrees(() => quietly(() => withDeadline(clock() + (opts.wall === undefined ? opts.ms ?? 20000 : Math.max(0, opts.wall -
|
|
1027
|
+
return withTrees(() => quietly(() => withDeadline(clock() + (opts.wall === undefined ? opts.ms ?? 20000 : Math.max(0, opts.wall - countedSearchNow())), () => inferLawsSearch(target, laws, stepLaws, opts))));
|
|
1023
1028
|
}
|
|
1024
1029
|
function inferLawsSearch(target, laws, stepLaws = [], opts = {}) {
|
|
1030
|
+
return withEvaluationAdmission(() => inferLawsSearchIn(target, laws, stepLaws, opts));
|
|
1031
|
+
}
|
|
1032
|
+
function inferLawsSearchIn(target, laws, stepLaws, opts) {
|
|
1033
|
+
checkWorkEndpoint('inference entry');
|
|
1025
1034
|
// (GDP_INFER_TRACE=2: each phase's progress too, to stderr)
|
|
1026
1035
|
if (env.GDP_INFER_TRACE === '2' && !opts.progress)
|
|
1027
1036
|
opts = { ...opts, progress: (phase, info) => globalThis.process.stderr.write(`[infer ${phase}] ${JSON.stringify(info)}\n`) };
|
|
1028
|
-
const t0 =
|
|
1037
|
+
const t0 = countedSearchNow(), ms = opts.ms ?? 20000, wallUntil = opts.wall ?? t0 + ms, rule = isRule(target) ? target.withSumsOf(laws, stepLaws) : undefined;
|
|
1029
1038
|
// The clock the budgets read (counted milliseconds since the start, or wall time where `timed`), and the stop.
|
|
1030
1039
|
const timed = !!opts.timed, w0 = work.n, used = { tries: 0, rows: 0, evals: 0, watched: 0, erows: 0, etries: 0 };
|
|
1031
|
-
const now = () => (timed ?
|
|
1040
|
+
const now = () => (timed ? countedSearchNow() - t0
|
|
1032
1041
|
: used.tries / inferRates.tries + used.rows / inferRates.rows + used.evals / inferRates.evals + used.watched / inferRates.watched + (work.n - w0) / inferRates.work);
|
|
1033
1042
|
let stopped = false;
|
|
1034
|
-
const stop = () => stopped || (stopped =
|
|
1043
|
+
const stop = () => { checkWorkEndpoint('inference poll'); return stopped || (stopped = countedSearchNow() > wallUntil); };
|
|
1035
1044
|
// The engine's clock (the stage below, from the small instance on): counted as `now` is, with the EPR path's work
|
|
1036
1045
|
// (kernel/epr.ts's eprMeter) and the views' rows beside it, so that every choice it makes by its budget (a BFS cut, the
|
|
1037
1046
|
// filter, a goal's cap, a round's growth) is the same on any machine; the wall (`stop`, `until` past `ms`) only ends it.
|
|
@@ -1039,15 +1048,15 @@ function inferLawsSearch(target, laws, stepLaws = [], opts = {}) {
|
|
|
1039
1048
|
// of what is left of `ms` once the join's count is taken at 0.3 a millisecond (the join's rates count its work
|
|
1040
1049
|
// 2 to 14 times faster than a Modal container does it), so the engine ends within the wall on a container somewhat
|
|
1041
1050
|
// slower than Modal's usual; past `eUntil` it stops as it would past the wall, at the same place on any machine.
|
|
1042
|
-
let eS = { now: 0, epr: eprMeter.n, erows: 0, etries: 0, full:
|
|
1043
|
-
const vnow = () => (timed ? now() : (used.etries - eS.etries) / inferRates.etries + (eprMeter.n - eS.epr) / inferRates.epr + (used.erows - eS.erows) / inferRates.erows + (
|
|
1044
|
-
const meters = () => ({ real: Math.round(
|
|
1051
|
+
let eS = { now: 0, epr: eprMeter.n, erows: 0, etries: 0, full: searchWork() }, eUntil = ms;
|
|
1052
|
+
const vnow = () => (timed ? now() : (used.etries - eS.etries) / inferRates.etries + (eprMeter.n - eS.epr) / inferRates.epr + (used.erows - eS.erows) / inferRates.erows + (searchWork() - eS.full) / inferRates.efull);
|
|
1053
|
+
const meters = () => ({ real: Math.round(countedSearchNow() - t0), v: Math.round(vnow()), now: Math.round(now()), full: Math.round(fullWork()), epr: eprMeter.n - eS.epr, erows: used.erows, etries: used.etries, tries: used.tries, rows: used.rows, evals: used.evals, work: work.n - w0 });
|
|
1045
1054
|
const until = ms;
|
|
1046
|
-
let tp =
|
|
1055
|
+
let tp = countedSearchNow(), cp = 0, wp = w0;
|
|
1047
1056
|
const trace = (what, o = {}) => {
|
|
1048
1057
|
if (!inferTrace)
|
|
1049
1058
|
return;
|
|
1050
|
-
const t =
|
|
1059
|
+
const t = countedSearchNow(), c = now();
|
|
1051
1060
|
globalThis.process.stderr.write(`[infer] ${what} ${JSON.stringify({ ms: Math.round(t - tp), counted: Math.round(c - cp), work: work.n - wp, ...used, ...o })}\n`);
|
|
1052
1061
|
tp = t;
|
|
1053
1062
|
cp = c;
|
|
@@ -1088,7 +1097,7 @@ function inferLawsSearch(target, laws, stepLaws = [], opts = {}) {
|
|
|
1088
1097
|
const out = stepLaws.length ? proveStepLaws(model, given, stepLaws) : (fast ? proveSetFast : proveLaws)(model, given);
|
|
1089
1098
|
return verdictOf(out);
|
|
1090
1099
|
};
|
|
1091
|
-
const stats = (samples, candidates, alive) => ({ samples, candidates, alive, proofs, ms: Math.round(
|
|
1100
|
+
const stats = (samples, candidates, alive) => ({ samples, candidates, alive, proofs, ms: Math.round(countedSearchNow() - t0), stopped: stop() });
|
|
1092
1101
|
// The old public prover's first pass also sampled reachable counterexamples.
|
|
1093
1102
|
// Keep that negative model evidence without invoking a source finalizer.
|
|
1094
1103
|
const refuted = !opts.first && !opts.cubes && rule ? refuteModelByRuns(rule, laws, stepLaws) : undefined;
|
|
@@ -1141,13 +1150,14 @@ function inferLawsSearch(target, laws, stepLaws = [], opts = {}) {
|
|
|
1141
1150
|
// (a rule of relations: its steps by domainStep, its params small: a relation's tuples grow as a power of them; its
|
|
1142
1151
|
// runs the least, the engine's small instance its samples)
|
|
1143
1152
|
const relStep = domainStep(m);
|
|
1144
|
-
const runsTimed = timed || opts.runsMs !== undefined, runsUntil = Math.min(wallUntil,
|
|
1145
|
-
const moreRuns = (trial) => !supplied && (runsTimed ?
|
|
1153
|
+
const runsTimed = timed || opts.runsMs !== undefined, runsUntil = Math.min(wallUntil, countedSearchNow() + (opts.runsMs ?? 500)), least = opts.runs ?? (relStep ? 2000 : Math.min(inferRuns, Math.max(2000, 4 * ms)));
|
|
1154
|
+
const moreRuns = (trial) => !supplied && (runsTimed ? countedSearchNow() < runsUntil : trial < (relStep ? 400 : Math.max(cap, least)) && (used.tries < least || offered < cap) && !stop());
|
|
1146
1155
|
let trials = 0;
|
|
1147
1156
|
// (an assumption with "there exists", a value the request brings, may admit no request at a small bound, a multiple
|
|
1148
1157
|
// of 5 but 0, say: a trial whose steps moved nothing doubles the bound at once)
|
|
1149
1158
|
const skolems = m.inputs.some(i => i.startsWith('some$a'));
|
|
1150
1159
|
for (let trial = 0, bound = 2, stuck = false; moreRuns(trial); trial++, bound = trial % 20 === 0 || stuck ? (bound >= 1024 ? 2 : bound * 2) : bound) {
|
|
1160
|
+
checkWorkEndpoint('inference trial');
|
|
1151
1161
|
stuck = false;
|
|
1152
1162
|
trials++;
|
|
1153
1163
|
// (a rule with maps: one trial in four goes on from a sample, of 64 drawn, holding the value of a state variable the
|
|
@@ -1183,6 +1193,7 @@ function inferLawsSearch(target, laws, stepLaws = [], opts = {}) {
|
|
|
1183
1193
|
}
|
|
1184
1194
|
let took = 0;
|
|
1185
1195
|
for (let d = 0, tries = 0; d < 40 && tries < 200; tries++) {
|
|
1196
|
+
checkWorkEndpoint('inference sample');
|
|
1186
1197
|
used.tries++;
|
|
1187
1198
|
const input = randomInput(params, rare ? 2 : bound);
|
|
1188
1199
|
let next;
|
|
@@ -1403,7 +1414,7 @@ function inferLawsSearch(target, laws, stepLaws = [], opts = {}) {
|
|
|
1403
1414
|
const sizeOf = (coef) => coef.length * 100 + coef.reduce((s, [, c]) => s + Math.abs(c), 0);
|
|
1404
1415
|
const forms = [];
|
|
1405
1416
|
const NS = rowsS.length, NK = rowsK.length;
|
|
1406
|
-
const at = (coef, vals, j) => { let s = 0; for (const [i, c] of coef)
|
|
1417
|
+
const at = (coef, vals, j) => { observeCubeTest(); let s = 0; for (const [i, c] of coef)
|
|
1407
1418
|
s += c * vals[i][j]; return s; };
|
|
1408
1419
|
const keyNots = plain.filter(i => !atoms[i].param && !atoms[i].int && !atoms[i].term);
|
|
1409
1420
|
// The guards: the choices first, then yes/nos, then small naturals, at most eight; each shape's largest value per
|
|
@@ -1751,6 +1762,7 @@ function inferLawsSearch(target, laws, stepLaws = [], opts = {}) {
|
|
|
1751
1762
|
return vs;
|
|
1752
1763
|
};
|
|
1753
1764
|
const holdsRow = (f, env) => {
|
|
1765
|
+
observeCubeTest();
|
|
1754
1766
|
used.evals++;
|
|
1755
1767
|
const vs = valuesOf(env);
|
|
1756
1768
|
if (f.never)
|
|
@@ -2085,7 +2097,7 @@ function inferLawsSearch(target, laws, stepLaws = [], opts = {}) {
|
|
|
2085
2097
|
try {
|
|
2086
2098
|
// (a rule of relations: no round of the join, whose hulls and bounds state no law of a relation's tuples; the engine's)
|
|
2087
2099
|
const noJoin = opts.join === 0 || !!Object.keys(m.relations ?? {}).length;
|
|
2088
|
-
const jT0 =
|
|
2100
|
+
const jT0 = countedSearchNow(), jUntil = Math.min(until, now() + (until - now()) * (noJoin ? 0 : opts.join ?? joinShare));
|
|
2089
2101
|
// The control state: the choice (loc) and, where they are few, the yes/nos (a program counter in bits), each of its
|
|
2090
2102
|
// values reached a part of its own.
|
|
2091
2103
|
const jChoice = modes.find(mo => mo.choice && !atoms[mo.atom].cell), bits = modes.filter(mo => mo.bool && !atoms[mo.atom].cell && !atoms[mo.atom].param);
|
|
@@ -2188,6 +2200,7 @@ function inferLawsSearch(target, laws, stepLaws = [], opts = {}) {
|
|
|
2188
2200
|
// (the frame, places and extra terms compiled once a view (`compiled`); one env the keys are set in, as each
|
|
2189
2201
|
// assignment's own copy was: a level reads only the keys above it)
|
|
2190
2202
|
const go = (i, env) => {
|
|
2203
|
+
checkWorkEndpoint('inference view bindings');
|
|
2191
2204
|
if (i === v.vars.length) {
|
|
2192
2205
|
try {
|
|
2193
2206
|
if (!compiled.frame(env, st))
|
|
@@ -2358,7 +2371,7 @@ function inferLawsSearch(target, laws, stepLaws = [], opts = {}) {
|
|
|
2358
2371
|
e[k] /= g2; const lead = e.find(x2 => x2 !== 0n); if (lead !== undefined && lead < 0n)
|
|
2359
2372
|
for (let k = 0; k < e.length; k++)
|
|
2360
2373
|
e[k] = -e[k]; return e; };
|
|
2361
|
-
const dirValue = (t, vs) => { let v = 0; for (const [i, c] of t)
|
|
2374
|
+
const dirValue = (t, vs) => { observeCubeTest(); let v = 0; for (const [i, c] of t)
|
|
2362
2375
|
v += c * vs[i]; return v; };
|
|
2363
2376
|
let joins = 0, neversBroken = 0;
|
|
2364
2377
|
// A space of the join: the states (one row each, the scalars), or, for a rule with maps, the cells at a key (a row per
|
|
@@ -2375,7 +2388,7 @@ function inferLawsSearch(target, laws, stepLaws = [], opts = {}) {
|
|
|
2375
2388
|
const coords = own.filter(i => !exactAtoms.has(i)), CN = coords.length, dirs = directions(coords);
|
|
2376
2389
|
const groups = new Map();
|
|
2377
2390
|
let keyAtoms = ctl.map(c => c.atom);
|
|
2378
|
-
const residual = (e, vs) => { let r = e[CN]; for (let k = 0; k < CN; k++)
|
|
2391
|
+
const residual = (e, vs) => { observeCubeTest(); let r = e[CN]; for (let k = 0; k < CN; k++)
|
|
2379
2392
|
if (e[k])
|
|
2380
2393
|
r += e[k] * BigInt(vs[coords[k]]); return r; };
|
|
2381
2394
|
const join = (g, vs, widen, into = groups) => {
|
|
@@ -2623,7 +2636,7 @@ function inferLawsSearch(target, laws, stepLaws = [], opts = {}) {
|
|
|
2623
2636
|
const flagless = !Object.keys(m.step.flags ?? {}).length && !!m.assume;
|
|
2624
2637
|
// A kernel search's budget: wall time where the search is timed, else counted in the kernel's work (inferRates.work
|
|
2625
2638
|
// a millisecond), so that what it finds doesn't depend on the machine.
|
|
2626
|
-
const budgeted = (ms2, f) => (timed ? f(
|
|
2639
|
+
const budgeted = (ms2, f) => (timed ? f(countedSearchNow() + Math.max(200, Math.min(ms2, wallUntil - countedSearchNow())))
|
|
2627
2640
|
: counted(inferRates.work, () => f(clock() + ms2)));
|
|
2628
2641
|
const requestAt = (params, st) => {
|
|
2629
2642
|
const vars = {};
|
|
@@ -2708,7 +2721,7 @@ function inferLawsSearch(target, laws, stepLaws = [], opts = {}) {
|
|
|
2708
2721
|
// units and 1.6k), and an unknown one ran 13 s (wo's every k: Leader[k] <= VoteRequestMsg[k], 1.2M and 647k), the
|
|
2709
2722
|
// engine's time; counted, where a 2 s wall used to end it, so the join ends where it ends on any machine)
|
|
2710
2723
|
const follow = engineFollows();
|
|
2711
|
-
const out = withEprCap(follow ? joinGrowEpr : Infinity, () =>
|
|
2724
|
+
const out = withEprCap(follow ? joinGrowEpr : Infinity, () => withSearchWork(follow ? searchWork() + joinGrowWork : Infinity, () => budgeted(joinQueryMs, until2 => grow(g, new Map(), { nodes: 0, until: until2 }))));
|
|
2712
2725
|
if (!('tree' in out))
|
|
2713
2726
|
return { stuck: out.stuck, witness: out.stuck === 'sat' ? out.witness : undefined, g: g };
|
|
2714
2727
|
for (const h of usedHyps(g, out.tree))
|
|
@@ -3370,6 +3383,7 @@ function inferLawsSearch(target, laws, stepLaws = [], opts = {}) {
|
|
|
3370
3383
|
}
|
|
3371
3384
|
}
|
|
3372
3385
|
const stepIn = (tb, params, st, input) => {
|
|
3386
|
+
checkWorkEndpoint('inference instance step');
|
|
3373
3387
|
try {
|
|
3374
3388
|
if (tb.js)
|
|
3375
3389
|
return tb.js(params, st, input);
|
|
@@ -3925,7 +3939,7 @@ function inferLawsSearch(target, laws, stepLaws = [], opts = {}) {
|
|
|
3925
3939
|
if (env.GDP_POOL_STOP !== '0' && k > 0 && !killed.size)
|
|
3926
3940
|
break;
|
|
3927
3941
|
}
|
|
3928
|
-
opts.progress?.('join pool', { made: pool.length, left: live.length, states, ms: Math.round(vnow() - t5), real: Math.round(
|
|
3942
|
+
opts.progress?.('join pool', { made: pool.length, left: live.length, states, ms: Math.round(vnow() - t5), real: Math.round(countedSearchNow() - t0) });
|
|
3929
3943
|
return live;
|
|
3930
3944
|
}
|
|
3931
3945
|
};
|
|
@@ -3950,7 +3964,7 @@ function inferLawsSearch(target, laws, stepLaws = [], opts = {}) {
|
|
|
3950
3964
|
const engine = () => {
|
|
3951
3965
|
if (sorts && callerLaws.some(l => l.keys?.length) && now() < until && !stop()) {
|
|
3952
3966
|
if (!timed) {
|
|
3953
|
-
eS = { now: now(), epr: eprMeter.n, erows: used.erows, etries: used.etries, full:
|
|
3967
|
+
eS = { now: now(), epr: eprMeter.n, erows: used.erows, etries: used.etries, full: searchWork() };
|
|
3954
3968
|
eUntil = engineShare * (ms - 0.3 * eS.now);
|
|
3955
3969
|
}
|
|
3956
3970
|
opts.progress?.('join engine', { wall: Math.round(vnow()), eUntil: Math.round(eUntil) });
|
|
@@ -4981,8 +4995,8 @@ function inferLawsSearch(target, laws, stepLaws = [], opts = {}) {
|
|
|
4981
4995
|
}
|
|
4982
4996
|
ctx = whole;
|
|
4983
4997
|
}
|
|
4984
|
-
const tq =
|
|
4985
|
-
qms += Math.round(
|
|
4998
|
+
const tq = countedSearchNow(), out = stepWith(todo, todoForm, ctx);
|
|
4999
|
+
qms += Math.round(countedSearchNow() - tq);
|
|
4986
5000
|
if ('used' in out) {
|
|
4987
5001
|
stood.set(todo, out.used);
|
|
4988
5002
|
opts.progress?.('join', { round: rounds, set: set.length, ms: qms, proven: todo.slice(0, 60), reads: out.used.length, ctx: ctx.length, attempt });
|
|
@@ -5172,7 +5186,7 @@ function inferLawsSearch(target, laws, stepLaws = [], opts = {}) {
|
|
|
5172
5186
|
// (a rule whose scalars the runs held at a few values each: no counter, the engine's shape)
|
|
5173
5187
|
if (engineFollows() && why !== 'inductive')
|
|
5174
5188
|
engine();
|
|
5175
|
-
opts.progress?.('join end', { rounds, set: set.length, why, cone: cone.length, ms: Math.round(
|
|
5189
|
+
opts.progress?.('join end', { rounds, set: set.length, why, cone: cone.length, ms: Math.round(countedSearchNow() - jT0), ...meters() });
|
|
5176
5190
|
// (unproven, the search below begins as it would have: the candidates and the counterexamples as they were)
|
|
5177
5191
|
if (why === 'inductive')
|
|
5178
5192
|
chosen = cone;
|
|
@@ -5182,6 +5196,7 @@ function inferLawsSearch(target, laws, stepLaws = [], opts = {}) {
|
|
|
5182
5196
|
}
|
|
5183
5197
|
}
|
|
5184
5198
|
catch (e) {
|
|
5199
|
+
checkWorkEndpoint('inference failure');
|
|
5185
5200
|
pool = pool0;
|
|
5186
5201
|
ctis.length = ctis0;
|
|
5187
5202
|
chosen = [];
|
|
@@ -5230,11 +5245,11 @@ function inferLawsSearch(target, laws, stepLaws = [], opts = {}) {
|
|
|
5230
5245
|
if (enumProof)
|
|
5231
5246
|
last = enumProof;
|
|
5232
5247
|
for (let iter = 0; iter < 300 && !enumProof && now() < until && !stop(); iter++) {
|
|
5233
|
-
const began = now(), wall =
|
|
5248
|
+
const began = now(), wall = countedSearchNow();
|
|
5234
5249
|
// (each law proven alone, then the set as a whole: the same goals, grown once)
|
|
5235
5250
|
last = withTrees(() => search([...given, ...chosen.map(lawFor)]));
|
|
5236
5251
|
const took = now() - began;
|
|
5237
|
-
opts.progress?.('proof', { chosen: chosen.length, goal: last.goal ?? '', stuck: last.stuck ?? '', ms: Math.round(
|
|
5252
|
+
opts.progress?.('proof', { chosen: chosen.length, goal: last.goal ?? '', stuck: last.stuck ?? '', ms: Math.round(countedSearchNow() - wall), counted: Math.round(took) });
|
|
5238
5253
|
if (last.proven && last.checked)
|
|
5239
5254
|
break;
|
|
5240
5255
|
if (!last.goal)
|
|
@@ -5267,10 +5282,10 @@ function inferLawsSearch(target, laws, stepLaws = [], opts = {}) {
|
|
|
5267
5282
|
if (!next && p)
|
|
5268
5283
|
next = best(p, true);
|
|
5269
5284
|
if (!next && p) {
|
|
5270
|
-
const t =
|
|
5285
|
+
const t = countedSearchNow(), made = fromCti(p);
|
|
5271
5286
|
pool.push(...made);
|
|
5272
5287
|
next = best(p);
|
|
5273
|
-
opts.progress?.('cti', { forms: made.length, ms: Math.round(
|
|
5288
|
+
opts.progress?.('cti', { forms: made.length, ms: Math.round(countedSearchNow() - t) });
|
|
5274
5289
|
}
|
|
5275
5290
|
// (a cell form chosen with its mirror where that is alive: the equality both halves state at every key, neither
|
|
5276
5291
|
// inductive without the other, as the real-world corpus's Timelock and blnk need; on CHC's scalar forms, measured,
|
package/dist/core/kind.js
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { searchNow as countedSearchNow } from "./wall.js";
|
|
1
2
|
import { checkKInduction, historyMachine, kInductionStart, kInductionSteps, stepLawObligations } from "../kernel/kernel.js";
|
|
2
3
|
import { clock, counted, grow, proveLaws } from "../kernel/prove.js";
|
|
3
4
|
import { REFUTED, growCdcl } from "../kernel/cdcl.js";
|
|
@@ -14,7 +15,7 @@ export function proveKInduction(m, laws, law, opts) {
|
|
|
14
15
|
if (!kindFits(m, laws, law))
|
|
15
16
|
return { proven: false, checked: false, depths, why: 'a law or fact about every key, a flag at every key, or a carried map' };
|
|
16
17
|
return counted(opts.rate ?? 200, () => {
|
|
17
|
-
const until = clock() + opts.ms, over = () => clock() > until || (opts.wall !== undefined &&
|
|
18
|
+
const until = clock() + opts.ms, over = () => clock() > until || (opts.wall !== undefined && countedSearchNow() > opts.wall);
|
|
18
19
|
// A goal's tree: CDCL's, unfolded (prove.ts's grow keeps CDCL off a goal over k steps, for the size of the tree its
|
|
19
20
|
// cuts would make smaller; but here the plain search's cases multiply with every step), else the plain search's.
|
|
20
21
|
const treeOf = (g) => {
|