Class Solver_altergo
- All Implemented Interfaces:
ISolver
alt-ergo --input smtlib2
--output smtlib2, reading the script from standard input.
Alt-Ergo writes nothing for a successful command and answers (set-option :print-success true)
with unsupported, so solverPrintsSuccess() is false: each command is followed by an
echo that marks the end of its response (see AbstractSolver). Alt-Ergo ignores, writing nothing,
get-option, get-value, get-assertions, get-unsat-core, get-unsat-assumptions, get-proof and
reset-assertions; those are answered here. It is run with --continue-on-error (by default it exits
after any error), and in its default mode answers check-sat with unsat or unknown, never sat.
Timeout: Alt-Ergo's --timelimit=SECONDS is one value, applied whole-run or, with
--timelimit-per-goal, per goal; see the constructor for how jSMTLIB's two timeouts map
onto it.
-
Nested Class Summary
Nested classes/interfaces inherited from class org.smtlib.AbstractSolver
AbstractSolver.Pending, AbstractSolver.Shape, AbstractSolver.StackChangeNested classes/interfaces inherited from interface org.smtlib.ISolver
ISolver.CreationException -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected String[]The command-line arguments for launching the solver.Fields inherited from class org.smtlib.AbstractSolver
checkSatStatus, END_WAIT_MILLIS, endedByTimeLimit, isMac, isWindows, linesOffset, options, printSuccess, printSuccessResponse, smtConfig, SOLVER_EXITED, solverProcess -
Constructor Summary
ConstructorsConstructorDescriptionSolver_altergo(SMT.Configuration smtConfig, String executable) Creates an instance of the solverSolver_altergo(SMT.Configuration smtConfig, String[] command) Launches the given command as is (a .command property, #147), without adding the flags the executable form adds -
Method Summary
Modifier and TypeMethodDescriptionexit()Alt-Ergo is silent for exit, as for any successful command, but no echo can follow it, since the process ends; so success is answered once the process has ended.Alt-Ergo ignores get-assertions, writing nothing; answered unsupported without sending itAlt-Ergo answers get-assignment in assert mode after a check.Alt-Ergo answers get-model in assert mode after a checkget_option(IExpr.IKeyword key) Alt-Ergo ignores get-option, writing nothing; answered from the values set (see set_option_impl) and the SMT-LIB defaultsAlt-Ergo writes nothing for get-proof (it ignores it); answered unsupported without sending itAlt-Ergo ignores get-unsat-assumptions, writing nothing; answered unsupported without sending itAlt-Ergo ignores get-unsat-core, writing nothing (with --sat-solver Tableaux it writes a non-SMT-LIB core after check-sat instead); answered unsupported without sending itAlt-Ergo ignores get-value, writing nothing; answered unsupported without sending itAlt-Ergo ignores reset-assertions, writing nothing and keeping the assertions; answered unsupported without sending itprotected IResponseset_option_impl(IExpr.IKeyword key, IAttributeValue value) Sent to Alt-Ergo, and kept here for get_option when Alt-Ergo accepts itprotected booleanAlt-Ergo writes nothing for a successful command and answers(set-option :print-success true)with unsupported; its commands are therefore sent as when pipelining, each followed by an echo that marks the end of its responsestart()Starts the solver; this is not an SMT-LIB command, but it is convenient in some implementations to separate the starting and initialization from the construction of the solver instance.Methods inherited from class org.smtlib.AbstractSolver
assertExpr, check_sat, check_sat_assuming, checkImmediateExit, checkPrintSuccess, checkSatStatus, checkShape, checkStatus, comment, correctResponse, declare_const, declare_datatype, declare_datatypes, declare_fun, declare_sort, declare_sort_parameter, define_const, define_fun, define_fun_rec, define_funs_rec, define_sort, earlierSourceLine, echo, errorStopsSolver, execute, executePipelined, exitedResponse, finishPipelined, forceExit, get_info, hasPending, inSatMode, interrupt, inUnsatMode, isFlatResponse, isTimeLimitResponse, lineNumberPatterns, logSolverDiagnostics, modelResponse, nextSolverLine, normalizeForTesting, outOfStep, parseResponse, pipelines, pop, proofResponse, push, readPipelined, recordChange, reportsEarlierLines, reportSeedIgnored, requireNoChangeSinceCheck, requireOptionEnabled, requireSatOrUnknown, requireUnsat, reset, responseEnd, selfReportsImmediateExit, sendChange, sendCommand, sendExitCommand, sendFailure, sendFailure, sendPipelined, sendScriptText, sendSeed, set_info, set_logic, set_option, setSourceLine, shapeOf, smt, solverName, successOrEmpty, timeLimitResponse, timeLimitResponseAfterExit, translate, unsatAssumptionsElements, unsatCoreElements, withSourceLinesMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.smtlib.ISolver
assertExpr, check_sat, check_sat_assuming, checkSatStatus, comment, declare_const, declare_datatype, declare_datatypes, declare_fun, declare_sort, declare_sort_parameter, define_const, define_fun, define_fun_rec, define_funs_rec, define_sort, echo, execute, forceExit, get_info, pop, push, reset, set_info, set_logic, set_option, setSourceLine, smt, solverName
-
Field Details
-
cmds
The command-line arguments for launching the solver.
-
-
Constructor Details
-
Solver_altergo
Creates an instance of the solver -
Solver_altergo
Launches the given command as is (a .command property, #147), without adding the flags the executable form adds
-
-
Method Details
-
start
Description copied from interface:ISolverStarts the solver; this is not an SMT-LIB command, but it is convenient in some implementations to separate the starting and initialization from the construction of the solver instance.- Specified by:
startin interfaceISolver- Overrides:
startin classAbstractSolver- Returns:
- success or an SMT error response
- See Also:
-
solverPrintsSuccess
protected boolean solverPrintsSuccess()Alt-Ergo writes nothing for a successful command and answers(set-option :print-success true)with unsupported; its commands are therefore sent as when pipelining, each followed by an echo that marks the end of its response- Overrides:
solverPrintsSuccessin classAbstractSolver
-
exit
Alt-Ergo is silent for exit, as for any successful command, but no echo can follow it, since the process ends; so success is answered once the process has ended. If it had already ended (its output was read to its end) or does not end in time, the answer is as the base class gives it, or an error.- Specified by:
exitin interfaceISolver- Overrides:
exitin classAbstractSolver- Returns:
- success or an SMT error response
- See Also:
-
set_option_impl
Sent to Alt-Ergo, and kept here for get_option when Alt-Ergo accepts it- Overrides:
set_option_implin classAbstractSolver
-
get_option
Alt-Ergo ignores get-option, writing nothing; answered from the values set (see set_option_impl) and the SMT-LIB defaults- Specified by:
get_optionin interfaceISolver- Overrides:
get_optionin classAbstractSolver- Parameters:
key- the keyword naming the option- Returns:
- the option value, or unsupported, or an SMT error response
- See Also:
-
reset_assertions
Alt-Ergo ignores reset-assertions, writing nothing and keeping the assertions; answered unsupported without sending it- Specified by:
reset_assertionsin interfaceISolver- Overrides:
reset_assertionsin classAbstractSolver- Returns:
- success or an SMT error response
- See Also:
-
get_proof
Alt-Ergo writes nothing for get-proof (it ignores it); answered unsupported without sending it- Specified by:
get_proofin interfaceISolver- Overrides:
get_proofin classAbstractSolver- Returns:
- a proof, unsupported, or an SMT error response
- See Also:
-
get_value
Alt-Ergo ignores get-value, writing nothing; answered unsupported without sending it- Specified by:
get_valuein interfaceISolver- Overrides:
get_valuein classAbstractSolver- Parameters:
terms- expressions to evaluate- Returns:
- a list of term–value pairs, unsupported, or an SMT error response
- See Also:
-
get_assertions
Alt-Ergo ignores get-assertions, writing nothing; answered unsupported without sending it- Specified by:
get_assertionsin interfaceISolver- Overrides:
get_assertionsin classAbstractSolver- Returns:
- a sequence of asserted terms, unsupported, or an SMT error response
- See Also:
-
get_unsat_core
Alt-Ergo ignores get-unsat-core, writing nothing (with --sat-solver Tableaux it writes a non-SMT-LIB core after check-sat instead); answered unsupported without sending it- Specified by:
get_unsat_corein interfaceISolver- Overrides:
get_unsat_corein classAbstractSolver- Returns:
- a list of formula names, unsupported, or an SMT error response
- See Also:
-
get_unsat_assumptions
Alt-Ergo ignores get-unsat-assumptions, writing nothing; answered unsupported without sending it- Specified by:
get_unsat_assumptionsin interfaceISolver- Overrides:
get_unsat_assumptionsin classAbstractSolver- Returns:
- a list of assumption literals, unsupported, or an SMT error response
- See Also:
-
get_model
Alt-Ergo answers get-model in assert mode after a check- Specified by:
get_modelin interfaceISolver- Overrides:
get_modelin classAbstractSolver- Returns:
- a model, unsupported, or an SMT error response
- See Also:
-
get_assignment
Alt-Ergo answers get-assignment in assert mode after a check. Sent through sendCommand, which reads Alt-Ergo's reply up to the echo after it (the base class reads one line, which may be a blank line Alt-Ergo writes around replies)- Specified by:
get_assignmentin interfaceISolver- Overrides:
get_assignmentin classAbstractSolver- Returns:
- a list of name–Boolean pairs, unsupported, or an SMT error response
- See Also:
-