Mentions légales du service

Skip to content

Specialize atomic and sparse sets equality and comparison

For AtomicBitSet, the lack of type annotation caused the generic implementations to be used (the typechecker generalizes before applying the module coercion, and codegen picks the generic code).

For SparseBitSet, a specialized implementation is now used. It should be semantically equivalent to the generic one.

Both optimizations allowed to reduce the runtime by around ~5% when applying the new --list-errors to cca_cpp.mly. Lookahead classes partition refinement was particularly affected. (generic compare function would show up in profile, taking a bit more than 7% of the total run time; it is now down below 1%, while the new implementation performs a bit better).

Merge request reports