1132718Skan/* Copyright (C) 2001, 2005 Free Software Foundation, Inc.
2132718Skan   Contributed by David Mosberger <davidm@hpl.hp.com>.
3132718Skan
4132718Skan   This file is part of GCC.
5169689Skan
6169689Skan   GCC is free software; you can redistribute it and/or modify
7169689Skan   it under the terms of the GNU General Public License as published by
8169689Skan   the Free Software Foundation; either version 2, or (at your option)
9169689Skan   any later version.
10169689Skan
11169689Skan   GCC is distributed in the hope that it will be useful,
12169689Skan   but WITHOUT ANY WARRANTY; without even the implied warranty of
13169689Skan   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14   GNU General Public License for more details.
15
16   You should have received a copy of the GNU General Public License
17   along with GCC; see the file COPYING.  If not, write to
18   the Free Software Foundation, 51 Franklin Street, Fifth Floor,
19   Boston, MA 02110-1301, USA.  */
20
21/* As a special exception, if you link this library with other files,
22   some of which are compiled with GCC, to produce an executable,
23   this library does not by itself cause the resulting executable
24   to be covered by the GNU General Public License.
25   This exception does not however invalidate any other reasons why
26   the executable file might be covered by the GNU General Public License.  */
27
28/* We could call fesetenv() here but that would create a confusing
29   dependency on libm (since that is where fesetenv() gets defined.
30   To avoid this, just do everything locally.  */
31#define FE_NONIEEE_ENV 0x0009a04d0270037f
32
33static void __attribute__((constructor))
34__ia64_set_fast_math (void)
35{
36  __asm__ __volatile__ ("mov.m ar.fpsr=%0" : : "r"(FE_NONIEEE_ENV));
37}
38