MCPcopy Create free account
hub / github.com/numpy/numpy / npy_get_floatstatus_barrier

Function npy_get_floatstatus_barrier

numpy/core/src/npymath/ieee754.cpp:422–438  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

420
421
422extern "C" int
423npy_get_floatstatus_barrier(char *param)
424{
425 int fpstatus = fetestexcept(FE_DIVBYZERO | FE_OVERFLOW | FE_UNDERFLOW |
426 FE_INVALID);
427 /*
428 * By using a volatile, the compiler cannot reorder this call
429 */
430 if (param != NULL) {
431 volatile char NPY_UNUSED(c) = *(char *)param;
432 }
433
434 return ((FE_DIVBYZERO & fpstatus) ? NPY_FPE_DIVIDEBYZERO : 0) |
435 ((FE_OVERFLOW & fpstatus) ? NPY_FPE_OVERFLOW : 0) |
436 ((FE_UNDERFLOW & fpstatus) ? NPY_FPE_UNDERFLOW : 0) |
437 ((FE_INVALID & fpstatus) ? NPY_FPE_INVALID : 0);
438}
439
440extern "C" int
441npy_clear_floatstatus_barrier(char *param)

Callers 12

npy_get_floatstatusFunction · 0.85
PyArray_CopyAsFlatFunction · 0.85
raw_array_assign_scalarFunction · 0.85
cast_raw_scalar_itemFunction · 0.85
raw_array_assign_arrayFunction · 0.85
array_assign_subscriptFunction · 0.85
PyArray_CastRawArraysFunction · 0.85
_check_ufunc_fperrFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected