Fastware
summary
Argues that exposing CPU instruction-level parallelism in serial code—by cutting data dependencies, using precomputed powers of ten, replacing multiplies with adds, and using an unsigned modular subtraction check—speeds ASCII-to-integer conversion. Implements a 4× unrolled loop, compares against libc and Boost lexical_cast, and publishes code in a Facebook GitHub library. Measures show about 3.4× speedup (falling toward ~2× on long numbers), with smaller numbers gaining most and tiny inputs sometimes slower.
AI-written summary · about
chapters (15)
- 0:00Intro
- 1:41ALU
- 4:20Parallelism
- 7:11Data Dependencies
- 8:16Cookie Crumbles
- 12:22Inlined Math
- 16:17Power of 10
- 20:41Baseline
- 25:28Random IDs
- 25:41Strength Reduction
- 28:27Parallel Execution
- 30:21Table Lookup
- 31:43Modular Subtraction
- 40:06Unrolling
- 42:24Optimization
related talks
01h 00mFastware
01h 02mFastware
01h 12mComparison of C++ Performance Optimization Techniques for C++ Programmers
49mWriting better code with help from Qt and the compiler
56mWrite Fast Code Like a Native
01h 00mProgramming with less effort in C++...
42mAdventures in Efficiency and Performance
23mBeating the Benchmarks: Co-evolving the ISA and Development Tools
