Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature: SMTChecker support (a.k.a support all possible outputs) #979

Closed
sambacha opened this issue Mar 18, 2022 · 2 comments
Closed

Feature: SMTChecker support (a.k.a support all possible outputs) #979

sambacha opened this issue Mar 18, 2022 · 2 comments
Labels
C-forge Command: forge Cmd-forge-build Command: forge build P-normal Priority: normal T-feature Type: feature

Comments

@sambacha
Copy link
Contributor

sambacha commented Mar 18, 2022

Component

Forge

Describe the feature you would like

As of 0.8.4, solidity is depreciating the experimental pragma for SMT Checker as it runs on all files if enabled

pragma experimental SMTChecker;

The new way to configure this is through the JSON config file

"settings.modelChecker.targets": ["underflow", "overflow"]

You have to define which engine it should run as well, see https://docs.soliditylang.org/en/v0.8.11/smtchecker.html#smtchecker-engines

"settings.modelChecker.solvers": ["smtlib2","z3"]
settings.modelChecker.targets=<targets>

And what targets to check

: --model-checker-targets assert,overflow

These options are not configurable currently for forge

Additional benefits would be when using the yul optimizer you would have access to the ReasoningBasedSimplifier

Additional context

Additionally custom natspec parsing would help in tests

/// @custom:smtchecker

maybe can be expanded to slither other tools, etc

@sambacha sambacha added the T-feature Type: feature label Mar 18, 2022
@onbjerg onbjerg added C-forge Command: forge P-normal Priority: normal Cmd-forge-build Command: forge build labels Mar 21, 2022
@sambacha
Copy link
Contributor Author

Bump to @gakonst now that revm is the default

@sambacha
Copy link
Contributor Author

There are multiple issues covering compiled output already. utilizing the solc binary directly and feeding the compiled output is satisfactory for the use case described here

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-forge Command: forge Cmd-forge-build Command: forge build P-normal Priority: normal T-feature Type: feature
Projects
Archived in project
Development

No branches or pull requests

2 participants