Avoid an extra function to generate BSincHeaders
[openal-soft.git] / alc / fpu_ctrl.h
blobe89bdc29ccf7b1f014fe1ad259e01d389b970d18
1 #ifndef FPU_CTRL_H
2 #define FPU_CTRL_H
4 class FPUCtl {
5 #if defined(HAVE_SSE_INTRINSICS) || (defined(__GNUC__) && defined(HAVE_SSE))
6 unsigned int sse_state{};
7 #endif
8 bool in_mode{};
10 public:
11 FPUCtl();
12 /* HACK: 32-bit targets for GCC seem to have a problem here with certain
13 * noexcept methods (which destructors are) causing an internal compiler
14 * error. No idea why it's these methods specifically, but this is needed
15 * to get it to compile.
17 ~FPUCtl() noexcept(false) { leave(); }
19 FPUCtl(const FPUCtl&) = delete;
20 FPUCtl& operator=(const FPUCtl&) = delete;
22 void leave();
25 #endif /* FPU_CTRL_H */