On 10/21/2014 03:32 PM, Vesa wrote:
>> The "Disabling denormal floats at the code level" is specially useful
>> for LMMS.
>>
>> AFAIK the usual procedure to avoid denormals is as follows:
>>
>> On the engine code, include the headers needed for _mm_getcsr/_mm_setcsr
>>
>> #include <xmmintrin.h>
>>
>>
>> When the engine thread is initializing call this: (on all the threads
>> that do audio-processing)
>>
>> _mm_setcsr(  _mm_getcsr()  |  0x8040  );
>>
>>
>> The plugins and LMMS engine/audio code will need to be built with
>> fastmath and SSE2, the gcc arguments are:
>>
>> -ffast-math -mtune=generic -msse -msse2 -mfpmath=sse
>>
>>
>> Note that this requires SSE2.
>> But if LMMS does this, the issue with denormals will very likely go away.
>>
>>
>> PS: I tried building the full LMMS code with "-ffast-math", but that
>> breaks the timeline.
>> So if this is going to be introduced it will need to be carefully
>> selected (only audio engine and plugins). 
> Thanks for the info.
>
> We've considered denormal-stripping and SSE2 before, but nothing came of
> those discussions - IIRC, it was thought that there wasn't enough
> benefit in doing so... but maybe that could be re-evaluated now, if it
> could prevent issues with fx plugins.

Maybe we can evaluate this again... if we can prevent problems with DSP
and fix long-standing issues, isn't that enough of a benefit to consider
this?
Is anyone really running LMMS on pre-SSE2 hardware anymore?

------------------------------------------------------------------------------
_______________________________________________
LMMS-devel mailing list
LMMS-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/lmms-devel

Reply via email to