-
Notifications
You must be signed in to change notification settings - Fork 0
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
Performance tests #121
Performance tests #121
Conversation
What's the point of storing the expected IL output too? It isn't used for anything here and seems completely redundant since it is just going to be the same information as the final output. I also think that something like that |
Its necessary for some examples to verify (though none of the test cases we have currently) and just gives worse performance for others, I think we want to keep both around at this stage. But yes it could have been its own PR. |
Can you explain about storing the IL output? |
Yeah that's not particularly useful at this point, my thinking was its so when we have more in-place transformation of the IR we have history in case of regressions. |
I don't see any point in including it right now, it's just unnecessary bloat and any regressions will be visible in the Boogie output. |
src/test/scala/SystemTests.scala
Outdated
val csvHeader = "passed,verified,shouldVerify,hasExpected,timedOut,matchesExpected,translateTime,verifyTime" | ||
} | ||
|
||
val testResults: mutable.Map[String, TestResult] = mutable.HashMap() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there a reason for using a Map here, given that it means the output isn't ordered, which is much less convenient? It doesn't seem like we care about the constant lookup time?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Uses an ArrayBuffer now
src/test/scala/SystemTests.scala
Outdated
Main.main(Array("--adt", ADTPath, "--relf", RELFPath, "--spec", specPath, "--output", outPath)) | ||
Main.main(Array("--adt", ADTPath, "--relf", RELFPath, "--spec", specPath, "--output", outPath, "--dump-il", ilPath)) | ||
} else { | ||
Main.main(Array("--adt", ADTPath, "--relf", RELFPath, "--output", outPath)) | ||
Main.main(Array("--adt", ADTPath, "--relf", RELFPath, "--output", outPath, "--dump-il", ilPath)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not really useful right now, as mentioned
build.sbt
Outdated
if (ILOutPath.exists() && !(ILExpectedPath.exists() && filesContentEqual(ILExpectedPath, ILOutPath))) { | ||
IO.copyFile(ILOutPath, ILExpectedPath) | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also unnecessary right now
# Conflicts: # src/main/scala/boogie/BProgram.scala # src/main/scala/translating/IRToBoogie.scala
src/test/scala/SystemTests.scala
Outdated
if (verifying.nonEmpty) | ||
info(s"Average time to verify: ${verifying.sum / verifying.size}") | ||
if (counterExamples.nonEmpty) | ||
info(s"Average time to counterexample: ${counterExamples.sum/ counterExamples.size}") | ||
|
||
val summaryHeader = "verifiedCount,counterexampleCount,timeoutCount,verifyTotalTime,counterexampleTotalTime" | ||
val summaryRow = s"$numVerified,${counterExamples.size},$numTimeout,${verifying.sum},${counterExamples.sum}" | ||
val summaryRow = s"$numSuccess,${counterExamples.size},$numTimeout,${verifying.sum},${counterExamples.sum}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wanted verifyTotalTime/verifyCount = mean verify time. scalaTest already tells you how many tests passed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'll just make the summary include both things.
Change summary:
--boogie-use-lambda-stores
to generate the lambda definition for >8bit stores, rather than the nested MemOp definition, this gives reasonable performance without ArrayAxioms.Breaking changes:
With defaults MemOps and ArrayAxioms:
With lambdas and array theories: