Skip to content

Commit

Permalink
ld/testsuite/
Browse files Browse the repository at this point in the history
2076-02-02  H.J. Lu  <hongjiu.lu@intel.com>

	* ld-i386/pcrel16.d: Updated.
	* ld-x86-64/pcrel16.d: Likewise.

opcodes/

2076-02-02  H.J. Lu  <hongjiu.lu@intel.com>

	* i386-dis.c (OP_J): Mask to 16bit only if there is a data16
	prefix.
  • Loading branch information
H.J. Lu committed Feb 3, 2007
1 parent c51882d commit 5b95cea
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 3 deletions.
5 changes: 5 additions & 0 deletions ld/testsuite/ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
2076-02-02 H.J. Lu <hongjiu.lu@intel.com>

* ld-i386/pcrel16.d: Updated.
* ld-x86-64/pcrel16.d: Likewise.

2007-02-01 Alan Modra <amodra@bigpond.net.au>

* ld-scripts/default-script.exp: Add "--local-store 0:0" to
Expand Down
2 changes: 1 addition & 1 deletion ld/testsuite/ld-i386/pcrel16.d
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,4 @@ Disassembly of section .text:
420: cd 42[ ]+int \$0x42
422: ca 02 00[ ]+lret \$0x2
...
f065: e9 b8 13[ ]+jmp 420 <_start\+0x420>
f065: e9 b8 13[ ]+jmp 10420 <__bss_start\+0x3b8>
2 changes: 1 addition & 1 deletion ld/testsuite/ld-x86-64/pcrel16.d
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,4 @@ Disassembly of section .text:
420: cd 42[ ]+int \$0x42
422: ca 02 00[ ]+lret \$0x2
...
f065: e9 b8 13[ ]+jmp 420 <_start\+0x420>
f065: e9 b8 13[ ]+jmp 10420 <_start\+0x10420>
5 changes: 5 additions & 0 deletions opcodes/ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
2076-02-02 H.J. Lu <hongjiu.lu@intel.com>

* i386-dis.c (OP_J): Mask to 16bit only if there is a data16
prefix.

2007-02-02 H.J. Lu <hongjiu.lu@intel.com>

* avr-dis.c (avr_operand): Correct PR number in comment.
Expand Down
5 changes: 4 additions & 1 deletion opcodes/i386-dis.c
Original file line number Diff line number Diff line change
Expand Up @@ -4916,10 +4916,13 @@ OP_J (int bytemode, int sizeflag)
else
{
disp = get16 ();
if ((disp & 0x8000) != 0)
disp -= 0x10000;
/* For some reason, a data16 prefix on a jump instruction
means that the pc is masked to 16 bits after the
displacement is added! */
mask = 0xffff;
if ((prefixes & PREFIX_DATA))
mask = 0xffff;
}
used_prefixes |= (prefixes & PREFIX_DATA);
break;
Expand Down

0 comments on commit 5b95cea

Please sign in to comment.