Title is slightly misleading (the shortened version of this post even more). Together with the fact that min-max is very similar to minimax[1] it made me expect an (language) AI article
The article is mostly about optimizing a specific function/data structure for fast displaying of waveforms (still interesting :]).