Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
469 commits
Select commit Hold shift + click to select a range
52e4c73
Merge remote-tracking branch 'origin/keuscha/assumption_analysis' int…
AndreaKe Aug 1, 2025
b46fd8b
remove analysis labels from function axioms
AndreaKe Aug 2, 2025
da2df73
minor fixes
AndreaKe Aug 4, 2025
b2381b6
add infeasibility bug example
AndreaKe Aug 5, 2025
9c7fb10
add precision tests - branches
AndreaKe Aug 5, 2025
5726578
fix graph export
AndreaKe Aug 6, 2025
97ec24f
optimize infeasibility case
AndreaKe Aug 6, 2025
ad5d00b
Revert "optimize infeasibility case"
AndreaKe Aug 6, 2025
37530fb
add test cases (applying, unfolding)
AndreaKe Aug 6, 2025
161cad0
cleanup
AndreaKe Aug 6, 2025
2900206
optimize infeasibility case
AndreaKe Aug 8, 2025
4594cf6
fix verification errors occuring when disabling infeasibility checks
AndreaKe Aug 8, 2025
db164e5
fix verification errors occuring when disabling infeasibility checks
AndreaKe Aug 8, 2025
a25c90a
check pipeline
AndreaKe Aug 12, 2025
1dc6c42
add pruning requests to command line tool
AndreaKe Aug 16, 2025
b011e39
fix precision benchmark
AndreaKe Aug 16, 2025
5559971
add precision benchmark results
AndreaKe Aug 16, 2025
422e769
add sequence test
AndreaKe Aug 16, 2025
e2c2090
minor fixes
AndreaKe Aug 17, 2025
34afe0b
update test examples
AndreaKe Aug 17, 2025
cd91caa
separate soundness tests and precision benchmark
AndreaKe Aug 18, 2025
6143826
minor fixes
AndreaKe Aug 27, 2025
ecc6109
add benchmark query to command line tool
AndreaKe Sep 1, 2025
e37df2e
fix benchmark query
AndreaKe Sep 2, 2025
61d95ff
minor fix
AndreaKe Sep 3, 2025
4c71e81
Merge remote-tracking branch 'origin/keuscha/assumption_analysis' int…
AndreaKe Sep 3, 2025
d975eb6
add queries for benchmarks
AndreaKe Sep 4, 2025
d652033
minor fix
AndreaKe Sep 4, 2025
fc9ecde
fix benchmarks, add results
AndreaKe Sep 5, 2025
72e7a62
add debug config option
AndreaKe Sep 5, 2025
dfc57c3
Merge remote-tracking branch 'origin/keuscha/assumption_analysis' int…
AndreaKe Sep 5, 2025
99b9796
add test cases
AndreaKe Sep 5, 2025
ce67226
update plotter
AndreaKe Sep 5, 2025
6e2b4d3
more tests, minor fix
AndreaKe Sep 8, 2025
9c33dbd
update precision benchmark
AndreaKe Sep 8, 2025
d3b0ead
cleanup
AndreaKe Sep 8, 2025
7e1ed2b
add neo4j import script
AndreaKe Sep 8, 2025
1620c9c
fix
AndreaKe Sep 8, 2025
4ad5713
fix and add neo4j queries
AndreaKe Sep 17, 2025
cc2af1e
fix names of benchmarks, add latest benchmark results
AndreaKe Sep 22, 2025
ff17c4f
cleanup
AndreaKe Sep 24, 2025
1aae05c
add Readme
AndreaKe Sep 26, 2025
334647a
update Readme
AndreaKe Sep 26, 2025
f9da376
minor fix
AndreaKe Sep 30, 2025
d1547af
optimize graph join through prefiltering/grouping
AndreaKe Nov 14, 2025
71471e3
renaming assumptionAnalysis -> dependencyAnalysis
AndreaKe Nov 20, 2025
c730c9b
optimize join for axioms
AndreaKe Nov 20, 2025
03aa584
profiling
AndreaKe Nov 6, 2025
cca0766
fix
AndreaKe Nov 20, 2025
21cd2d3
optimize graph join
AndreaKe Nov 20, 2025
1b939c2
add more profiling instrumentation
AndreaKe Nov 24, 2025
190a62d
fix test annotations
AndreaKe Nov 27, 2025
80fed57
verification errors fixed but DA unsound!!
AndreaKe Nov 28, 2025
a14cc6c
Making resource bounds the default instead of timeouts (#949)
marcoeilers Nov 26, 2025
01f7b52
verification errors fixed but DA unsound!!
AndreaKe Dec 2, 2025
ff3325b
fix: sound again
AndreaKe Dec 8, 2025
7d4bb11
cleanup analysis source info
AndreaKe Dec 8, 2025
fa85f41
minor fixes
AndreaKe Dec 11, 2025
a61ab6d
introduce precondition assumption type
AndreaKe Dec 11, 2025
b24ee22
(WIP) progress metric
AndreaKe Dec 11, 2025
455598e
(WIP) progress metric
AndreaKe Dec 12, 2025
6d4ff4f
add PostconditionCall assumption type
AndreaKe Dec 15, 2025
2821bfe
update verification progress metric
AndreaKe Dec 15, 2025
759c9d9
WIP: pass dependency results to Gobra
AndreaKe Dec 15, 2025
a09bd41
WIP: fix unsoundness issues in Gobra DA
AndreaKe Dec 16, 2025
6ce376f
minor fixes
AndreaKe Dec 17, 2025
d9c3fec
tmp
AndreaKe Dec 17, 2025
d3976d1
tmp
AndreaKe Dec 17, 2025
15fb4a0
modifications for Gobra dependency analysis
AndreaKe Dec 18, 2025
762b64c
minor fix
AndreaKe Dec 19, 2025
628bc7a
add documentation
AndreaKe Dec 22, 2025
669617d
(WIP) implement alternative progress metric
AndreaKe Dec 22, 2025
2130d0a
fix position mapping for DA
AndreaKe Jan 5, 2026
5e8eba7
minor renaming
AndreaKe Jan 7, 2026
e4ec91e
add some examples
AndreaKe Jan 9, 2026
ca64da4
cleanup of how passing dependency results to Gobra
AndreaKe Jan 9, 2026
f8ea7f8
implement progress metric
AndreaKe Jan 9, 2026
14c87f9
fix lifting from low level to user level graph
AndreaKe Jan 12, 2026
5c0dfce
renaming
AndreaKe Jan 12, 2026
acbcca6
implement verification guidance
AndreaKe Jan 12, 2026
c990fa6
handle verification failures in progress metric
AndreaKe Jan 12, 2026
c75b617
fix for Gobra
AndreaKe Jan 12, 2026
4ce35a3
handle verification failures via infeasible path and assert failed nodes
AndreaKe Jan 13, 2026
9964848
minor fix
AndreaKe Jan 13, 2026
af67cfd
minor fix
AndreaKe Jan 13, 2026
ca821e1
add dependency types
AndreaKe Jan 14, 2026
e15ae1f
revert
AndreaKe Jan 14, 2026
c769b79
fix source info "equals"
AndreaKe Jan 14, 2026
c87a0f7
fix function axioms of disabled functions
AndreaKe Jan 14, 2026
9863770
progress metric: require verified program
AndreaKe Jan 14, 2026
08233c9
progress metric: exclude trivial assertions
AndreaKe Jan 14, 2026
69ed391
test
AndreaKe Jan 14, 2026
b3e6f21
Revert "fix source info "equals""
AndreaKe Jan 14, 2026
ffb25e3
fix UserLevelDependencyAnalysisNode creation
AndreaKe Jan 14, 2026
b1d20cc
minor fix
AndreaKe Jan 14, 2026
9d67732
temporary fix graph join for frontends
AndreaKe Jan 15, 2026
3afb7bc
fix UserLevelDependencyAnalysisNode
AndreaKe Jan 15, 2026
6672a9d
fix AnalysisSourceInfo
AndreaKe Jan 15, 2026
34b6c18
minor fix
AndreaKe Jan 15, 2026
53d3051
DependencyAnalysisTestFramework: make storing pruned programs optional
AndreaKe Jan 15, 2026
bf5f1ca
update submodules
AndreaKe Jan 15, 2026
d0a0f07
add progress test
AndreaKe Jan 15, 2026
9ed781e
fix method join
AndreaKe Jan 16, 2026
3d41f98
implement VerificationProgressRunner
AndreaKe Jan 16, 2026
36fa7eb
add verification progress examples
AndreaKe Jan 16, 2026
74a2a1e
update Readme
AndreaKe Jan 16, 2026
71b955f
fix typos
AndreaKe Jan 16, 2026
a13e6e7
Merge branch 'master' into keuscha/assumption_analysis_profiling_gobra
AndreaKe Jan 26, 2026
7b45a02
fix after merge
AndreaKe Jan 26, 2026
c1231a1
fix assumption types
AndreaKe Jan 27, 2026
901aae1
dependency node equality workaround
AndreaKe Jan 27, 2026
1cef81a
fix assumption types
AndreaKe Jan 27, 2026
12d4ff0
treat assertions as verification annotations
AndreaKe Jan 28, 2026
50821f3
fix function axioms by removing analysis labels
AndreaKe Jan 29, 2026
73d930f
comment in warnings about function axioms
AndreaKe Jan 29, 2026
5077d68
progress metric: remove special treatment of verification failures
AndreaKe Jan 29, 2026
e0d695d
optimize progress computation
AndreaKe Feb 2, 2026
54733c2
optimize node storage (assumptions vs assertions)
AndreaKe Feb 2, 2026
a12e784
minor fix
AndreaKe Feb 2, 2026
212a37e
combine spec and proof quality computation
AndreaKe Feb 2, 2026
cfd76f6
fix assumption and assertion types
AndreaKe Feb 2, 2026
07cc814
progress computation optimizations (removing internal nodes, node maps)
AndreaKe Feb 4, 2026
b482ccd
infeasible paths: optimizations
AndreaKe Feb 9, 2026
81b25c0
update submodules
AndreaKe Feb 9, 2026
0a2bd2b
fix infeasible path incompleteness bug
AndreaKe Feb 10, 2026
f195487
fix unsoundness bug
AndreaKe Feb 10, 2026
722f36c
TMP: run pipeline with DA enabled
AndreaKe Feb 10, 2026
c2bf37e
Revert "TMP: run pipeline with DA enabled"
AndreaKe Feb 10, 2026
35ede49
make DA more precise for magic wands
AndreaKe Feb 11, 2026
662685b
fix graph export (edges)
AndreaKe Feb 11, 2026
5b678f7
(WIP) fix chunk nodes
AndreaKe Feb 11, 2026
1874235
minor fix
AndreaKe Feb 12, 2026
c4d6f44
add test case for infeasible paths
AndreaKe Feb 12, 2026
187238d
fix missing dependency types
AndreaKe Feb 12, 2026
3b2a0ea
fix graph join for frontends
AndreaKe Feb 14, 2026
eb695ee
minor fixes
AndreaKe Feb 24, 2026
9afa0cd
add more profiling instrumentation
AndreaKe Feb 24, 2026
23c3c31
add enableUnsatCore config option
AndreaKe Feb 27, 2026
5b9d5d2
fix for gobra interfaces
AndreaKe Feb 27, 2026
62e7dcf
cherry-pick silicon PR #961
jcp19 Feb 27, 2026
ae05d01
implement graph importer as a stand-alone program
AndreaKe Feb 27, 2026
71c0899
Merge remote-tracking branch 'origin/keuscha/assumption_analysis_prof…
AndreaKe Feb 27, 2026
6fe9365
add command line arguments to graph importer
AndreaKe Feb 28, 2026
18b0939
cleanup smoke checks
AndreaKe Feb 28, 2026
2a5fa17
cleanup fix for Gobra interfaces (custom join nodes)
AndreaKe Mar 2, 2026
19f6dad
handle join nodes in function verification unit
AndreaKe Mar 2, 2026
977c980
optimize graph export
AndreaKe Mar 2, 2026
f72b6c1
comment out profiling artifacts for progress metric
AndreaKe Mar 2, 2026
1881e4d
minor fix regarding join nodes
AndreaKe Mar 2, 2026
4e8df60
fix guidance
AndreaKe Mar 2, 2026
e350606
attempt to automatically determine minimal dependencies for precision…
AndreaKe Mar 3, 2026
e7e15de
fix guidance (function bodies)
AndreaKe Mar 3, 2026
ee7bb0a
minor fix, function bodies -> verification annotation
AndreaKe Mar 3, 2026
c53794d
fix Gobra method and function postcondition types
AndreaKe Mar 3, 2026
4360244
fix Gobra method and function postcondition types
AndreaKe Mar 4, 2026
06316d7
improve guidance by estimating impact of assumptions on Lea's progres…
AndreaKe Mar 5, 2026
0ccddd1
fix div by 0 in progress computation
AndreaKe Mar 5, 2026
485a2ce
fix function axiom annotations
AndreaKe Mar 6, 2026
1af15bc
add getMaxPriorityType
AndreaKe Mar 6, 2026
addf001
fix dependency type annotations for Gobra
AndreaKe Mar 7, 2026
29457ba
fix dependency type annotations for Gobra
AndreaKe Mar 7, 2026
88532c1
fix infinite loop in progress computation
AndreaKe Mar 7, 2026
ac929ff
optimize graph joins
AndreaKe Mar 8, 2026
ec340c8
handle impure assertion failures
AndreaKe Mar 9, 2026
47e551d
add support for verification failures
AndreaKe Mar 9, 2026
cc6a430
minor fix for verification failure handling
AndreaKe Mar 9, 2026
1857b71
annotate imported methods
AndreaKe Mar 10, 2026
ae769dd
treat ghost code identical to normal code
AndreaKe Mar 10, 2026
392473c
adjust progress and guidance for abstract and imported methods
AndreaKe Mar 10, 2026
bedaee1
nodes with failed obligations are always explicit assumptions
AndreaKe Mar 10, 2026
73fcd94
fix spec quality computation
AndreaKe Mar 11, 2026
bc73399
minor fix for verification failures
AndreaKe Mar 11, 2026
815b844
add precision eval query
AndreaKe Mar 11, 2026
f2c95bc
add annotate query
AndreaKe Mar 11, 2026
c36fe68
update precisionEval query
AndreaKe Mar 12, 2026
ce03dff
fix precision test case annotation helper
AndreaKe Mar 12, 2026
d2f2a28
fix precision eval query
AndreaKe Mar 12, 2026
373d60e
update precision evaluation query
AndreaKe Mar 15, 2026
ae88f7a
fixes for interfaces
AndreaKe Mar 15, 2026
f01110a
update precision evaluation query for gobra
AndreaKe Mar 15, 2026
2a7124a
fix for gobra interfaces
AndreaKe Mar 16, 2026
4242846
fix method call without assumptions
AndreaKe Mar 16, 2026
fe79c63
fix for preconditions
AndreaKe Mar 17, 2026
ac356df
make interprocedural dependencies context-sensitive
AndreaKe Mar 17, 2026
c95a2fd
refactoring
AndreaKe Mar 23, 2026
43501c3
create DependencyAnalysisInfo and propagate it
AndreaKe Mar 25, 2026
21658db
create DependencyAnalysisInfoes
AndreaKe Mar 30, 2026
9862a5a
refactor dependency type
AndreaKe Mar 30, 2026
206e326
refactor join info
AndreaKe Mar 30, 2026
df9c515
fix
AndreaKe Mar 30, 2026
2d96e53
fix merge info
AndreaKe Mar 30, 2026
6560e2c
fix join
AndreaKe Mar 31, 2026
8c405ea
refactoring
AndreaKe Mar 31, 2026
2d4dd16
fix axioms
AndreaKe Mar 31, 2026
900af54
cleanup
AndreaKe Mar 31, 2026
620003d
renaming
AndreaKe Mar 31, 2026
4cdbeea
cleanup warnings
AndreaKe Mar 31, 2026
6475012
refactoring
AndreaKe Mar 31, 2026
89bfa03
collect DependencyAnalysisInfos only if DA is enabled
AndreaKe Mar 31, 2026
8b53c22
fix
AndreaKe Mar 31, 2026
080116a
fix Silicon DA tests
AndreaKe Apr 8, 2026
38e479f
update silver submodule
AndreaKe Apr 8, 2026
30d9bb3
add DependencyGraphState
AndreaKe Apr 8, 2026
f995ad4
fix tests
AndreaKe Apr 9, 2026
dd148b8
fix graph export
AndreaKe Apr 9, 2026
7fd6ccb
make method calls more precise by separating it from argument evaluation
AndreaKe Apr 9, 2026
d5609a1
make function calls more precise by separating it from argument evalu…
AndreaKe Apr 9, 2026
5f352b2
add test case for join precision
AndreaKe Apr 9, 2026
f869afc
refactor interpreter and user tool
AndreaKe Apr 9, 2026
d5f2fa5
refactor interpreter and user tool
AndreaKe Apr 10, 2026
329e7dc
fix tests
AndreaKe Apr 10, 2026
7ed0918
fix state consolidation
AndreaKe Apr 10, 2026
9f7f356
fix for method and function calls
AndreaKe Apr 10, 2026
5cf82c0
add some documentation
AndreaKe Apr 10, 2026
505944c
fix tests
AndreaKe Apr 10, 2026
6c69f8b
add documentation and cleanup unused code
AndreaKe Apr 10, 2026
4ae1874
adapt Gobra DA implementation to new design
AndreaKe Apr 10, 2026
86c8f93
update submodules
AndreaKe Apr 10, 2026
a195706
adapt solution for Gobra interfaces
AndreaKe Apr 10, 2026
69c7064
fixes
AndreaKe Apr 12, 2026
bcbe1b6
fix infeasibility node
AndreaKe Apr 12, 2026
d6eec6b
fix withMeta for BackendFuncApp
AndreaKe Apr 20, 2026
8bc735d
fix withMeta for Adt plugin
AndreaKe Apr 20, 2026
61c8fa6
fix DA tests
AndreaKe Apr 21, 2026
edf51da
fix dependency queries regarding join edges
AndreaKe Apr 21, 2026
567c480
refactor dependency queries
AndreaKe Apr 21, 2026
7fd1213
refactor progress and pruning supporter
AndreaKe Apr 21, 2026
a501721
print warnings when DA info is missing
AndreaKe Apr 23, 2026
f84414a
do not collect builtin axioms
AndreaKe Apr 23, 2026
c80c852
Add flags for VSC extension
DovydasVad Mar 20, 2026
bf7211a
mark infeasibility checks at branches as internal
AndreaKe May 7, 2026
de0c85b
ignore preconditions for progress and guidance
AndreaKe May 8, 2026
0548f80
fix join nodes on infeasible paths
AndreaKe May 8, 2026
49d90fd
add assertionTypes query
AndreaKe May 8, 2026
9c469a5
create one node per top-level conjuncts for assertions
AndreaKe May 8, 2026
b2bd2bd
clean up silver
AndreaKe May 12, 2026
52c63db
clean up silver
AndreaKe May 12, 2026
bcc8d7e
remove benchmark artifacts
AndreaKe May 12, 2026
395e36f
clean up silver
AndreaKe May 12, 2026
bf8b403
clean up silicon
AndreaKe May 12, 2026
c065adf
clean up silicon
AndreaKe May 12, 2026
da0fe07
clean up DA tests
AndreaKe May 12, 2026
142af18
fix implication in combination with infeasibility
AndreaKe May 12, 2026
8f6668d
add tests for node types and dependencies (for Silicon and Gobra)
AndreaKe May 13, 2026
662c1c4
minor fix
AndreaKe May 13, 2026
8be7baa
redesign annotated tests
AndreaKe May 14, 2026
39958bc
fix failing tests
AndreaKe May 19, 2026
92cf5db
merge silver/master
AndreaKe May 26, 2026
1b0c791
merge silver/master
AndreaKe May 26, 2026
521979f
Merge branch 'master' into keuscha/dependency_analysis_refactoring
AndreaKe May 26, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
141 changes: 137 additions & 4 deletions src/main/scala/Config.scala
Original file line number Diff line number Diff line change
Expand Up @@ -6,16 +6,17 @@

package viper.silicon

import java.nio.file.{Files, Path, Paths}
import scala.collection.immutable.ArraySeq
import scala.util.matching.Regex
import scala.util.Properties._
import org.rogach.scallop._
import viper.silicon.Config.JoinMode.JoinMode
import viper.silicon.Config.StateConsolidationMode.StateConsolidationMode
import viper.silicon.decider.{Cvc5ProverStdIO, Z3ProverAPI, Z3ProverStdIO}
import viper.silver.frontend.SilFrontendConfig

import java.nio.file.{Files, Path, Paths}
import scala.collection.immutable.ArraySeq
import scala.util.Properties._
import scala.util.matching.Regex

class Config(args: Seq[String]) extends SilFrontendConfig(args, "Silicon") {
import Config._

Expand Down Expand Up @@ -691,6 +692,78 @@ class Config(args: Seq[String]) extends SilFrontendConfig(args, "Silicon") {
noshort = true
)

val startDebuggerAutomatically: ScallopOption[Boolean] = opt[Boolean]("startDebuggerAutomatically",
descr = "Starts the debugging mode automatically after verification completes",
default = Some(false),
noshort = true
)

val enableDependencyAnalysis: ScallopOption[Boolean] = opt[Boolean]("enableDependencyAnalysis",
descr = "Enable dependency analysis mode",
default = Some(false),
noshort = true
)

val enableDependencyAnalysisDebugging: ScallopOption[Boolean] = opt[Boolean]("enableDependencyAnalysisDebugging",
descr = "Enable debugging for dependency analysis mode",
default = Some(false),
noshort = true
)

val disableInfeasibilityChecks: ScallopOption[Boolean] = opt[Boolean]("disableInfeasibilityChecks",
descr = "Disable infeasibility checks. As a consequence all paths will be explored to the end. (Potentially) huge performance overhead!",
default = Some(false),
noshort = true
)

val dependencyAnalysisExportPath: ScallopOption[String] = opt[String]("dependencyAnalysisExportPath",
descr = "Path to the directory where the dependency analysis graphs should be exported to",
default = None,
noshort = true
)

val startDependencyAnalysisTool: ScallopOption[Boolean] = opt[Boolean]("startDependencyAnalysisTool",
descr = "Starts the dependency analysis command line tool after verification",
default = Some(false),
noshort = true
)

val executeDependencyAnalysisTests: ScallopOption[Boolean] = opt[Boolean]("executeDependencyAnalysisTests",
descr = "Automatically executes dependency analysis tests",
default = Some(false),
noshort = true
)

val enableUnsatCores: ScallopOption[Boolean] = opt[Boolean]("enableUnsatCores",
descr = "Enables UNSAT cores",
default = Some(false),
noshort = true
)

val pruneLines: ScallopOption[List[Int]] = opt[List[Int]]("pruneLines",
descr = "Line numbers to prune the program with respect to. Part of the dependency analysis tool.",
default = None,
noshort = true
)

val pruneExportFileName: ScallopOption[String] = opt[String]("pruneExportFileName",
descr = "Export file name for the pruned program (used with --pruneLines)",
default = Some("prunedExport.vpr"),
noshort = true
)

val computeVerificationProgress: ScallopOption[Boolean] = opt[Boolean]("computeVerificationProgress",
descr = "Computes verification progress of the program",
default = Some(false),
noshort = true
)

val computeVerificationProgressFileName: ScallopOption[String] = opt[String]("computeVerificationProgressFileName",
descr = "Export file name for the verification progress output (used with --computeVerificationProgress)",
default = Some("progressExport.vpr"),
noshort = true
)

/* Option validation (trailing file argument is validated by parent class) */

validateOpt(prover) {
Expand Down Expand Up @@ -738,6 +811,66 @@ class Config(args: Seq[String]) extends SilFrontendConfig(args, "Silicon") {
validateFileOpt(multisetAxiomatizationFile)
validateFileOpt(sequenceAxiomatizationFile)

validateOpt(enableDependencyAnalysis, parallelizeBranches) {
case (Some(false), _) => Right(())
case (_, Some(false)) => Right(())
case (Some(true), Some(true)) =>
Left(s"Option ${enableDependencyAnalysis.name} is not supported in combination with ${parallelizeBranches.name}")
case other =>
sys.error(s"Unexpected combination: $other")
}

validateOpt(rawProverArgs, enableDependencyAnalysis) {
case (_, Some(false)) => Right(())
case (Some(args), Some(true)) if args.contains("proof=true") && args.contains("unsat-core=true") => Right(())
case (_, _) =>
Left(s"Option ${enableDependencyAnalysis.name} requires ${rawProverArgs.name} with \"proof=true unsat-core=true\"")
}

validateOpt(dependencyAnalysisExportPath, enableDependencyAnalysis) {
case (None, _) => Right(())
case (Some(_), Some(true)) => Right(())
case (Some(_), Some(false)) =>
Left(s"Option ${dependencyAnalysisExportPath.name} requires option ${enableDependencyAnalysis.name}")
}

validateOpt(executeDependencyAnalysisTests, enableDependencyAnalysis) {
case (Some(false), _) => Right(())
case (_, Some(true)) => Right(())
case (_, _) =>
Left(s"Option ${executeDependencyAnalysisTests.name} requires option ${enableDependencyAnalysis.name}")
}

validateOpt(startDependencyAnalysisTool, enableDependencyAnalysis) {
case (Some(false), _) => Right(())
case (_, Some(true)) => Right(())
case (_, _) =>
Left(s"Option ${startDependencyAnalysisTool.name} requires option ${enableDependencyAnalysis.name}")
}

validateOpt(pruneLines, enableDependencyAnalysis) {
case (None, _) => Right(())
case (Some(_), Some(true)) => Right(())
case (Some(_), _) =>
Left(s"Option ${pruneLines.name} requires option ${enableDependencyAnalysis.name}")
}

validateOpt(computeVerificationProgress, enableDependencyAnalysis) {
case (Some(false), _) => Right(())
case (_, Some(true)) => Right(())
case (_, _) =>
Left(s"Option ${computeVerificationProgress.name} requires option ${enableDependencyAnalysis.name}")
}

validateOpt(startDebuggerAutomatically, enableDebugging) {
case (Some(false), _) => Right(())
case (Some(true), Some(true)) => Right(())
case (Some(true), Some(false)) =>
Left(s"Option ${startDebuggerAutomatically.name} requires option ${enableDebugging.name}")
case other =>
sys.error(s"Unexpected combination: $other")
}

/* Finalise configuration */

verify()
Expand Down
21 changes: 10 additions & 11 deletions src/main/scala/Silicon.scala
Original file line number Diff line number Diff line change
Expand Up @@ -6,27 +6,26 @@

package viper.silicon

import java.text.SimpleDateFormat
import java.util.concurrent.{Callable, Executors, TimeUnit, TimeoutException}
import scala.collection.immutable.ArraySeq
import scala.util.{Left, Right}
import ch.qos.logback.classic.{Level, Logger}
import com.typesafe.scalalogging.LazyLogging
import org.slf4j.LoggerFactory
import viper.silver.ast
import viper.silver.frontend.{DefaultStates, MinimalViperFrontendAPI, SilFrontend, ViperFrontendAPI}
import viper.silver.reporter._
import viper.silver.verifier.{AbstractVerificationError => SilAbstractVerificationError, Failure => SilFailure, Success => SilSuccess, TimeoutOccurred => SilTimeoutOccurred, VerificationResult => SilVerificationResult, Verifier => SilVerifier}
import viper.silicon.decider.{Cvc5ProverStdIO, Z3ProverStdIO}
import viper.silicon.interfaces.Failure
import viper.silicon.logger.{MemberSymbExLogger, SymbExLogger}
import viper.silicon.reporting.{MultiRunRecorders, condenseToViperResult}
import viper.silicon.verifier.DefaultMainVerifier
import viper.silicon.decider.{Cvc5ProverStdIO, Z3ProverStdIO}
import viper.silver.ast
import viper.silver.cfg.silver.SilverCfg
import viper.silver.frontend.{DefaultStates, MinimalViperFrontendAPI, SilFrontend, ViperFrontendAPI}
import viper.silver.logger.ViperStdOutLogger
import viper.silver.utility.{FileProgramSubmitter}
import viper.silver.reporter._
import viper.silver.utility.FileProgramSubmitter
import viper.silver.verifier.{AbstractVerificationError => SilAbstractVerificationError, Failure => SilFailure, Success => SilSuccess, TimeoutOccurred => SilTimeoutOccurred, VerificationResult => SilVerificationResult, Verifier => SilVerifier}

import scala.util.chaining._
import java.text.SimpleDateFormat
import java.util.concurrent.{Callable, Executors, TimeUnit, TimeoutException}
import scala.collection.immutable.ArraySeq
import scala.util.{Left, Right}

object Silicon {
val name = BuildInfo.projectName
Expand Down
5 changes: 3 additions & 2 deletions src/main/scala/debugger/DebugParser.scala
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ package viper.silicon.debugger

import fastparse._
import viper.silver.ast._
import viper.silver.dependencyAnalysis.DependencyType
import viper.silver.parser._

import scala.collection.mutable
Expand Down Expand Up @@ -36,7 +37,7 @@ class DebugParser extends FastParser {

class DebugTranslator(p: PProgram, override val members: mutable.Map[String, Node]) extends Translator(p) {

override protected def expInternal(pexp: PExp, pos: PExp, info: Info): Exp = {
override protected def expInternal(pexp: PExp, pos: PExp, info: Info, dependencyType: Option[DependencyType]): Exp = {
pexp match {
case pviu@PVersionedIdnUseExp(_, _, _) =>
pexp.typ match {
Expand All @@ -45,7 +46,7 @@ class DebugTranslator(p: PProgram, override val members: mutable.Map[String, Nod
}
case PDebugLabelledOldExp(_, lbl, e) =>
DebugLabelledOld(exp(e), lbl.versionedName)(pos, info)
case _ => super.expInternal(pexp, pos, info)
case _ => super.expInternal(pexp, pos, info, dependencyType)
}
}

Expand Down
7 changes: 4 additions & 3 deletions src/main/scala/debugger/SiliconDebugger.scala
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ package viper.silicon.debugger

import viper.silicon.common.collections.immutable.InsertionOrderedSet
import viper.silicon.decider.{Cvc5ProverStdIO, RecordedPathConditions, Z3ProverStdIO}
import viper.silicon.dependencyAnalysis.DependencyAnalysisInfos
import viper.silicon.interfaces.state.Chunk
import viper.silicon.interfaces.{Failure, SiliconDebuggingFailureContext, Success, VerificationResult}
import viper.silicon.resources.{FieldID, PredicateID}
Expand Down Expand Up @@ -270,7 +271,7 @@ class SiliconDebugger(verificationResults: List[VerificationResult],
}

private def initVerifier(obl: ProofObligation, proverName: String, userArgsString: Option[String]): ProofObligation = {
val v = new WorkerVerifier(this.mainVerifier, obl.v.uniqueId, NoopReporter, false)
val v = new WorkerVerifier(this.mainVerifier, "debugger_01", NoopReporter, false)
counter += 1
v.start()
v.decider.createProver(proverName, userArgsString)
Expand Down Expand Up @@ -430,7 +431,7 @@ class SiliconDebugger(verificationResults: List[VerificationResult],
var resE: ast.Exp = null
var resV: Verifier = null
val pve: PartialVerificationError = PartialVerificationError(r => ContractNotWellformed(assertionE, r))
val verificationResult = evaluator.eval3(obl.s, assertionE, pve, obl.v)((_, t, newE, newV) => {
val verificationResult = evaluator.eval3(obl.s, assertionE, pve, obl.v, DependencyAnalysisInfos.DefaultDependencyAnalysisInfos)((_, t, newE, newV) => {
resT = t
resE = newE.get
resV = newV
Expand Down Expand Up @@ -497,7 +498,7 @@ class SiliconDebugger(verificationResults: List[VerificationResult],
var evalPcs: RecordedPathConditions = null
val pve: PartialVerificationError = PartialVerificationError(r => ContractNotWellformed(e, r))
val beforeEval = v.decider.setPathConditionMark()
val verificationResult = evaluator.eval3(obl.s, e, pve, v)((newS, t, newE, newV) => {
val verificationResult = evaluator.eval3(obl.s, e, pve, v, DependencyAnalysisInfos.DefaultDependencyAnalysisInfos)((newS, t, newE, newV) => {
resS = newS
resT = t
resE = newE.get
Expand Down
7 changes: 4 additions & 3 deletions src/main/scala/decider/CVC5ProverStdIO.scala
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,13 @@

package viper.silicon.decider

import java.nio.file.{Path, Paths}
import viper.silicon.common.config.Version
import viper.silicon.state.IdentifierFactory
import viper.silicon.verifier.Verifier
import viper.silver.verifier.{DefaultDependency => SilDefaultDependency}
import viper.silver.reporter.Reporter
import viper.silicon.common.config.Version
import viper.silver.verifier.{DefaultDependency => SilDefaultDependency}

import java.nio.file.{Path, Paths}

object Cvc5ProverStdIO {
val name = "cvc5"
Expand Down
Loading