lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]

Mike Pall wrote:
>> Can you suggest any other references? Muchnick's book seems to be rather
>> hard to get hold of (and is apparently notoriously full of bugs, but
>> that's another matter).
> You can get a Chinese copy of most of these textbooks for a few
> dollars (same content in English, just with a Chinese cover). And
> I wouldn't say it's full of bugs, but then I rarely read the code
> examples. The biggest problem is that it's rather ancient by
> todays standards (e.g. it mentions SSA only in passing). AFAIK
> there is no up-to-date, comprehensive textbook on modern compiler
> design.

Surprisingly enough I actually found a copy in the tiny reference
library at work (sandwiched between vols. I-III of _The Art of Computer
Programming_ and someone else's copy of the Dragon Book) --- complete
with the big wodge of errata.

Having looked at the relevant chapter, it does look promising, but it's
not a complete solution. It's trivially easy in C to construct a graph
that won't neatly decompose into primitives that my target language
supports. Even something as simple as a C switch statement can't be
represented with if...then...else due to the requirement to fall through
from one block to another, for example.

So I'll bear it in mind, and thanks very much for the recommendation,
but I'll stick with gotos for the time being until I've had a chance to
vet how much of a performance impact using emulated gotos will have.
(The fact that writing graph traversal code is possibly my least
favourite programming task --- even ranking below documentation --- has
nothing to do with this...)

┌─── ───── ─────
│ "I have always wished for my computer to be as easy to use as my
│ telephone; my wish has come true because I can no longer figure out
│ how to use my telephone." --- Bjarne Stroustrup

Attachment: signature.asc
Description: OpenPGP digital signature