| 1067 | } |
| 1068 | |
| 1069 | FPExcept disableFPExcept (FPExcept excepts) |
| 1070 | { |
| 1071 | auto prev = getFPExcept(); |
| 1072 | #if defined(__linux__) && defined(__GLIBC__) |
| 1073 | int flags = 0; |
| 1074 | if (any(excepts & FPExcept::invalid )) { flags |= FE_INVALID ; } |
| 1075 | if (any(excepts & FPExcept::zero )) { flags |= FE_DIVBYZERO; } |
| 1076 | if (any(excepts & FPExcept::overflow)) { flags |= FE_OVERFLOW ; } |
| 1077 | fedisableexcept(flags); |
| 1078 | #else |
| 1079 | amrex::ignore_unused(excepts); |
| 1080 | #endif |
| 1081 | return prev; |
| 1082 | } |
| 1083 | |
| 1084 | FPExcept enableFPExcept (FPExcept excepts) |
| 1085 | { |
nothing calls this directly
no test coverage detected