6 ms·
Debug symbol size shouldn't be influencing relocation jump distances - debug info has its own ELF section. Regardless of whether you're FAANG or not, nothing y
by 10000truths 10mo ago
Debug symbol size shouldn't be influencing relocation jump distances - debug info has its own ELF section.
Regardless of whether you're FAANG or not, nothing you're running should require an executable with a 2 GB large .text section. If you're bumping into that limit, then your build process likely lacks dead code elimination in the linking step. You should be using LTO for release builds. Even the traditional solution (compile your object files with -ffunction-sections and link with --gc-sections) does a good job of culling dead code at function-level granularity.
- yablak 10mo agoFAANGs we're deeply involved in designing LTO. See, e.g., https://research.google/pubs/thinlto-scalable-and-incremental-lto/ https://research.google/pubs/thinlto-scalable-and-incrementa... And other refs. And yet...
- jeffbee 10mo agoGoogle also uses identical code folding. It's a pretty silly idea that a shop that big doesn't know about the compiler flags.
- Orphis 10mo agoGoogle is made of many thousands of individuals. Some experts will be aware of all those, some won't. In my team, many didn't know about those details as they were handled by other builds teams for specific products or entire domains at once. But since each product in some different domains had to actively enable those optimizations for themselves, they were occasionally forgotten, and I found a few in the app I worked for (but not directly on).
- jeffbee 10mo agoICF seems like a good one to keep in the box of flags people don't know about because like everything in life it's a tradeoff and keeping that one problematic artifact under 2GiB is pretty much the only non-debatable use case for it.
- saagarjha 10mo agoGoogle Chrome ships as a 500 MB binary on my machine, so if you're embedding a web browser, that's how much you need minimum. Now tack on whatever else your application needs and it's easy to see how you can go past 2 GB if you're not careful. (To be clear, I am not making a moral judgment here, I am just saying it's possible to do. Whether it should happen is a different question.)
- throwawaymobule 10mo agoDo you have some special setup? Chromium is in the hundred and something MB range on mine last I looked. Might expand to more on install.
- saagarjha 10mo agoI just checked Google Chrome Framework on my Mac, it was a little over 400 MB. Although now that I think about it it's probably a universal binary so you can cut that in half?
- deleted 10mo ago[deleted]