From: "tip-bot2 for Samuel Zeter" <tip-bot2@linutronix.de>
To: linux-tip-commits@vger.kernel.org
Cc: Samuel Zeter <samuelzeter@gmail.com>,
Nathan Chancellor <nathan@kernel.org>,
Ingo Molnar <mingo@kernel.org>, Kees Cook <keescook@chromium.org>,
Masami Hiramatsu <mhiramat@kernel.org>,
x86@kernel.org, linux-kernel@vger.kernel.org
Subject: [tip: x86/build] x86/tools: objdump_reformat.awk: Allow for spaces
Date: Thu, 30 Nov 2023 08:51:33 -0000 [thread overview]
Message-ID: <170133429362.398.4707883263902716130.tip-bot2@tip-bot2> (raw)
In-Reply-To: <20231129-objdump-reformat-llvm-v3-2-0d855e79314d@kernel.org>
The following commit has been merged into the x86/build branch of tip:
Commit-ID: f4570ebd836363dc7722b8eb8d099b311021af13
Gitweb: https://git.kernel.org/tip/f4570ebd836363dc7722b8eb8d099b311021af13
Author: Samuel Zeter <samuelzeter@gmail.com>
AuthorDate: Wed, 29 Nov 2023 15:17:42 -07:00
Committer: Ingo Molnar <mingo@kernel.org>
CommitterDate: Thu, 30 Nov 2023 09:38:10 +01:00
x86/tools: objdump_reformat.awk: Allow for spaces
GNU objdump and LLVM objdump have differing output formats.
Specifically, GNU objump will format its output as: address:<tab>hex,
whereas LLVM objdump displays its output as address:<space>hex.
objdump_reformat.awk incorrectly handles this discrepancy due to
the unexpected space and as a result insn_decoder_test fails, as
its input is garbled.
The instruction line being tokenized now handles a space and colon,
or tab delimiter.
Signed-off-by: Samuel Zeter <samuelzeter@gmail.com>
Signed-off-by: Nathan Chancellor <nathan@kernel.org>
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Tested-by: Nathan Chancellor <nathan@kernel.org>
Tested-by: Kees Cook <keescook@chromium.org>
Reviewed-by: Kees Cook <keescook@chromium.org>
Acked-by: Masami Hiramatsu <mhiramat@kernel.org>
Link: https://lore.kernel.org/r/20231129-objdump-reformat-llvm-v3-2-0d855e79314d@kernel.org
Closes: https://github.com/ClangBuiltLinux/linux/issues/1364
---
arch/x86/tools/objdump_reformat.awk | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/x86/tools/objdump_reformat.awk b/arch/x86/tools/objdump_reformat.awk
index 276e572..a4120d9 100644
--- a/arch/x86/tools/objdump_reformat.awk
+++ b/arch/x86/tools/objdump_reformat.awk
@@ -22,7 +22,7 @@ BEGIN {
}
/^ *[0-9a-f]+:/ {
- if (split($0, field, "\t") < 3) {
+ if (split($0, field, /: |\t/) < 3) {
# This is a continuation of the same insn.
prev_hex = prev_hex field[2]
} else {
next prev parent reply other threads:[~2023-11-30 8:51 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-11-29 22:17 [PATCH v3 0/3] x86: Support llvm-objdump in instruction decoder selftest Nathan Chancellor
2023-11-29 22:17 ` [PATCH v3 1/3] x86/tools: objdump_reformat.awk: Ensure regex matches fwait Nathan Chancellor
2023-11-30 8:51 ` [tip: x86/build] " tip-bot2 for Samuel Zeter
2023-11-29 22:17 ` [PATCH v3 2/3] x86/tools: objdump_reformat.awk: Allow for spaces Nathan Chancellor
2023-11-30 8:51 ` tip-bot2 for Samuel Zeter [this message]
2023-11-29 22:17 ` [PATCH v3 3/3] x86/tools: Remove chkobjdump.awk Nathan Chancellor
2023-11-30 8:51 ` [tip: x86/build] " tip-bot2 for Nathan Chancellor
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=170133429362.398.4707883263902716130.tip-bot2@tip-bot2 \
--to=tip-bot2@linutronix.de \
--cc=keescook@chromium.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-tip-commits@vger.kernel.org \
--cc=mhiramat@kernel.org \
--cc=mingo@kernel.org \
--cc=nathan@kernel.org \
--cc=samuelzeter@gmail.com \
--cc=x86@kernel.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®