[FFmpeg-devel] [PATCH 2/2] Use gcc/clang builtins for av_sat_(add|sub)_64_c if available.

Dale Curtis dalecurtis at chromium.org
Tue May 26 22:23:41 EEST 2020


On Fri, May 22, 2020 at 1:34 PM Michael Niedermayer <michael at niedermayer.cc>
wrote:

>
> does this produce faster / better code ?
> that is do compilers actually fail to optimize this from plain
> clean C code ?
>

Here's the difference:
clang trunk: https://godbolt.org/z/6SHmEo
gcc trunk: https://godbolt.org/z/iKb9jZ

I don't think it matters at all for the use cases I'm planning to add, but
it might for any future use which uses it on a hotter path. Happy to
abandon if it's not worth the trouble to y'all.

- dale


More information about the ffmpeg-devel mailing list