From Jason Turner
Watch on YouTube

Summary

Jason compares performance metrics between the original Crispy Doom (C code) and his C++ port. Surprisingly, the C++ version produces a slightly smaller binary and performs marginally better, despite having additional C++ features like RTTI and exception handling enabled. Jason theorizes that C++'s stricter aliasing rules may give the compiler better optimization opportunities, resulting in fewer branch misses (1.0% vs 1.05%) and slightly higher performance (124 FPS vs 123.4 FPS).

Resources

Tags