Update copyright dates with scripts/update-copyrights.
[glibc.git] / sysdeps / powerpc / powerpc32 / e500 / nofpu / fenv_const.c
blobc0b0586de917bff2a576833fe1e40b45d2939e98
1 /* Constant floating-point environments for e500.
2 Copyright (C) 2004-2015 Free Software Foundation, Inc.
3 This file is part of the GNU C Library.
5 The GNU C Library is free software; you can redistribute it and/or
6 modify it under the terms of the GNU Lesser General Public
7 License as published by the Free Software Foundation; either
8 version 2.1 of the License, or (at your option) any later version.
10 The GNU C Library is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 Lesser General Public License for more details.
15 You should have received a copy of the GNU Lesser General Public
16 License along with the GNU C Library; if not, see
17 <http://www.gnu.org/licenses/>. */
19 /* The use of "unsigned long long" as the type to define the
20 bit-pattern explicitly, rather than the type "double" used in
21 <bits/fenv.h>, means that we cannot include <fenv_libc.h> here to
22 get the enum constants for the SPEFSCR bits to enable
23 exceptions. */
25 #include <sys/prctl.h>
27 /* If the default argument is used we use this value. */
28 const unsigned long long __fe_dfl_env __attribute__ ((aligned (8))) =
29 0x3cULL;
31 /* Floating-point environment where none of the exceptions are masked. */
32 const unsigned long long __fe_enabled_env __attribute__ ((aligned (8))) =
33 (((unsigned long long) (PR_FP_EXC_DIV
34 | PR_FP_EXC_OVF
35 | PR_FP_EXC_UND
36 | PR_FP_EXC_RES
37 | PR_FP_EXC_INV)) << 32) | 0x7cULL;
39 /* Non-IEEE mode. */
40 const unsigned long long __fe_nonieee_env __attribute__ ((aligned (8))) =
41 0x0ULL;