This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
Re: how to embed an arbitrary opcode
- From: Daniel Jacobowitz <drow at false dot org>
- To: John Breitenbach <breiten at lexmark dot com>
- Cc: binutils at sourceware dot org, Daniel Gutson <dgutson at codesourcery dot com>
- Date: Thu, 18 Jun 2009 17:25:44 -0400
- Subject: Re: how to embed an arbitrary opcode
- References: <4A3AA129.5090708@lpdev.prtdev.lexmark.com>
On Thu, Jun 18, 2009 at 04:18:49PM -0400, John Breitenbach wrote:
> Hi,
> I'm looking for a way to embed an arbitrary opcode into an assembly file
> for the ARM architecture. .long and
> friends implicitly mark their data as data, using the $d, and follow it
> with a $a to resume with executable code.
>
> This was a problem because we build code for be8 mode, and the linker
> needs to know what it executable code and
> thus what to swap. Our hand-coded opcode wasn't getting swapped.
> Objdump refuses to disassemble those
> opcodes even with the --disassemble-all flag.
>
> binutils version is a bit old, but its new to us: GNU assembler
> (CodeSourcery 2007q1-10. Marvell 2008q3-13 20081204) 2.17
There's no way to do this even in current binutils - but Daniel
Gutson's been working on it recently. I think we'll have
a patch posted for this soon.
--
Daniel Jacobowitz
CodeSourcery