svn trunk commit r4413
[wrffire.git] / wrfv2_fire / share / setfeenv.c
blobe4983dea096846df1240117106da3b93ad93f971
1 #ifndef CRAY
2 # ifdef NOUNDERSCORE
3 # define SETFEENV setfeenv
4 # else
5 # ifdef F2CSTYLE
6 # define SETFEENV setfeenv__
7 # else
8 # define SETFEENV setfeenv_
9 # endif
10 # endif
11 #endif
13 #include <fenv.h>
14 #include <stdio.h>
16 void SETFEENV()
18 fenv_t envp;
19 int stat;
20 #ifdef _OPENMP
22 stat = fegetenv(&envp);
24 if (fesetenv(&envp) != 0) {
25 perror("Error getting fp env");
29 #pragma omp parallel shared(envp)
31 stat = fesetenv(&envp);
33 if (fesetenv(&envp) != 0) {
34 perror("Error setting fp env");
38 #endif