Reordering data constructors of IntSet and IntMap.
The order of constructors of IntSet and IntMap matters when considering
performance. Currently in GHC 7.0, when type has 3 constructors, they
are matched from the first to the last -- the best performance is
achieved when the constructors are ordered by frequency.
On GHC 7.0, reordering constructors from Nil | Tip | Bin to Bin | Tip |
Nil
improves the containers_benchmark
- by 9.5% on x86 and by 8% on x86_64 for IntMap
- by 11% on x86 and by 9% on x86_64 for IntSet
The performance should never decrease for any architecture.
Is that an example in line with
http://hackage.haskell.org/trac/ghc/ticket/849 ?
If yes, you might want to mention it there.
Claus
_______________________________________________
Cvs-ghc mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/cvs-ghc