Subject: Re: [PATCH net-next 4/4] filter: add minimal BPF JIT emitted image disassembler

From: Daniel Borkmann <[email-masked]>
Date: Wed, 20 Mar 2013 09:50:41 +0100

On 03/20/2013 03:58 AM, Ben Hutchings wrote:
> On Tue, 2013-03-19 at 14:28 +0100, Daniel Borkmann wrote:
>> This is a minimal stand-alone user space helper, that allows for debugging or
>> verification of emitted BPF JIT images. This is in particular useful for
>> emitted opcode debugging, since minor bugs in the JIT compiler can be fatal.
>> The disassembler is architecture generic and uses libopcodes and libbfd.
> [...]
>> ---
>>   scripts/bpf_jit_disasm.c | 216 +++++++++++++++++++++++++++++++++++++++++++++++
>>   1 file changed, 216 insertions(+)
>>   create mode 100644 scripts/bpf_jit_disasm.c
> [...]
>
> This might belong in tools.  scripts is mostly for build scripts now.

Ok, I thought this would be overkill, since it's just a small C program
(unlike perf, etc) and there are also other things present in scripts/
like Coccinelle scripts etc. But, sure we could do this. What would you
suggest? tools/net/bpf_jit_disasm.c?