diff options
author | law <law@138bc75d-0d04-0410-961f-82ee72b054a4> | 1999-01-03 19:45:34 +0000 |
---|---|---|
committer | law <law@138bc75d-0d04-0410-961f-82ee72b054a4> | 1999-01-03 19:45:34 +0000 |
commit | d0781cc7452e07df9c9d66a4aa5eeaa128a3a1f2 (patch) | |
tree | 07f5f78b4e67470df38c100332b7ac010a2d8184 | |
parent | 71c5359451cafd6706070d5e0cb929ad532d48e4 (diff) |
* pa.md (branch, negated branch): Handle (const_int 0) as first
source operand.
* pa.c (output_cbranch): Likewise.
Should fix unrolling aborts on the PA.
git-svn-id: https://gcc.gnu.org/svn/gcc/trunk@24465 138bc75d-0d04-0410-961f-82ee72b054a4
-rw-r--r-- | gcc/ChangeLog | 6 | ||||
-rw-r--r-- | gcc/config/pa/pa.c | 24 | ||||
-rw-r--r-- | gcc/config/pa/pa.md | 4 |
3 files changed, 20 insertions, 14 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index e8e79e13bcf..5009cfe9bf0 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +Sun Jan 3 20:40:34 1999 Jeffrey A Law (law@cygnus.com) + + * pa.md (branch, negated branch): Handle (const_int 0) as first + source operand. + * pa.c (output_cbranch): Likewise. + Sun Jan 3 03:20:38 1999 David Edelsohn <edelsohn@mhpcc.edu> * rs6000.c (rs6000_stack_info): Undo spurious part of last diff --git a/gcc/config/pa/pa.c b/gcc/config/pa/pa.c index 91ada8e3aec..162a0b09a24 100644 --- a/gcc/config/pa/pa.c +++ b/gcc/config/pa/pa.c @@ -4461,11 +4461,11 @@ output_cbranch (operands, nullify, length, negated, insn) else strcat (buf, "%S3"); if (useskip) - strcat (buf, " %2,%1,0"); + strcat (buf, " %2,%r1,0"); else if (nullify) - strcat (buf, ",n %2,%1,%0"); + strcat (buf, ",n %2,%r1,%0"); else - strcat (buf, " %2,%1,%0"); + strcat (buf, " %2,%r1,%0"); break; /* All long conditionals. Note an short backward branch with an @@ -4483,7 +4483,7 @@ output_cbranch (operands, nullify, length, negated, insn) strcat (buf, "%S3"); else strcat (buf, "%B3"); - strcat (buf, ",n %2,%1,.+12\n\tbl %0,0"); + strcat (buf, ",n %2,%r1,.+12\n\tbl %0,0"); } /* Handle short backwards branch with an unfilled delay slot. Using a comb;nop rather than comiclr;bl saves 1 cycle for both @@ -4496,9 +4496,9 @@ output_cbranch (operands, nullify, length, negated, insn) { strcpy (buf, "com%I2b,"); if (negated) - strcat (buf, "%B3 %2,%1,%0%#"); + strcat (buf, "%B3 %2,%r1,%0%#"); else - strcat (buf, "%S3 %2,%1,%0%#"); + strcat (buf, "%S3 %2,%r1,%0%#"); } else { @@ -4508,9 +4508,9 @@ output_cbranch (operands, nullify, length, negated, insn) else strcat (buf, "%B3"); if (nullify) - strcat (buf, " %2,%1,0\n\tbl,n %0,0"); + strcat (buf, " %2,%r1,0\n\tbl,n %0,0"); else - strcat (buf, " %2,%1,0\n\tbl %0,0"); + strcat (buf, " %2,%r1,0\n\tbl %0,0"); } break; @@ -4523,9 +4523,9 @@ output_cbranch (operands, nullify, length, negated, insn) /* Create a reversed conditional branch which branches around the following insns. */ if (negated) - strcpy (buf, "com%I2b,%S3,n %2,%1,.+20"); + strcpy (buf, "com%I2b,%S3,n %2,%r1,.+20"); else - strcpy (buf, "com%I2b,%B3,n %2,%1,.+20"); + strcpy (buf, "com%I2b,%B3,n %2,%r1,.+20"); output_asm_insn (buf, operands); /* Output an insn to save %r1. */ @@ -4548,9 +4548,9 @@ output_cbranch (operands, nullify, length, negated, insn) /* Create a reversed conditional branch which branches around the following insns. */ if (negated) - strcpy (buf, "com%I2b,%S3,n %2,%1,.+28"); + strcpy (buf, "com%I2b,%S3,n %2,%r1,.+28"); else - strcpy (buf, "com%I2b,%B3,n %2,%1,.+28"); + strcpy (buf, "com%I2b,%B3,n %2,%r1,.+28"); output_asm_insn (buf, operands); /* Output an insn to save %r1. */ diff --git a/gcc/config/pa/pa.md b/gcc/config/pa/pa.md index 2f3848c28b3..b693f672a5e 100644 --- a/gcc/config/pa/pa.md +++ b/gcc/config/pa/pa.md @@ -1031,7 +1031,7 @@ [(set (pc) (if_then_else (match_operator 3 "comparison_operator" - [(match_operand:SI 1 "register_operand" "r") + [(match_operand:SI 1 "reg_or_0_operand" "rM") (match_operand:SI 2 "arith5_operand" "rL")]) (label_ref (match_operand 0 "" "")) (pc)))] @@ -1059,7 +1059,7 @@ [(set (pc) (if_then_else (match_operator 3 "comparison_operator" - [(match_operand:SI 1 "register_operand" "r") + [(match_operand:SI 1 "reg_or_0_operand" "rM") (match_operand:SI 2 "arith5_operand" "rL")]) (pc) (label_ref (match_operand 0 "" ""))))] |