Skip to content

--cores flag is detrimental to performance #2562

@facundominguez

Description

@facundominguez

The --cores flag specifies how many cores should be used to check verification conditions. It is set by default to Nothing, meaning that the implementation will try to assign verification conditions to different processors as it sees fit.

I have found an example recently where verification with --cores=1, that is no parallelism, is faster than verification with parallelism (the default setting). The improvement is significant as verification with parallelism requires twice as long as no parallelism.

I decided to benchmark the flag against the testsuite. If I make --cores=1 the default, a couple of benchmarks improve considerably.

It would be interesting to know if someone has a larger example where parallelism makes a substantial improvement (say in the order of minutes).

The benchmark framework is measuring CPU time at the moment. To have conclusive results we should be measuring wall-clock time instead. I manually checked the Base and the Fusion/T benchmarks below and they are faster with no parallelism even when measured with wall-clock time.

Benchmark results follow. "before" is with parallelism, "after" is without.

Image
Image

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions