summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.target/mips/nansf-2008.c
diff options
context:
space:
mode:
authormacro <macro@138bc75d-0d04-0410-961f-82ee72b054a4>2013-07-29 14:37:30 +0000
committermacro <macro@138bc75d-0d04-0410-961f-82ee72b054a4>2013-07-29 14:37:30 +0000
commit0bd32132d471995f3e333138363d1d928a9dde60 (patch)
tree4b72a5f006ea9267e8c0e91ce37fdae020e14228 /gcc/testsuite/gcc.target/mips/nansf-2008.c
parent9834debf37d25899ac88afa6f0cc812fc347eba4 (diff)
downloadgcc-0bd32132d471995f3e333138363d1d928a9dde60.tar.gz
gcc/
* config/mips/linux.h (GLIBC_DYNAMIC_LINKER): Handle `-mnan=2008'. (UCLIBC_DYNAMIC_LINKER): New macro. * config/mips/linux64.h (GLIBC_DYNAMIC_LINKER32): Handle `-mnan=2008'. (GLIBC_DYNAMIC_LINKER64, GLIBC_DYNAMIC_LINKERN32): Likewise. (UCLIBC_DYNAMIC_LINKER32): Undefine macro first. Handle `-mnan=2008'. (UCLIBC_DYNAMIC_LINKER64): Redefine macro. (UCLIBC_DYNAMIC_LINKERN32): Likewise. * config/mips/mips-modes.def: Remove RESET_FLOAT_FORMAT calls for SF and DF modes. Use ieee_quad_format for TF mode. * config/mips/mips-opts.h (mips_ieee_754_setting): New enum. * config/mips/mips.c (mips_file_start): Output a `.nan' directive. (mips_option_override): Handle `-mnan=legacy'. * config/mips/mips.h (TARGET_CPU_CPP_BUILTINS): Handle `-mabs=2008' and `-mnan=2008'. (OPTION_DEFAULT_SPECS): Add "nan" default. (ASM_SPEC): Handle `-mnan='. [!HAVE_AS_NAN] (HAVE_AS_NAN): New macro. * config/mips/mips.md (abs<mode>2): Handle `-mabs=2008', update comment accordingly. (neg<mode>2): Likewise. * config/mips/mips.opt (mabs, mnan): New options. * doc/install.texi (Configuration): Document `--with-nan=' option. * doc/invoke.texi (Option Summary): List MIPS `-mabs=' and `-mnan=' options. (MIPS Options): Document them. * config.gcc <mips*-*-*>: Handle `--with-nan='. * configure.ac <mips*-*-*>: Check for GAS `-mnan=2008' support. * configure: Regenerate. * config.in: Regenerate. gcc/testsuite/ * gcc.target/mips/fabs-2008.c: New test case. * gcc.target/mips/fabs-legacy.c: New test case. * gcc.target/mips/fabsf-2008.c: New test case. * gcc.target/mips/fabsf-legacy.c: New test case. * gcc.target/mips/fneg-2008.c: New test case. * gcc.target/mips/fneg-legacy.c: New test case. * gcc.target/mips/fneg-2008.c: New test case. * gcc.target/mips/fneg-legacy.c: New test case. * gcc.target/mips/nan-2008.c: New test case. * gcc.target/mips/nan-legacy.c: New test case. * gcc.target/mips/nanf-2008.c: New test case. * gcc.target/mips/nanf-legacy.c: New test case. * gcc.target/mips/nans-2008.c: New test case. * gcc.target/mips/nans-legacy.c: New test case. * gcc.target/mips/nansf-2008.c: New test case. * gcc.target/mips/nansf-legacy.c: New test case. * gcc.target/mips/mips.exp: Handle `-mabs=' and `-mnan='. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@201313 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/testsuite/gcc.target/mips/nansf-2008.c')
-rw-r--r--gcc/testsuite/gcc.target/mips/nansf-2008.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.target/mips/nansf-2008.c b/gcc/testsuite/gcc.target/mips/nansf-2008.c
new file mode 100644
index 00000000000..d6c86a8472f
--- /dev/null
+++ b/gcc/testsuite/gcc.target/mips/nansf-2008.c
@@ -0,0 +1,7 @@
+/* { dg-do compile } */
+/* { dg-options "-mnan=2008 -EB" } */
+
+float fs = __builtin_nansf ("");
+
+/* { dg-final { scan-assembler "\t\.nan\t2008\n" } } */
+/* { dg-final { scan-assembler "\t\.word\t2141192192\n" } } */