[flac-dev] FLAC__SSE_OS change

Erik de Castro Lopo mle+la at mega-nerd.com
Tue Jun 21 08:17:41 UTC 2016


lvqcl wrote:

> About the commit <http://git.xiph.org/?p=flac.git;a=commitdiff;h=e120037f3c67b23fd9eef7ccd04d2df57fa1a9a6>
> 
> I admit I don't understand the following lines:
> 
>   #if !FLAC__SSE_OS
>          /* assume user knows better than us; turn it off */
>          disable_sse(info);
>   #elif defined(__FreeBSD__) || defined(__FreeBSD_kernel__) ......
> 
> Probably it should be
> 
>   #if FLAC__SSE_OS
>          /* assume user knows better than us; leave as detected above */
>   #elif defined(__FreeBSD__) || defined(__FreeBSD_kernel__) ......

I actually think my change is correct. It should be easier to see if you
look at the github version of the change:

    https://github.com/xiph/flac/commit/e120037f3c67b23fd9eef7ccd04d2df57fa1a9a6#diff-9f048b83ff55071de36263cf0f403b2eL209

But yes, all those #ifs and #elses are horrible for readability and
maintainability.

CHeers,
Erik
-- 
----------------------------------------------------------------------
Erik de Castro Lopo
http://www.mega-nerd.com/


More information about the flac-dev mailing list