This file is indexed.

/usr/include/diet/fenv.h is in dietlibc-dev 0.33~cvs20120325-4.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
#ifndef _FENV_H
#define _FENV_H

#include <sys/cdefs.h>

__BEGIN_DECLS

#if defined(__i386__)

enum
  {
    FE_INVALID = 0x01,
#define FE_INVALID      FE_INVALID
    __FE_DENORM = 0x02,
    FE_DIVBYZERO = 0x04,
#define FE_DIVBYZERO    FE_DIVBYZERO
    FE_OVERFLOW = 0x08,
#define FE_OVERFLOW     FE_OVERFLOW
    FE_UNDERFLOW = 0x10,
#define FE_UNDERFLOW    FE_UNDERFLOW
    FE_INEXACT = 0x20
#define FE_INEXACT      FE_INEXACT
  };

#define FE_ALL_EXCEPT \
        (FE_INEXACT | FE_DIVBYZERO | FE_UNDERFLOW | FE_OVERFLOW | FE_INVALID)

enum
  {
    FE_TONEAREST = 0,
#define FE_TONEAREST    FE_TONEAREST
    FE_DOWNWARD = 0x400,
#define FE_DOWNWARD     FE_DOWNWARD
    FE_UPWARD = 0x800,
#define FE_UPWARD       FE_UPWARD
    FE_TOWARDZERO = 0xc00
#define FE_TOWARDZERO   FE_TOWARDZERO
  };

#define FE_DFL_ENV      ((__const fenv_t *) -1)

/* Type representing exception flags.  */
typedef unsigned short int fexcept_t;

/* Type representing floating-point environment.  This function corresponds
   to the layout of the block written by the `fstenv'.  */
typedef struct {
  unsigned short int __control_word;
  unsigned short int __unused1;
  unsigned short int __status_word;
  unsigned short int __unused2;
  unsigned short int __tags;
  unsigned short int __unused3;
  unsigned int __eip;
  unsigned short int __cs_selector;
  unsigned int __opcode:11;
  unsigned int __unused4:5;
  unsigned int __data_offset;
  unsigned short int __data_selector;
  unsigned short int __unused5;
} fenv_t;

#elif defined(__ia64__)

enum
  {
    FE_INEXACT =        1UL << 5,
#define FE_INEXACT      FE_INEXACT

    FE_UNDERFLOW =      1UL << 4,
#define FE_UNDERFLOW    FE_UNDERFLOW

    FE_OVERFLOW =       1UL << 3,
#define FE_OVERFLOW     FE_OVERFLOW

    FE_DIVBYZERO =      1UL << 2,
#define FE_DIVBYZERO    FE_DIVBYZERO

    FE_UNNORMAL =       1UL << 1,
#define FE_UNNORMAL     FE_UNNORMAL

    FE_INVALID =        1UL << 0,
#define FE_INVALID      FE_INVALID

    FE_ALL_EXCEPT =
        (FE_INEXACT | FE_UNDERFLOW | FE_OVERFLOW | FE_DIVBYZERO | FE_UNNORMAL | FE_INVALID)
#define FE_ALL_EXCEPT   FE_ALL_EXCEPT
  };

enum
  {
    FE_TOWARDZERO =     3,
#define FE_TOWARDZERO   FE_TOWARDZERO

    FE_UPWARD =         2,
#define FE_UPWARD       FE_UPWARD

    FE_DOWNWARD =       1,
#define FE_DOWNWARD     FE_DOWNWARD

    FE_TONEAREST =      0,
#define FE_TONEAREST    FE_TONEAREST
  };

#define FE_DFL_ENV      ((__const fenv_t *) 0xc009804c0270033fUL)

typedef unsigned long int fexcept_t;
typedef unsigned long int fenv_t;

#elif defined(__powerpc__)

enum
  {
    FE_INEXACT = 1 << (31 - 6),
#define FE_INEXACT      FE_INEXACT
    FE_DIVBYZERO = 1 << (31 - 5),
#define FE_DIVBYZERO    FE_DIVBYZERO
    FE_UNDERFLOW = 1 << (31 - 4),
#define FE_UNDERFLOW    FE_UNDERFLOW
    FE_OVERFLOW = 1 << (31 - 3),
#define FE_OVERFLOW     FE_OVERFLOW

    /* ... except for FE_INVALID, for which we use bit 31. FE_INVALID
       actually corresponds to bits 7 through 12 and 21 through 23
       in the FPSCR, but we can't use that because the current draft
       says that it must be a power of 2.  Instead we use bit 2 which
       is the summary bit for all the FE_INVALID exceptions, which
       kind of makes sense.  */
    FE_INVALID = 1 << (31 - 2),
#define FE_INVALID      FE_INVALID
  };

#define FE_ALL_EXCEPT \
        (FE_INEXACT | FE_DIVBYZERO | FE_UNDERFLOW | FE_OVERFLOW | FE_INVALID)

enum
  {
    FE_TONEAREST = 0,
#define FE_TONEAREST    FE_TONEAREST
    FE_TOWARDZERO = 1,
#define FE_TOWARDZERO   FE_TOWARDZERO
    FE_UPWARD = 2,
#define FE_UPWARD       FE_UPWARD
    FE_DOWNWARD = 3
#define FE_DOWNWARD     FE_DOWNWARD
  };

typedef unsigned int fexcept_t;
typedef double fenv_t;
extern const fenv_t __fe_dfl_env;
#define FE_DFL_ENV      (&__fe_dfl_env)

#elif defined(__s390__)

enum
  {
    FE_INVALID = 0x80,
#define FE_INVALID      FE_INVALID
    FE_DIVBYZERO = 0x40,
#define FE_DIVBYZERO    FE_DIVBYZERO
    FE_OVERFLOW = 0x20,
#define FE_OVERFLOW     FE_OVERFLOW
    FE_UNDERFLOW = 0x10,
#define FE_UNDERFLOW    FE_UNDERFLOW
    FE_INEXACT = 0x08
#define FE_INEXACT      FE_INEXACT
  };

#define FE_ALL_EXCEPT \
        (FE_INEXACT | FE_DIVBYZERO | FE_UNDERFLOW | FE_OVERFLOW | FE_INVALID)

enum
  {
    FE_TONEAREST = 0,
#define FE_TONEAREST    FE_TONEAREST
    FE_DOWNWARD = 0x3,
#define FE_DOWNWARD     FE_DOWNWARD
    FE_UPWARD = 0x2,
#define FE_UPWARD       FE_UPWARD
    FE_TOWARDZERO = 0x1
#define FE_TOWARDZERO   FE_TOWARDZERO
  };

#define FE_DFL_ENV      ((__const fenv_t *) -1)

typedef unsigned int fexcept_t; /* size of fpc */
typedef struct
{
  fexcept_t fpc;
  void *ieee_instruction_pointer;
  /* failing instruction for ieee exceptions */
} fenv_t;

#elif defined(__sparc__)

enum
  {    
    FE_INVALID =        (1 << 9),
#define FE_INVALID      FE_INVALID
    FE_OVERFLOW =       (1 << 8),
#define FE_OVERFLOW     FE_OVERFLOW
    FE_UNDERFLOW =      (1 << 7),
#define FE_UNDERFLOW    FE_UNDERFLOW
    FE_DIVBYZERO =      (1 << 6),
#define FE_DIVBYZERO    FE_DIVBYZERO
    FE_INEXACT =        (1 << 5)
#define FE_INEXACT      FE_INEXACT
  };

#define FE_ALL_EXCEPT \
        (FE_INEXACT | FE_DIVBYZERO | FE_UNDERFLOW | FE_OVERFLOW | FE_INVALID)

enum
  {      
    FE_TONEAREST =      (0U << 30),
#define FE_TONEAREST    FE_TONEAREST
    FE_TOWARDZERO =     (1U << 30),
#define FE_TOWARDZERO   FE_TOWARDZERO
    FE_UPWARD =         (2U << 30),
#define FE_UPWARD       FE_UPWARD
    FE_DOWNWARD =       (3U << 30)
#define FE_DOWNWARD     FE_DOWNWARD
  };

#define __FE_ROUND_MASK (3U << 30)
#define FE_DFL_ENV      ((__const fenv_t *) -1)

typedef unsigned long int fexcept_t;
typedef unsigned long int fenv_t;

#elif defined(__x86_64__)

enum
  {    
    FE_INVALID = 0x01,  
#define FE_INVALID      FE_INVALID
    __FE_DENORM = 0x02,
    FE_DIVBYZERO = 0x04,
#define FE_DIVBYZERO    FE_DIVBYZERO
    FE_OVERFLOW = 0x08,
#define FE_OVERFLOW     FE_OVERFLOW
    FE_UNDERFLOW = 0x10,
#define FE_UNDERFLOW    FE_UNDERFLOW
    FE_INEXACT = 0x20
#define FE_INEXACT      FE_INEXACT
  };

#define FE_ALL_EXCEPT \
        (FE_INEXACT | FE_DIVBYZERO | FE_UNDERFLOW | FE_OVERFLOW | FE_INVALID)

enum
  { 
    FE_TONEAREST = 0,
#define FE_TONEAREST    FE_TONEAREST
    FE_DOWNWARD = 0x400,
#define FE_DOWNWARD     FE_DOWNWARD
    FE_UPWARD = 0x800,
#define FE_UPWARD       FE_UPWARD
    FE_TOWARDZERO = 0xc00
#define FE_TOWARDZERO   FE_TOWARDZERO
  };

#define FE_DFL_ENV      ((__const fenv_t *) -1)

typedef unsigned short int fexcept_t;

typedef struct {
  unsigned short int __control_word;
  unsigned short int __unused1;
  unsigned short int __status_word;
  unsigned short int __unused2;
  unsigned short int __tags;
  unsigned short int __unused3;
  unsigned int __eip;
  unsigned short int __cs_selector;
  unsigned int __opcode:11;
  unsigned int __unused4:5;
  unsigned int __data_offset;
  unsigned short int __data_selector;
  unsigned short int __unused5;
  unsigned int __mxcsr;
} fenv_t;

#else

#error unsupported platform, edit include/fenv.h
#endif

int  feclearexcept(int);
int  fegetexceptflag(fexcept_t *, int);
int  feraiseexcept(int);
int  fesetexceptflag(const fexcept_t *, int);
int  fetestexcept(int);
int  fegetround(void);
int  fesetround(int);
int  fegetenv(fenv_t *);
int  feholdexcept(fenv_t *);
int  fesetenv(const fenv_t *);
int  feupdateenv(const fenv_t *);

__END_DECLS

#endif