Ignore:
Timestamp:
04/21/19 16:36:22 (5 years ago)
Author:
Maciej Komosinski
Message:

Code formatting + cosmetic fixes

File:
1 edited

Legend:

Unmodified
Added
Removed
  • cpp/common/nonstd_math.cpp

    r835 r867  
    77RandomGenerator& rndGetInstance()
    88{
    9 static RandomGenerator rnd(0);
    10 return rnd;
     9        static RandomGenerator rnd(0);
     10        return rnd;
    1111}
    1212
     
    5050void fpExceptEnable()
    5151{
    52 feclearexcept(FE_DIVBYZERO);
    53 feenableexcept(FE_DIVBYZERO);
     52        feclearexcept(FE_DIVBYZERO);
     53        feenableexcept(FE_DIVBYZERO);
    5454}
    5555
    5656void fpExceptDisable()
    5757{
    58 fedisableexcept(FE_DIVBYZERO);
     58        fedisableexcept(FE_DIVBYZERO);
    5959}
    6060
     
    8383        //unsigned int was=_clear87();
    8484        //logPrintf("","fpExceptInit",LOG_INFO,"control87 status before clear was %08x", was);
    85         fp_control_word_std=_control87(0, 0);             //4978 = 1001101110010
     85        fp_control_word_std = _control87(0, 0);             //4978 = 1001101110010
    8686        // Make the new fp env same as the old one, except for the changes we're going to make
    8787        fp_control_word_muted = fp_control_word_std | EM_INVALID | EM_DENORMAL | EM_ZERODIVIDE | EM_OVERFLOW | EM_UNDERFLOW | EM_INEXACT;  //4991 = 1001101111111
     
    9090void fpExceptEnable()
    9191{
    92         unsigned int was=_clear87(); //trzeba czyscic zeby nie bylo exception...
     92        unsigned int was = _clear87(); //trzeba czyscic zeby nie bylo exception...
    9393        //logPrintf("","fpExceptEnable ",LOG_INFO,"control87 status before clear was %08x", was);
    9494        _control87(fp_control_word_std, 0xffffffff);
     
    9898void fpExceptDisable()
    9999{
    100         unsigned int was=_clear87(); //trzeba czyscic zeby nie bylo exception...
     100        unsigned int was = _clear87(); //trzeba czyscic zeby nie bylo exception...
    101101        //logPrintf("","fpExceptDisable",LOG_INFO,"control87 status before clear was %08x", was);
    102102        _control87(fp_control_word_muted, 0xffffffff);
     
    116116void fpExceptDisable() {}
    117117#endif
    118 
Note: See TracChangeset for help on using the changeset viewer.