Search⌘ K

Known Slugs

Explore techniques to optimize C code by substituting slow math functions like pow and sqrt with faster alternatives, and understand how profiling tools help identify performance bottlenecks. This lesson helps you write more efficient programs by applying practical approaches to speed up math operations and prepares you for advanced optimization using compiler flags.

We'll cover the following...

Slow math functions

There are some C functions that are known to be slow such as the pow and sqrt functions and the trigonometric functions (e.g., sin, cos, tan, etc.). These can be accessed by including the math.h ...