Re: Static analysis of the Linux kernel

Kenneth Albanowski (kjahds@kjahds.com)
Sun, 2 Aug 1998 21:11:44 -0400 (EDT)


On Sun, 2 Aug 1998, John G. Alvord wrote:

> On 01 Aug 1998 19:16:29 +0200, Francois-Rene Rideau
> <I+fare+WANT@tunes.NO.org.SPAM> wrote:
>
> >Dear Linus and Kernel hackers,
> >
> >torvalds@transmeta.com (Linus Torvalds) writes:
> >> Well, if we had a static analysis tool we'd obviously be able to track a
> >> lot of things that we can't currently track. You could build a tree of all
> >> calling sequences, and statically verify quite a few rules. You might not
> >> prove correctness, but you could find a lot of things like this.
> >>
> >> Dreaming? Yes.

FWIW, there are quite a number of other interesting things you could do
with such a tool (or a closely related one), including stack usage
analysis, static buffer tracking (a function that uses a static buffer
must not recurse or call another function that uses the same buffer), etc.

However, as usual, actually doing this seems too close to writing a
compiler. But I don't see anyone hacking this sort of stuff into GCC.

-- 
Kenneth Albanowski (kjahds@kjahds.com, CIS: 70705,126)

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.altern.org/andrebalsa/doc/lkml-faq.html