[Bug gas/3109] GAS assembles incorrect branches using target arm-wince-pe

2006-08-23 Thread nickc at redhat dot com

--- Additional Comments From nickc at redhat dot com  2006-08-23 17:15 
---
Already fixed in mainline

-- 
   What|Removed |Added

 Status|WAITING |RESOLVED
 Resolution||INVALID


http://sourceware.org/bugzilla/show_bug.cgi?id=3109

--- You are receiving this mail because: ---
You are on the CC list for the bug, or are watching someone who is.


___
bug-binutils mailing list
bug-binutils@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug gas/3109] GAS assembles incorrect branches using target arm-wince-pe

2006-08-23 Thread boris dot leidner at formenos dot de

--- Additional Comments From boris dot leidner at formenos dot de  
2006-08-23 11:05 ---
Hi Nick,

you're right. The problem was not shown in my example. The relocations are 
correct:
$ arm-wince-pe-objdump -d armtest.o -r

armtest.o: file format pe-arm-little

Disassembly of section .text:

 <_start>:
   0:   e1a01001mov r1, r1
   4:   ea00b   8 <_start+0x8>
4: ARM_26D  _start

BTW: I provided the same o-file to GDB. That, of course, makes absolutely no
sense...I see.

In my special case I do not need linking, because the code is injected into a
process. So I just copy it out of the object file. GAS did not use relocations
in my code and even if I linked it, the binary contained faulty branches.
However, I noticed that this has truly been fixed in the repository. I'm sorry,
I did not check that first.

Greetings,

Boris

-- 


http://sourceware.org/bugzilla/show_bug.cgi?id=3109

--- You are receiving this mail because: ---
You are on the CC list for the bug, or are watching someone who is.


___
bug-binutils mailing list
bug-binutils@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug gas/3109] GAS assembles incorrect branches using target arm-wince-pe

2006-08-23 Thread nickc at redhat dot com


-- 
   What|Removed |Added

 Status|NEW |WAITING


http://sourceware.org/bugzilla/show_bug.cgi?id=3109

--- You are receiving this mail because: ---
You are on the CC list for the bug, or are watching someone who is.


___
bug-binutils mailing list
bug-binutils@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug gas/3109] GAS assembles incorrect branches using target arm-wince-pe

2006-08-23 Thread nickc at redhat dot com

--- Additional Comments From nickc at redhat dot com  2006-08-23 10:11 
---
Subject: Re:  New: GAS assembles incorrect branches using target
 arm-wince-pe

Hi Boris,

> $ arm-wince-pe-objdump -d armtest.o

This is insufficient.  Please add the "-r" switch to the objdump command 
line.

>  <_start>:
>0:   e1a01001mov r1, r1
>4:   ea00b   8 <_start+0x8>

The -r switch should show you that there is a relocation for the 
instruction at address 0x4, hence the disassembly is showing you an 
incomplete instruction.  (It would be better to run objdump on the fully 
linked executable, rather than the object file, as that way you do not 
have to worry about relocations).

> (gdb) disas _start
> Dump of assembler code for function _start:
> 0x <_start+0>:  mov r1, r1
> 0x0004 <_start+4>:  b   0xc

How did you create the file that you gave to GDB ?

Please try the latest sources in the binutils repository.  I believe 
that you will find that this bug has now been fixed.

Cheers
   Nick





-- 


http://sourceware.org/bugzilla/show_bug.cgi?id=3109

--- You are receiving this mail because: ---
You are on the CC list for the bug, or are watching someone who is.


___
bug-binutils mailing list
bug-binutils@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug gas/3109] GAS assembles incorrect branches using target arm-wince-pe

2006-08-23 Thread boris dot leidner at formenos dot de

--- Additional Comments From boris dot leidner at formenos dot de  
2006-08-23 09:58 ---
I do not know why objdump (not GAS) and GDB disassemble code differently

-- 


http://sourceware.org/bugzilla/show_bug.cgi?id=3109

--- You are receiving this mail because: ---
You are on the CC list for the bug, or are watching someone who is.


___
bug-binutils mailing list
bug-binutils@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-binutils