From 0c85dbfd1251f34624e17cae810de6ddd4257cc4 Mon Sep 17 00:00:00 2001 From: Eric Botcazou Date: Fri, 28 Mar 2003 10:10:43 +0100 Subject: [PATCH] re PR target/10067 (GCC-3.2.2 outputs invalid asm on sparc64) PR target/10067 * config/sparc/sparc.md (jump pattern): Correct order when issuing the annuling marker. From-SVN: r64964 --- gcc/ChangeLog | 6 +++++ gcc/config/sparc/sparc.md | 2 +- gcc/testsuite/ChangeLog | 4 ++++ gcc/testsuite/gcc.dg/ultrasp8.c | 39 +++++++++++++++++++++++++++++++++ 4 files changed, 50 insertions(+), 1 deletion(-) create mode 100644 gcc/testsuite/gcc.dg/ultrasp8.c diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 8ebdc40140e..581d7588aff 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2003-03-28 Eric Botcazou + + PR target/10067 + * config/sparc/sparc.md (jump pattern): Correct order + when issuing the annuling marker. + 2003-03-28 Eric Botcazou PR c/8281 diff --git a/gcc/config/sparc/sparc.md b/gcc/config/sparc/sparc.md index aa3ebdb2c9a..bc8c634ac18 100644 --- a/gcc/config/sparc/sparc.md +++ b/gcc/config/sparc/sparc.md @@ -7252,7 +7252,7 @@ == INSN_ADDRESSES (INSN_UID (insn)))) return "b\t%l0%#"; else - return TARGET_V9 ? "ba,pt%*\t%%xcc, %l0%(" : "b%*\t%l0%("; + return TARGET_V9 ? "ba%*,pt\t%%xcc, %l0%(" : "b%*\t%l0%("; } [(set_attr "type" "uncond_branch")]) diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index e34b6e11ea4..5818881ca76 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,7 @@ +2003-03-28 Eric Botcazou + + * gcc.dg/ultrasp8.c: New test. + 2003-03-28 Eric Botcazou * gcc.dg/ultrasp7.c: New test. diff --git a/gcc/testsuite/gcc.dg/ultrasp8.c b/gcc/testsuite/gcc.dg/ultrasp8.c new file mode 100644 index 00000000000..9b0c8d976c1 --- /dev/null +++ b/gcc/testsuite/gcc.dg/ultrasp8.c @@ -0,0 +1,39 @@ +/* PR target/10067 */ +/* Originator: */ +/* { dg-do compile { target sparc-*-* } } */ +/* { dg-options "-O2 -m64 -mtune=supersparc" } */ + +struct _reent; + +extern unsigned long __malloc_trim_threshold; +extern unsigned long __malloc_top_pad; + +int _mallopt_r(struct _reent *reent_ptr, int param_number, int value) +{ + __malloc_lock(reent_ptr); + + switch(param_number) + { + case -1: + __malloc_trim_threshold = value; + __malloc_unlock(reent_ptr); + return 1; + + case -2: + __malloc_top_pad = value; + __malloc_unlock(reent_ptr); + return 1; + + case -3: + __malloc_unlock(reent_ptr); + return 1; + + case -4: + __malloc_unlock(reent_ptr); + return value == 0; + + default: + __malloc_unlock(reent_ptr); + return 0; + } +} -- 2.30.2