News for hackers. Stuff that matters.
Re:Make Ubuntu packages 90% faster by rebuilding them by dan-robertson on Tuesday March 18, 2025 @09:01PM (#43407212)
Debug symbols do not need to be paged in so shouldn’t make much/any difference. Compiling with -O3 can increase code size a lot due to inlining, which can be a little bad.
Re:Make Ubuntu packages 90% faster by rebuilding them by taeric on Wednesday March 19, 2025 @12:12AM (#43408212)
Right, my humor there was that I'm assuming people specifically did non-debug flags for the build as an optimization. Only for them to still fall short.

And understood a little on -O3 possibly increasing code size. I had thought that was more of a concern for tight environments than for most systems? Of course, I'd have assumed that -march=native would be more impactful, but the post indicates otherwise.

I said in a top level, but it seems the allocator makes the biggest impact for this application? Would be interesting to see which applications should use different allocators. Would be amazing to see a system where the more likely optimal allocator was default for different applications, based on their typical allocation patterns.

Re:Make Ubuntu packages 90% faster by rebuilding them by turol on Wednesday March 19, 2025 @03:04AM (#43408989)
> Right, my humor there was that I'm assuming people specifically did non-debug flags for the build as an optimization.

It used to be the case that the presence of debug symbols would affect GCC code generation. Nowadays that should be fixed. I think it still affects the speed of compilation so if you're building the whole system from source you might want to avoid it.

Re:Make Ubuntu packages 90% faster by rebuilding them by SkiFire13 on Wednesday March 19, 2025 @08:06AM (#43410831)
> And understood a little on -O3 possibly increasing code size. I had thought that was more of a concern for tight environments than for most systems?

Increasing code size too much can result in hot functions not fitting in the icache, and that ultimately can make your program slower.

Re:Make Ubuntu packages 90% faster by rebuilding them by pests on Tuesday March 18, 2025 @11:58PM (#43408162)
Mario 64 gets flak for some files not being compiled with optimizations on. There is a YouTuber, whose name I forget at the moment, who has been doing optimization and improvements on it and constantly talks about how this is for the better due to the low instruction cache size and slow speed on the console. Compiling with optimizations explodes code size (unrolling links, inlining, etc) to the point it’s a net loss after factoring in the increased load on the IC.
Re:Make Ubuntu packages 90% faster by rebuilding them by chasil on Wednesday March 19, 2025 @04:52AM (#43409588)
The -Os flag optimizes for size.

What impact does that have?

Re:Make Ubuntu packages 90% faster by rebuilding them by rurban on Wednesday March 19, 2025 @09:21AM (#43411594)
The IC is the instruction cache. Bloated code needs more slow loads from the IC, and even if the performance is faster per cache line, the 50x overhead of added cache loads diminishes all -O3 advantages.
Re:Make Ubuntu packages 90% faster by rebuilding them by tjalfi on Wednesday March 19, 2025 @02:54PM (#43415959)
Kaze Emanuar[0] is the YouTuber you're thinking of.

[0] https://www.youtube.com/@KazeN64

Re:Make Ubuntu packages 90% faster by rebuilding them by pests on Thursday March 20, 2025 @01:28PM (#43426182)
Yes thank you!