DescriptionDeinline PartitionAlloc from DefaultAllocator to reduce code size
DefaultAllocator calls PartitionAlloc functions from inline methods.
PartitionAlloc consist of always inline functions. This result in a huge
code bloat as DefaultAllocator is used as template argument in wtf templatized
containers. We only need to do the allocation via PartitionAlloc directly when
the container's buffer is created or resized so it doesn't seem to worth the
cost in code size to inline them.
This patch reduced the size of content_shell in my static release build with ~0.5 megabyte.
Reference size: 84514K, 61492K after stripping. Patched: 84083K and 61052K.
This is neutral on Android where -Os already does a good job and deny to inline.
I think we can rely on the performance bots to make sure that this doesn't result in performance regression.
Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=173243
Patch Set 1 #Patch Set 2 : typo fix #Patch Set 3 : fix linking by properly exporting symbols #
Messages
Total messages: 11 (0 generated)
|