REVEALED: Quake III's SECRET Algorithm!
Dave's Garage Dave's Garage
671K subscribers
499,107 views
0

 Published On Premiered Aug 11, 2021

When the Quake III Arena source code was released to the world it contained a previously unknown algorithm called the Fast Inverse Square Root. This is the story of this strange algorithm and how it works as told by retired Microsoft software engineer Dave Plummer.
Thanks to viewer Brandon Pinske for the video topic suggestion!

For more info on the FISR:
A great video with better math explanations:    • Fast Inverse Square Root — A Quake II...  
A surprisingly complete and detailed Wikipedia article: https://en.wikipedia.org/wiki/Fast_in...

Amazon Affiliate links for products mentioned in the video:
Zen of Code Optimization - https://amzn.to/2VO7ltx
Zen of Graphics Programming - https://amzn.to/3AxTAh9
Zen of Assembly [Out of Print] - https://amzn.to/2VD7Arn

Chapter Markers:
00:00 The Story
02:10 Welcome
03:25 Vectors
04:30 Normalization
05:48 Pythagoras Redux
07:50 Behold Code
09:10 Roots and Floats
10:21 Newton, Approximately
11:14 Rate of Change
13:02 C++ Code
14:15 Gates and Allen
15:04 Outtakes and Rarities

Errata: Please let me know in the comments of any important errors or omissions, and I will update things here. Currently, the only major update is at the end - I leave you with the impression that IEEE-754 might have been based on MBF, but I don't think that's the case. I will expand on this in Part 2, but recommend these two links for the curious:

• "The IEEE Standard 754: One for the History Books,"
https://www.computer.org/csdl/magazin...
• "An Interview with the Old Man of Floating-Point,"
http://people.eecs.berkeley.edu/~wkah...

show more

Share/Embed