Re: [PATCH 18/35] objtool: Another static block fail

From: Peter Zijlstra
Date: Mon Jan 29 2018 - 13:24:20 EST


On Mon, Jan 29, 2018 at 12:01:05PM -0600, Josh Poimboeuf wrote:
> On Fri, Jan 19, 2018 at 05:42:29PM +0100, Peter Zijlstra wrote:
> > Josh, how would you feel about adding the bits required to make objtool
> > a full disassembler? That would make it far easier to visualse the state
> > and I don't think its _that_ much more, all the difficult bits are
> > already done afaict, all we need is infrastructure to print the already
> > fully decoded instruction.
>
> It sounds interesting, but I have no idea what you mean :-) Can you
> elaborate?

Well, having had to debug the objtool state, I end up printing
sec+offset and then matching up with objdump output. It might be easier
to just print annotated assembly in one go.

Of course, to make that so, we have this small matter of actually
implementing the bits that print the instructions first ;-)