-
Notifications
You must be signed in to change notification settings - Fork 28
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
While looking at the memory allocation patterns under OSX's Instruments, I noticed that everything about ExpressionPieces spams the allocator. We create a really large number of temporary objects, and because of the way ObjRangeAdapter and friends work, we also clone these things for every subcommand we send. This changes ExpressionPiece from being an object hierarchy to one single object implemented with a union underneath. We can now have vectors of ExpressionPieces which should help locality. Allocating ExpressionPieces and vector<>s of ExpressionPieces no longer shows up as a hotspot on Instruments.
- Loading branch information
Showing
19 changed files
with
942 additions
and
900 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.