[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CANpmjNPc7Hs0LvXPe540rgCzFAe9B7ec-ddStGfxVU_mtvFKOQ@mail.gmail.com>
Date: Mon, 31 Aug 2020 08:41:27 +0200
From: Marco Elver <elver@...gle.com>
To: Linus Torvalds <torvalds@...ux-foundation.org>
Cc: Thomas Gleixner <tglx@...utronix.de>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
"the arch/x86 maintainers" <x86@...nel.org>
Subject: Re: [GIT pull] sched/urgent for v5.9-rc2
On Sun, 30 Aug 2020 at 20:54, Linus Torvalds
<torvalds@...ux-foundation.org> wrote:
> On Sun, Aug 30, 2020 at 11:04 AM Thomas Gleixner <tglx@...utronix.de> wrote:
> >
> > - Make is_idle_task() __always_inline to prevent the compiler from putting
> > it out of line into the wrong section because it's used inside noinstr
> > sections.
>
> What completely broken compiler uninlined that single-instruction function?
>
> I've obviously pulled this, but it sounds like there should be a
> compiler bug-report for this insane behavior.
>
> Or is Marco building the kernel without optimizations or something
> like that? That has not been a supported model, for various good
> reasons..
Certainly with optimizations, but also with various debug options and
sanitizer instrumentation. (FTR, the config used:
https://lore.kernel.org/lkml/20200820144931.GA4120397@elver.google.com/3-a.txt
on GCC 10.1 with GCC 11's KCSAN patches backported.)
Checking GCC's sources, the inlining policy here is that the compiler
tries to sanitize as many functions as possible, and if only 'inline'
is used, it'll avoid inlining such a function into a 'no_sanitize'
function in favor of instrumenting it.
With a normal non-debug config this should therefore never happen.
Thanks,
-- Marco
Powered by blists - more mailing lists