News for hackers. Stuff that matters.
Re:The Art of 64-bit Assembly by slashdave on Saturday August 01, 2026 @12:49PM (#49136026)
Except for some odd corner cases, it is very hard for a good engineer to beat compilers these days (they are very good now). Not to mention, tuning depends on the platform, and often the exact model of chip.
Re:The Art of 64-bit Assembly by Keyframe on Saturday August 01, 2026 @02:15PM (#49136873)
* it is very hard for a good engineer to beat compilers these days (they are very good now).*

I keep hearing this for the last 20 odd years, yet I see evidence to the contrary each and every day. It is hard and honest work though.

Re:The Art of 64-bit Assembly by okanat on Saturday August 01, 2026 @06:51PM (#49139335)
A good engineer isn't a godlike entity who knows all. They know when to bring in assembly and when to be satisfied with C / C++ / Rust compilers and steer the compiler.

Assembly has unique advantages like guaranteed execution duration for cryptography or exact optimization of hot-loop computation.

99% of the even performance-sensive code doesn't need assembly and compilers beat good engineers in this category since API surface is big and complicated. For 1% very hot code or very sensitive code due to execution duration / predictability / throughput, humans usually code better than compilers. This is due to specialization and limited DoF problems that can be solved and optimized to hell.

Re:The Art of 64-bit Assembly by slashdave on Monday August 03, 2026 @12:52AM (#49151343)
Indeed. Compilers do have to make compromises, and it is not possible from code alone to understand the tradeoffs.
Re:The Art of 64-bit Assembly by zero-sharp on Saturday August 01, 2026 @01:07PM (#49136230)
there were two lead developers from FFMPEG on Lex Fridman's youtube channel who talked about performance gain from assembly. They claimed the opposite

https://www.youtube.com/watch?v=IUo0UwZOaRw

Re:The Art of 64-bit Assembly by slashdave on Saturday August 01, 2026 @01:53PM (#49136700)
Yeah, a corner case (streaming) and good developers working very hard.

The original SSE (SIMD) extensions were actually written with this use case in mind. When they first came out, the compilers were awful. They've since caught up.

Re:The Art of 64-bit Assembly by rurban on Sunday August 02, 2026 @01:55PM (#49146693)
Certainly not. Every hand-optimized tight loop or lookup beats every compiler still. Compilers are extremely stupid, and esp. the language designers.