RAII mechanism to disable denormals while an instance of this class is alive. Supports SSE or NEON instruction sets, will have no effect if neither of those are present. Goes without saying, but doesn't allocate (I deliberately didn't use pImpl for this reason) More...
#include <mostlyharmless_NoDenormals.h>
Public Member Functions | |
NoDenormals () | |
~NoDenormals () noexcept | |
RAII mechanism to disable denormals while an instance of this class is alive. Supports SSE or NEON instruction sets, will have no effect if neither of those are present. Goes without saying, but doesn't allocate (I deliberately didn't use pImpl for this reason)
mostly_harmless::utils::NoDenormals::NoDenormals | ( | ) |
Disables denormals on construction, by setting FTZ (and DAZ in SSE)
|
noexcept |
Resets the FTZ / DAZ bits to their original states