ultimate-pa / ultimate

The Ultimate program analysis framework.
https://ultimate-pa.org/
200 stars 41 forks source link

Slow Petri Net Unfolding (the Bumblebee Observations) #448

Open Heizmann opened 5 years ago

Heizmann commented 5 years ago

The Petri net unfolding is at the moment (early Oct 2019) the major bottleneck of the Petri Automizer verifier. The Petri net unfolding seems to be unnecessarily slow.

The following list of observations should help us to discuss improvements.

The Dinosaur Observations:

The Bumblebee Observations:

Heizmann commented 4 years ago
Heizmann commented 4 years ago

Here is now a related, but slightly different kind of analysis. While applying our difference operation to a Petri net and a finite automaton we do not only care about the speed of the algorithm but also about the size of the result. For the sake of simplicity I will measure the size of the Petri net by using the size of its flow relation. Furthermore, I will take the sum of all examples in the materialistic benchmark set although the numbers from lager examples may dominate over the numbers from smaller examples.

Heizmann commented 4 years ago
Heizmann commented 4 years ago
Heizmann commented 4 years ago

Here is now an experiment with the Svcomp20AutomizerConcurrentSpeedBenchmarks testsuite.

The interleaved.log shows that

The Hprof output shows that a major bottleneck of the verification algorithm will be that (as above) RemoveRedundantFlow calls the isRestrictorCondition method very often and this method uses the co-relation of the unfolding.

Heizmann commented 4 years ago
Heizmann commented 4 years ago

Here is another experiment with the Svcomp20AutomizerConcurrentSpeedBenchmarks testsuite, where I compared a version where counterexamples are computed during the difference operation with the version before.

The interleaved.log shows.

Nonetheless, the second version should become the default. (Already implemented by now)

Heizmann commented 2 years ago

I just rerun the materialistic benchmark set on 82f65192ab.

The comparison to benchmark results above hints that our Petri net unfolding became slower in the last two years. The size of the flow relation is however similar.

Algorithm 1: DifferencePairwiseOnDemand (generation of statistics commented) Rumtime: 317s Size: 137121 CsvAutomataOperationStatistics903064416_2022-08-19_18-52-02-170.csv.txt

Algorithm 2: difference "PAIRWISE" Runtime 306s Size: 127558 CsvAutomataOperationStatistics903064416_2022-08-19_18-45-14-078.csv.txt

Heizmann commented 2 years ago

I just rerun the materialistic benchmark set on https://github.com/ultimate-pa/ultimate/commit/b48bd9feeee0f1bfc84257002261e60595ee34c1

The Petri net unfolding became around 35% slower since https://github.com/ultimate-pa/ultimate/commit/82f65192ab58bd843b52489f1859a782c12bfc44

Algorithm 1: DifferencePairwiseOnDemand (generation of statistics commented) Rumtime: 431s Size: 137121 CsvAutomataOperationStatistics903064416_2022-08-25_17-05-42-503.csv

Algorithm 2: difference "PAIRWISE" Runtime 424s Size: 127558 CsvAutomataOperationStatistics17331878_2022-08-25_17-32-09-423.csv