@@ -253,13 +253,8 @@ object executor extends ExecutionRules {
253253 phase1data = phase1data :+ (s1,
254254 v1.decider.pcs.after(mark),
255255 v1.decider.freshFunctions /* [BRANCH-PARALLELISATION] */ )
256- v1.decider.prover.comment(" Loop head block: Check well-definedness of edge conditions" )
257- edgeConditions.foldLeft(Success (): VerificationResult ) {
258- case (result, _) if ! result.continueVerification => result
259- case (intermediateResult, eCond) =>
260- intermediateResult combine executionFlowController.locally(s1, v1)((s2, v2) => {
261- eval(s2, eCond, WhileFailed (eCond), v2)((_, _, _) =>
262- Success ())})}})})
256+ Success ()
257+ })})
263258 combine executionFlowController.locally(s, v)((s0, v0) => {
264259 v0.decider.prover.comment(" Loop head block: Establish invariant" )
265260 consumes(s0, invs, LoopInvariantNotEstablished , v0)((sLeftover, _, v1) => {
@@ -276,8 +271,19 @@ object executor extends ExecutionRules {
276271 Success ()
277272 else {
278273 execs(s3, stmts, v2)((s4, v3) => {
274+ val edgeCondWelldefinedness = {
275+ v1.decider.prover.comment(" Loop head block: Check well-definedness of edge conditions" )
276+ edgeConditions.foldLeft(Success (): VerificationResult ) {
277+ case (result, _) if ! result.continueVerification => result
278+ case (intermediateResult, eCond) =>
279+ intermediateResult combine executionFlowController.locally(s4, v3)((s5, v4) => {
280+ eval(s5, eCond, WhileFailed (eCond), v4)((_, _, _) =>
281+ Success ())
282+ })
283+ }
284+ }
279285 v3.decider.prover.comment(" Loop head block: Follow loop-internal edges" )
280- follows(s4, sortedEdges, WhileFailed , v3, joinPoint)(Q )})}})}})}))
286+ edgeCondWelldefinedness combine follows(s4, sortedEdges, WhileFailed , v3, joinPoint)(Q )})}})}})}))
281287
282288 case _ =>
283289 /* We've reached a loop head block via an edge other than an in-edge: a normal edge or
0 commit comments