Use ProcessThread::init () to set up denormal protection

Modifying the MXCSR register only affects the current thread.
This commit is contained in:
Robin Gareus 2019-09-09 18:48:16 +02:00
parent 07b685c371
commit 4abb907a82
Signed by: rgareus
GPG Key ID: A090BCE02CF57F04
2 changed files with 5 additions and 1 deletions

View File

@ -37,7 +37,7 @@ public:
ProcessThread ();
~ProcessThread ();
static void init();
void init();
void get_buffers ();
void drop_buffers ();

View File

@ -20,6 +20,7 @@
#include <iostream>
#include "ardour/ardour.h"
#include "ardour/buffer.h"
#include "ardour/buffer_manager.h"
#include "ardour/buffer_set.h"
@ -41,10 +42,13 @@ Glib::Threads::Private<ThreadBuffers> ProcessThread::_private_thread_buffers (re
void
ProcessThread::init ()
{
/* denormal protection is per thread */
ARDOUR::setup_fpu ();
}
ProcessThread::ProcessThread ()
{
init ();
}
ProcessThread::~ProcessThread ()