[FFmpeg-devel] [PATCH] configure, avutil/libm: add fmax, fmaxf, fmin, fminf support
u at pkh.me
Thu Oct 15 14:31:24 CEST 2015
On Thu, Oct 15, 2015 at 08:18:02AM -0400, Ganesh Ajjanagadde wrote:
> It has been demonstrated that using libc provided floating point
> functions is beneficial, in the context of fabs() vs FFABS.
> Unfortunately, MSVC 2012 (and earlier) lack the ISO C99 fmax, fmaxf,
> fmin, fminf functions. This patch adds them, thus making their usage in
> FFmpeg safe.
Do we have any use of fmax/fmin? The functions don't exist to make
FFMAX-like faster, it actually is more complex:
These functions return the maximum of x and y.
If one argument is a NaN, the other argument is returned.
If both arguments are NaN, a NaN is returned.
Which means it's likely slower but will do more. Not that I mind, but in this
case, if we happen to use them, you will want to fix your local implementation
to match this behaviour.
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 473 bytes
Desc: not available
More information about the ffmpeg-devel