lkml.org 
[lkml]   [2018]   [Dec]   [29]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [GIT PULL 2/4] Kbuild updates for v4.21 part2
On Fri, Dec 28, 2018 at 8:00 AM Masahiro Yamada
<yamada.masahiro@socionext.com> wrote:
>
> Introduce a new option CONFIG_NO_AUTO_INLINE as well. With this option,
> only functions explicitly marked with "inline" will be inlined. This
> will allow the function tracer to trace more functions.

Ugh. This causes new and bogus warnings, because gcc doesn't see some
of the checks.

For example, the x86 emulate_vsyscall() function now warns that

warning: ‘syscall_nr’ may be used uninitialized in this function

because addr_to_vsyscall_nr() isn't inlined any more, so gcc doesn't
see that the return value is always smaller than three (and then it
doesn't see that we handle all the cases in the switch statement
later).

So honestly, these "debugging improvements" have a rather nasty side
effect. I'm not at all convinced that we should do this. It is *not*
worth causing extra development pain with a totally pointless option
that changes code generation radically like this. It's going to cause
lots of extra churn.

This branch already added a couple of extra inline markers just to
make code work reasonably. How many tens (or hundreds) got missed just
because the build still works, but the lack of inlining means that we
generate completely garbage code?

I'm going to skip this pull request.

We have basically always required a certain level of competence from
the compiler, and this basically says that the compiler can do stupid
things and we'd have to fix those stupidities by hand.

Linus

\
 
 \ /
  Last update: 2018-12-29 22:01    [W:0.042 / U:2.172 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site