linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Nick Desaulniers <ndesaulniers@google.com>
To: Josh Poimboeuf <jpoimboe@redhat.com>,
	Peter Zijlstra <peterz@infradead.org>
Cc: Arnd Bergmann <arnd@kernel.org>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	clang-built-linux <clang-built-linux@googlegroups.com>
Subject: Re: objtool crashes with some clang produced .o files
Date: Fri, 11 Dec 2020 16:47:00 -0800	[thread overview]
Message-ID: <CAKwvOdkdBxucLOf-9a+PK7K+yFLjjPWgncGrXwtE5BHK=uevDA@mail.gmail.com> (raw)
In-Reply-To: <CAKwvOdmVq2StZbKZ0eaLEZmrPMgRUJMZFso+2G8tLJA_Nd-swA@mail.gmail.com>

[-- Attachment #1: Type: text/plain, Size: 1541 bytes --]

On Fri, Dec 11, 2020 at 4:42 PM Nick Desaulniers
<ndesaulniers@google.com> wrote:
>
> On Fri, Dec 11, 2020 at 12:57 PM Nick Desaulniers
> <ndesaulniers@google.com> wrote:
> >
> > Thanks for the patch!
> >
> > Reviewed-by: Nick Desaulniers <ndesaulniers@google.com>
> > Link: https://github.com/ClangBuiltLinux/linux/issues/1207
>
> Arnd reported another objtool warning/error from another randconfig in
> https://github.com/ClangBuiltLinux/linux/issues/1209 and CrOS just hit
> this as well.
>
> I haven't been able to isolate the configs yet (Arnd has posted the
> full config: https://pastebin.com/wwwhUL8L
>
> $ ./tools/objtool/objtool orc generate  --no-fp --no-unreachable
> --retpoline arch/x86/entry/thunk_64.o
> arch/x86/entry/thunk_64.o: warning: objtool: missing symbol for insn
> at offset 0x3e
>
> Is the offset 0x3e referring to the final `ret` instruction in
> preempt_schedule_notrace_thunk?  Observing insn_to_reloc_sym_addend()
> (with your patch applied), it looks like both calls to
> find_symbol_containing() with offset and offset-1 returns NULL.  I'm
> curious if there's another quirk going on here, or possibly a config
> from the randconfig that's messing up the special case? I don't follow
> the comment about:
> 119        * Hack alert.  This happens when we need to reference
> 120        * the NOP pad insn immediately after the function.
> 121        */
>
> Attached the object file FWIW.

Resending with the attachment renamed; I just got a bounceback from
Josh's mailer daemon.
-- 
Thanks,
~Nick Desaulniers

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: thunk_64.o.txt --]
[-- Type: text/plain; charset="x-binaryenc"; name="thunk_64.o.txt", Size: 744 bytes --]

\x7fELF\x02\x01\x01\0\0\0\0\0\0\0\0\0\x01\0>\0\x01\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0¨\x01\0\0\0\0\0\0\0\0\0\0@\0\0\0\0\0@\0\x05\0\x01\0UH‰åWVRQPAPAQARASè\0\0\0\0ë\x18UH‰åWVRQPAPAQARASè\0\0\0\0ë\0A[AZAYAXXYZ^_]Ã\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0B\0\0\0\x10\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0S\0\0\0\x10\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0#\0\0\0\x12\0\x02\0\x18\0\0\0\0\0\0\0\x18\0\0\0\0\0\0\0\f\0\0\0\x12\0\x02\0\0\0\0\0\0\0\0\0\x18\0\0\0\0\0\0\0\x12\0\0\0\0\0\0\0\x04\0\0\0\x01\0\0\0üÿÿÿÿÿÿÿ*\0\0\0\0\0\0\0\x04\0\0\0\x02\0\0\0üÿÿÿÿÿÿÿ\0.rela.text\0preempt_schedule_thunk\0preempt_schedule_notrace_thunk\0preempt_schedule\0preempt_schedule_notrace\0.strtab\0.symtab\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0l\0\0\0\x03\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0(\x01\0\0\0\0\0\0|\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x01\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x06\0\0\0\x01\0\0\0\x06\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0@\0\0\0\0\0\0\0?\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x04\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x01\0\0\0\x04\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0ø\0\0\0\0\0\0\00\0\0\0\0\0\0\0\x04\0\0\0\x02\0\0\0\b\0\0\0\0\0\0\0\x18\0\0\0\0\0\0\0t\0\0\0\x02\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0€\0\0\0\0\0\0\0x\0\0\0\0\0\0\0\x01\0\0\0\x01\0\0\0\b\0\0\0\0\0\0\0\x18\0\0\0\0\0\0\0

  reply	other threads:[~2020-12-12  0:56 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-12-03 13:56 objtool crashes with some clang produced .o files Arnd Bergmann
2020-12-10 23:35 ` Nick Desaulniers
2020-12-11  8:45   ` Peter Zijlstra
2020-12-11  9:32   ` Peter Zijlstra
2020-12-11 16:37     ` Josh Poimboeuf
2020-12-11 16:49       ` Peter Zijlstra
2020-12-11 17:46         ` Josh Poimboeuf
2020-12-11 20:57           ` Nick Desaulniers
2020-12-12  0:42             ` Nick Desaulniers
2020-12-12  0:47               ` Nick Desaulniers [this message]
2020-12-14 12:49               ` Arnd Bergmann

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='CAKwvOdkdBxucLOf-9a+PK7K+yFLjjPWgncGrXwtE5BHK=uevDA@mail.gmail.com' \
    --to=ndesaulniers@google.com \
    --cc=arnd@kernel.org \
    --cc=clang-built-linux@googlegroups.com \
    --cc=jpoimboe@redhat.com \
    --cc=linux-kernel@vger.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;
as well as URLs for NNTP newsgroup(s).