[flac-dev] FLAC__SSE_OS change

lvqcl lvqcl.mail at gmail.com
Thu Jun 23 18:32:44 UTC 2016


lvqcl wrote:

> Erik de Castro Lopo wrote:
>
>> 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
>>

P.P.S.

1) if FLAC__SSE_OS==1 then MSVC cannot compile current cpu.c:
"#include <windows.h>" line is inactive and MSVC complains:
cpu.c(278): error C2065: 'EXCEPTION_EXECUTE_HANDLER': undeclared identifier
cpu.c(279): error C2065: 'STATUS_ILLEGAL_INSTRUCTION': undeclared identifier

2) the current code (simplified):

     if(info->ia32.sse) {
#if !FLAC__SSE_OS
         /* assume user knows better than us; turn it off */
         disable_sse(info);
#elif ...
#elif defined(__linux__) && !FLAC__SSE_OS
#elif ...
#else
#endif
     }

means that the __linux__ part is never compiled: if FLAC__SSE_OS==0 then
this code becomes just "disable_sse(info);" and if FLAC__SSE_OS==1
then "defined(__linux__) && !FLAC__SSE_OS" is always false.


More information about the flac-dev mailing list