[prev in list] [next in list] [prev in thread] [next in thread]
List: linux-sparse
Subject: Re: Doing CSE in sparse..
From: Linus Torvalds <torvalds () osdl ! org>
Date: 2004-11-23 23:22:03
Message-ID: Pine.LNX.4.58.0411231516190.20993 () ppc970 ! osdl ! org
[Download RAW message or body]
On Tue, 23 Nov 2004, Linus Torvalds wrote:
>
> Well, I actually did write a simple dominator, but I guess it counts as a
> "fast O(mn)" rather than anything really good.
>
> It seems to work, and makes us CSE a lot better.
Btw, even with the "pure dominance" thing (assuming I got it right, of
course), it takes CSE from finding just a couple of entries in parse.c to
finding 70 instructions to be CSE'd.
Of course, by now it's actually pretty hard to see when I do something
wrong, since any interesting cases end up being pretty big. But the way I
re-write the instructions when cse'ing, you can at least see very clearly
what I do in the "test-linearize" output (ie the same way loads and stores
have been changed to special no-ops that show what they used to be, the
CSE thing changes the instruction into a special cse no-op that shows what
the source of the CSE was).
Any CSE that does code movement is likely to be better still, but
obviously at that point there is always the worry that you might move
something unimportant in an error path into a hot path, so code movement
might sometimes deprove things. I think.
Linus
-
To unsubscribe from this list: send the line "unsubscribe linux-sparse" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic