Patchwork rs6000: Correct ATOMIC mode iterator

login
register
mail settings
Submitter Segher Boessenkool
Date Oct. 25, 2012, 10:56 p.m.
Message ID <c42516b2964247818b0290645b24753215490e2e.1351204428.git.segher@kernel.crashing.org>
Download mbox | patch
Permalink /patch/194321/
State New
Headers show

Comments

Segher Boessenkool - Oct. 25, 2012, 10:56 p.m.
This fixes the ICE with -m32 -mpowerpc64 on many of the testcases that
use atomics:

gcc:
-# of expected passes           108465
-# of unexpected failures       365
+# of expected passes           108499
+# of unexpected failures       303

libgomp:
-# of expected passes           8664
-# of unexpected failures       126
-# of unresolved testcases      63
+# of expected passes           8790

Not bad for a one-liner :-)

Bootstrapped and tested on powerpc64-linux, -m64,-m32,-m32/-mpowerpc64;
no new failures, and the above improvements.

Okay to apply?


Segher


2012-10-25  Segher Boessenkool  <segher@kernel.crashing.org>

gcc/
	* config/rs6000/sync.md (ATOMIC): Correct DI condition.

---
 gcc/config/rs6000/sync.md |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
David Edelsohn - Oct. 26, 2012, 12:54 a.m.
On Thu, Oct 25, 2012 at 6:56 PM, Segher Boessenkool
<segher@kernel.crashing.org> wrote:
> This fixes the ICE with -m32 -mpowerpc64 on many of the testcases that
> use atomics:

> Bootstrapped and tested on powerpc64-linux, -m64,-m32,-m32/-mpowerpc64;
> no new failures, and the above improvements.
>
> Okay to apply?

> 2012-10-25  Segher Boessenkool  <segher@kernel.crashing.org>
>
> gcc/
>         * config/rs6000/sync.md (ATOMIC): Correct DI condition.

Okay.

Thanks, David

Patch

diff --git a/gcc/config/rs6000/sync.md b/gcc/config/rs6000/sync.md
index 42ac903..ddf2ae7 100644
--- a/gcc/config/rs6000/sync.md
+++ b/gcc/config/rs6000/sync.md
@@ -174,7 +174,7 @@  (define_expand "atomic_store<mode>"
 ;; opcode that is "phased-in".  Not implemented as of Power7, so not yet used,
 ;; but let's prepare the macros anyway.
 
-(define_mode_iterator ATOMIC    [SI (DI "TARGET_64BIT")])
+(define_mode_iterator ATOMIC    [SI (DI "TARGET_POWERPC64")])
 
 (define_insn "load_locked<mode>"
   [(set (match_operand:ATOMIC 0 "gpc_reg_operand" "=r")