This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB 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]

Re: [PATCH] Fix alignment of disassemble /r


Ping for maintainer feedback.

Thanks,

    Daniel.

On Fri, Apr 11, 2014 at 7:24 PM, Daniel Gutson
<daniel.gutson@tallertechnologies.com> wrote:
> Hi,
>
>    when disassembling in raw mode (/r) in a variable-length insn
> architecture (i.e. x86),
> the output can be completely messed since no alignment takes place.
>
> I am aware of the uiout->table stuff, but it seems an overkill since I
> should change
> the current_uiout when disassembling in this mode (and I didn't find
> any actual use of this
> machinery at least for x86).
> Therefore, I added a hack in the dump_insns when the /r flag is specified.
> This clearly isn't the cutiest thing in the world, and I specified a
> hardcoded maximum number
> of opcode bytes to align (currently 8) though it is easily changeable.
>
> Please let me know if this approach is OK or I should do something
> else. Maybe consider whether
> current arch is insn-len variable?
>
> If this happens to be OK, please commit it for me since I don't have
> write access.
>
> Thanks,
>
>    Daniel.
>
>
> 2014-04-11  Daniel Gutson  <daniel.gutson@tallertechnologies.com>
>
>         * disasm.c (dump_insns): Added right alignment when showing opcodes.



-- 

Daniel F. Gutson
Chief Engineering Officer, SPD


San Lorenzo 47, 3rd Floor, Office 5

CÃrdoba, Argentina


Phone: +54 351 4217888 / +54 351 4218211

Skype: dgutson


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