From: Alexandre Chartre <alexandre.chartre@oracle.com>
To: Josh Poimboeuf <jpoimboe@kernel.org>
Cc: alexandre.chartre@oracle.com, linux-kernel@vger.kernel.org,
mingo@kernel.org, peterz@infradead.org
Subject: Re: [RFC PATCH v2 00/17] objtool: Function validation tracing
Date: Wed, 24 Sep 2025 11:25:35 +0200 [thread overview]
Message-ID: <e60c22fd-3e91-4a93-a90c-53cda227800d@oracle.com> (raw)
In-Reply-To: <jxvtccnmr35xtevd7kjd5tn4n4bpwvfo2baajidwv5yfsvqcvb@mj7t4zfpllm7>
On 9/24/25 00:33, Josh Poimboeuf wrote:
> On Thu, Jun 19, 2025 at 04:56:42PM +0200, Alexandre Chartre wrote:
>> Hi,
>>
>> Version v2 of this RFC addresses all comments from Josh and Peter,
>> in particular:
>>
>> - add --disas option to disassemble functions
>> - do not fail the build if libopcodes is not available. Instead objtool
>> is then built without disassembly support. In that case, objtool prints
>> a warning message if trying to use disassembly.
>>
>> Example:
>> $ ./tools/objtool/objtool --disas --link vmlinux.o
>> vmlinux.o: warning: objtool: Rebuild with libopcodes for disassembly support
>>
>> - remove dbuffer
>> - rename VTRACE* to TRACE*
>> - add trace.[ch] for trace-related functions and macros
>
> Sorry for the delay... this is looking really good. A few nits I saw
> when testing:
>
> 1) With "make -s" I see
>
> Auto-detecting system features:
> ... libbfd: [ on ]
> ... disassembler-init-styled: [ on ]
>
> but I'm thinking that should be completely silent?
>
>
> 2) Also seeing an oddity with --trace:
>
> $ OBJTOOL_ARGS='--trace=shrink_node' make -s -j12 mm/vmscan.o
> shrink_node: validation begin
> 12440: shrink_node push %rbp - - statecfa=rsp+16 rbp=(cfa-16) stack_size=16
> 12440: shrink_node push %rbp
> 12441: shrink_node+0x1 mov %rsp,%rbp - - statecfa=rbp+16
> 12441: shrink_node+0x1 mov %rsp,%rbp
>
> For the instructions which have unwinding state changes, it's printing
> them twice. Also the formatting looks a little off (two dashes;
> "statecfa").
>
Thanks for all comments, I will address them and also resync the code.
alex.
next prev parent reply other threads:[~2025-09-24 9:26 UTC|newest]
Thread overview: 35+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-06-19 14:56 Alexandre Chartre
2025-06-19 14:56 ` [RFC PATCH v2 01/17] objtool: Move disassembly functions to a separated file Alexandre Chartre
2025-06-19 14:56 ` [RFC PATCH v2 02/17] objtool: Create disassembly context Alexandre Chartre
2025-09-23 22:23 ` Josh Poimboeuf
2025-06-19 14:56 ` [RFC PATCH v2 03/17] objtool: Disassemble code with libopcodes instead of running objdump Alexandre Chartre
2025-06-19 14:56 ` [RFC PATCH v2 04/17] tool build: Remove annoying newline in build output Alexandre Chartre
2025-06-19 14:56 ` [RFC PATCH v2 05/17] objtool: Print symbol during disassembly Alexandre Chartre
2025-06-19 14:56 ` [RFC PATCH v2 06/17] objtool: Improve offstr() output Alexandre Chartre
2025-09-23 22:23 ` Josh Poimboeuf
2025-06-19 14:56 ` [RFC PATCH v2 07/17] objtool: Store instruction disassembly result Alexandre Chartre
2025-06-19 14:56 ` [RFC PATCH v2 08/17] objtool: Disassemble instruction on warning or backtrace Alexandre Chartre
2025-06-19 14:56 ` [RFC PATCH v2 09/17] objtool: Extract code to validate instruction from the validate branch loop Alexandre Chartre
2025-06-19 14:56 ` [RFC PATCH v2 10/17] objtool: Record symbol name max length Alexandre Chartre
2025-06-19 14:56 ` [RFC PATCH v2 11/17] objtool: Add option to trace function validation Alexandre Chartre
2025-09-23 22:25 ` Josh Poimboeuf
2025-06-19 14:56 ` [RFC PATCH v2 12/17] objtool: Trace instruction state changes during " Alexandre Chartre
2025-06-19 14:56 ` [RFC PATCH v2 13/17] objtool: Improve register reporting " Alexandre Chartre
2025-06-19 14:56 ` [RFC PATCH v2 14/17] objtool: Improve tracing of alternative instructions Alexandre Chartre
2025-06-19 14:56 ` [RFC PATCH v2 15/17] objtool: Do not validate IBT for .return_sites and .call_sites Alexandre Chartre
2025-06-19 14:56 ` [RFC PATCH v2 16/17] objtool: Add the --disas=<function-pattern> action Alexandre Chartre
2025-06-19 14:56 ` [RFC PATCH v2 17/17] objtool: Disassemble all alternatives when using --disas Alexandre Chartre
2025-09-23 22:33 ` [RFC PATCH v2 00/17] objtool: Function validation tracing Josh Poimboeuf
2025-09-24 9:25 ` Alexandre Chartre [this message]
2025-09-24 7:36 ` Peter Zijlstra
2025-09-24 7:42 ` Peter Zijlstra
2025-09-24 10:08 ` Peter Zijlstra
2025-09-24 10:10 ` Peter Zijlstra
2025-09-24 10:52 ` Alexandre Chartre
2025-09-24 10:58 ` Peter Zijlstra
2025-09-24 11:45 ` Peter Zijlstra
2025-09-24 11:57 ` Alexandre Chartre
2025-09-24 9:17 ` Peter Zijlstra
2025-09-24 9:50 ` Alexandre Chartre
2025-09-24 9:57 ` Peter Zijlstra
2025-09-24 9:37 ` Alexandre Chartre
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=e60c22fd-3e91-4a93-a90c-53cda227800d@oracle.com \
--to=alexandre.chartre@oracle.com \
--cc=jpoimboe@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@kernel.org \
--cc=peterz@infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®