This is the mail archive of the binutils-cvs@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[binutils-gdb] Fix bb instructions with double-word condition on hppa.


https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=2e957b16d45b8fe4396b16775f0b3fa77f71f0a0

commit 2e957b16d45b8fe4396b16775f0b3fa77f71f0a0
Author: John David Anglin <danglin@gcc.gnu.org>
Date:   Mon Jul 31 12:51:25 2017 -0400

    Fix bb instructions with double-word condition on hppa.

Diff:
---
 gas/ChangeLog        | 5 +++++
 gas/config/tc-hppa.c | 4 +---
 2 files changed, 6 insertions(+), 3 deletions(-)

diff --git a/gas/ChangeLog b/gas/ChangeLog
index 7b716c3..1a3439d 100644
--- a/gas/ChangeLog
+++ b/gas/ChangeLog
@@ -1,3 +1,8 @@
+2017-07-31  John David Anglin  <danglin@gcc.gnu.org>
+
+	* config/tc-hppa.c (pa_ip): Clear `d' bit in branch on bit instructions
+	with a double-word condition and a fixed bit position greater than 31.
+
 2017-07-28  Andrew Waterman  <andrew@sifive.com>
 
 	* config/tc-riscv.c (riscv_set_arch): Handle the Q subset like
diff --git a/gas/config/tc-hppa.c b/gas/config/tc-hppa.c
index 724b48b..e4ec892 100644
--- a/gas/config/tc-hppa.c
+++ b/gas/config/tc-hppa.c
@@ -5216,9 +5216,7 @@ pa_ip (char *str)
 	      s = expr_end;
 	      CHECK_FIELD (num, 63, 0, strict);
 	      if (num & 0x20)
-		;
-	      else
-		opcode |= (1 << 13);
+		opcode &= ~(1 << 13);
 	      INSERT_FIELD_AND_CONTINUE (opcode, num & 0x1f, 21);
 
 	    /* Handle a 5 bit immediate at 10.  */


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]