“What Has My Compiler Done for Me Lately? Unbolting the Compiler's Lid”
summary
A quick history and demo: a 2012 bash script grows into Compiler Explorer, a Node.js site that pipes user code to many compilers (GCC/Clang/MSVC via Docker on AWS) and returns assembly, diffs and a CFG beta. Concrete wins shown: range-for compiles to the same 10–14 instructions as indexed loops, compilers replace hand shifts with lea and multiply tricks, eliminate divides via magic constants, use popcnt and turn O(n) summations into O(1). Site costs ≈$150–200/month and runs cached, public compiler images, with execution and more languages planned.
AI-written summary · about
chapters (15)
- 0:00Introduction and background
- 1:05Why learn assembly?
- 4:22Compiler Explorer origin
- 7:35X86 assembly overview
- 14:51Range-based for loops
- 20:13Vector optimization analysis
- 28:29Multiplication optimization
- 32:54Division and modulus
- 37:08Hash map optimizations
- 39:39Bit counting tricks
- 42:15Closed-form solutions
- 47:31Building Compiler Explorer
- 53:12Security challenges
- 58:25Future developments
- 1:03:18Q&A and concluding remarks
related talks
01h 00mJust Enough Assembly for Compiler Explorer
59mCompilers can be surprising
01h 04mCompiler Bugs And Bug Compilers
01h 03mJust Enough Assembly for Compiler Explorer
21mGetting the Most Bang out of your Buck with Compilers on POWER
10mA quick view into a compiler
46mWhat C and C++ can do and when do you need Assembly?
01h 25mPeeking Into Your Compiler
