From: Ingo Molnar <mingo@elte.hu>
To: Vegard Nossum <vegard.nossum@gmail.com>
Cc: Pekka Enberg <penberg@cs.helsinki.fi>, linux-kernel@vger.kernel.org
Subject: Re: [GIT PULL] kmemcheck fixlets (for -tip)
Date: Mon, 29 Sep 2008 11:25:46 +0200 [thread overview]
Message-ID: <20080929092546.GB7735@elte.hu> (raw)
In-Reply-To: <19f34abd0809290213m54a2c485p5917fcd46747ad6@mail.gmail.com>
* Vegard Nossum <vegard.nossum@gmail.com> wrote:
> On Mon, Sep 29, 2008 at 10:55 AM, Ingo Molnar <mingo@elte.hu> wrote:
> > FYI, i've reactivated kmemcheck on one of the -tip auto-test boxes
> > earlier today and it's looking good so far - for example a 32-bit
> > allyesconfig-ish config booted in just fine with kmemcheck enabled.
> > Also, the box is very usable interactively - while previous one could
> > always tell whether there's kmemcheck active.
>
> Oops. Probably kmemcheck was not enabled (for all the right caches).
> Here's what may go wrong:
>
> 1. kmemcheck is in one-shot mode. Only one error is reported; after
> that, box will start returning to normal speed.
i'd have noticed that error.
> 2. SLUB debugging was enabled. kmemcheck will not track "debugged"
> caches, so I suggest turning SLUB off in kernel config, or by booting
> with "slub_debug=-". But I think that SLUB debug can be turned off in
> kernel config as well, which means that your randconfig testing will
> hit both cases eventually.
ok, slub debugging was indeed on. I'll re-test with that disabled.
> > [ only one CPU is active, but we knew that. We've still got this
> > test-commit:
> >
> > 21d01a4: x86: add functions for duplicating page tables
> >
> > it's not in tip/master but we still have it around. ]
> >
> > btw., is there any easy way to tell from within a script what the
> > current status of kmemcheck is? In particular, whether it's running.
> > Normally i have this in the syslog:
> >
> > [ 0.448022] kmemcheck: "Bugs, beware!"
> > [ 0.452002] kmemcheck: Limiting number of CPUs to 1.
> >
> > but this time the log was too large so this bit was snipped out and i
> > was unsure about it - needed a second bootup with a larger buffer to
> > make sure. With lockdep we've got the 'debug_locks' /proc/lockdep_stats.
> >
>
> You can read /proc/sys/kernel/kmemcheck. We also set a per-cache flag
> in slabs, so I think you can get some information from SLUB sysfs. But
> I agree -- it is not always easy to tell what kmemcheck is actually
> doing. Maybe some counters and stats would be appropriate.
ah, missed that flag.
> > also, all kmemcheck warnings follow the usual WARN_ON() format, so
> > that automated tests can pick it up, correct? -tip testing does so
> > many bootups that there's no chance to notice non-system-crashing
> > bugs and printouts but via automated means.
>
> Uhm, not correct. We need a few more infos (like read size, shadow,
> etc.), also the stacktraces are saved, so the default stacktrace of
> WARN is useless. But we can certainly try to emulate it. What text
> should I insert in order for your scripts to pick it up?
a kernel log line beginning with:
INFO:
WARNING:
BUG:
would be noticed. (That pattern has to be at the beginning of the line.
Otherwise we'd match on things like 'DEBUG: ' - such printouts exist)
Ingo
next prev parent reply other threads:[~2008-09-29 9:26 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-09-28 18:06 [GIT PULL] kmemcheck fixlets (for -tip) Vegard Nossum
2008-09-29 7:54 ` Ingo Molnar
2008-09-29 7:59 ` Ingo Molnar
2008-09-29 8:55 ` Ingo Molnar
2008-09-29 9:13 ` Vegard Nossum
2008-09-29 9:25 ` Ingo Molnar [this message]
2008-09-29 9:43 ` Ingo Molnar
2008-09-29 11:13 ` Ingo Molnar
2008-09-29 11:57 ` kmemcheck: Caught 32-bit read from uninitialized memory (f6038ec0) Ingo Molnar
2008-09-29 13:14 ` Ingo Molnar
2008-10-05 12:42 ` Vegard Nossum
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=20080929092546.GB7735@elte.hu \
--to=mingo@elte.hu \
--cc=linux-kernel@vger.kernel.org \
--cc=penberg@cs.helsinki.fi \
--cc=vegard.nossum@gmail.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.