-
Notifications
You must be signed in to change notification settings - Fork 43
Best practices & Pitfalls for Viper, Silicon and Carbon
Federico Poli edited this page Feb 21, 2020
·
1 revision
A Viper program takes 190 seconds to verify in Silicon. The CFG looks reasonable, but there are a lot of statements (>1000) and a lot of local variables (>200).
By removing 123 unnecessary <var> := new()
statements the verification time goes from 190s to just 20s -- a big improvement, but it's still a lot. There are still 50 new(..)
statements in the program.
What is the cause of the 10x reduction in verification time (from 190s to 20s)? How to speed up the verification?
Each new()
statement has to ensure that the result is different from any other reference, and this adds quite some overhead. By removing the remaining 50 new()
statements the verification time goes below 8 seconds.