Re: [RFC] kmemcheck: trap uses of uninitialized memory (v2)

From: Pekka J Enberg
Date: Thu Nov 29 2007 - 07:05:31 EST


Hi Vegard,

On Thu, 29 Nov 2007, Vegard Nossum wrote:
> If I understand you correctly, you only want to be notified if any
> memory within an allocation is used before any memory within the
> allocation has been initialized. I think that this would be quite
> useless compared to tracking all the bytes of an allocation.

Ok, why is it useless? I am trying to understand what kind of errors you
hope to catch here.

On Thu, 29 Nov 2007, Vegard Nossum wrote:
> I am not truly concerned about the memory usage; this kind of error
> detection is by definition slow and memory intense.

There's "slow" and then there's "too slow for mainline" :-). But even if
you want to track every byte, you could use a bitmap in the slab layer to
cut down memory usage and get rid of "shadow pages", no?

Pekka
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/