Skip to content

LEC: name the problem the solver is given, and the time it takes - #268

Open
oharboe wants to merge 2 commits into
keplertech:mainfrom
oharboe:solver-problem-size
Open

oharboe wants to merge 2 commits into
keplertech:mainfrom
oharboe:solver-problem-size

Conversation

@oharboe

@oharboe oharboe commented Oct 6, 2026 •

Copy link
Copy Markdown
Contributor

"Starting solver" says nothing about what it started on. On a 256-word, 21-port register file, the miter built in four minutes, then the solver ran for over half an hour with nothing more logged. There was no way to tell a hard problem from a hang, or to compare it with a smaller run.

The two existing lines now carry the problem and the time, without adding a line:

Starting solver: <v> variables, <c> clauses, <n> outputs compared
SAT solver finished: UNSAT in <s> s
  • SATSolverWrapper counts the clauses it is handed and the largest variable they use.
  • Both solve sites in MiterStrategy log it: the whole design and compact mode.
  • KeplerCliSubprocessTests.LecLogNamesTheSolverProblemAndItsTime in MiterTests runs the binary on AND2 against NAND2 into INV, from a tiny inline liberty. That pair is equivalent but can't be hashed away, so the solver runs. The test reads both lines from the log and takes milliseconds.

bazel-orfs carries this as a patch for now; it would drop the patch once this merges.

Tested: bazel test //... passes, including the test above.

Correction: an earlier version of this PR put its test in KeplerFormalCliTests.cpp, which only CMake builds, so it did not run under Bazel. The test now lives in MiterTests. The CMake-side copy is still there; tell me if you'd rather drop it.

🤖 Generated with Claude Code

oharboe and others added 2 commits October 6, 2026 09:36
"Starting solver" said nothing about what it started on. On a
256-word, 21-port register file the miter built in four minutes and the
solver then ran for over half an hour with nothing more logged: no way to
tell a hard problem from a hang, or to compare it with a smaller run.

The two existing lines now carry it, without adding a line:

  Starting solver: <v> variables, <c> clauses, <n> outputs compared
  SAT solver finished: UNSAT in <s> s

SATSolverWrapper counts the clauses it is handed and the largest variable
they use. LecLogNamesTheSolverProblemAndItsTime runs an equivalent pair
the miter cannot hash away (a & b against ~(~a | ~b)) and reads both
lines from the log.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
KeplerFormalCliTests.cpp is built by CMake only. MiterTests'
LecLogNamesTheSolverProblemAndItsTime runs the binary on AND2 against
NAND2 into INV (a tiny inline liberty), an equivalent pair the miter
cannot hash away, and reads both solver lines from the log.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant