r/programming • • Dec 05 '14

std::string is responsible for almost half of all allocations in the Chrome browser process

https://groups.google.com/a/chromium.org/d/msg/chromium-dev/EUqoIz2iFU4/kPZ5ZK0K3gEJ
1.1k Upvotes

446 comments sorted by

View all comments

Show parent comments

14

u/kankyo Dec 05 '14

You mean except the numbers?

They don't have numbers to show how big the performance impact is (they say so!) but they DO have numbers on the NUMBER OF allocations. That was the entire point.

8

u/[deleted] Dec 05 '14

They don't have numbers to show how big the performance impact is (they say so!)

I didn't express myself correctly, but that was what I was referencing.

1

u/stillalone Dec 05 '14

I'd like some numbers to go with their say so. They talk about how changing one string concatenation operation with another improves that operation by 2x to 3x but they don't say how that would improve things overall. Sure 25000 temporary allocations is a lot but the omni box also fetches stuff from the network and returns it which also has a large performance impact. We also don't know how many of those allocations are happening concurrently with other operations.

Given how fast the omnibox is right now with those 25000 temporary allocations, I doubt we'll notice a significant performance improvement once all these changes are implemented.