A magazine about programmers, code, and society. Written by and for humans since 2018.

Vikram Chandra

There are a lot of different things we could have talked about in the Library section of an edition dedicated to compilers; one obvious choice would have been to talk about the quintessential compiler theory book, the 1986 “Dragon Book” also known as “Compilers: Principles, Techniques, and Tools” by Alfred V. Aho, Ravi Sethi, and Jeffrey D. Ullman. As excellent and Wikipedia-worthy as this one is, that is not the book we will talk about here.

We are in 2025, and there is no shortage of excellent resources devoted to the craft of compiler making. For the sake of the curious among you, we can mention a few honorable choices, at least according to the taste of this author.

We have already mentioned in the pages of this magazine (during the edition dedicated to the Go programming language) the fantastic “Writing An Interpreter In Go” and “Writing A Compiler In Go” by Thorsten Ball. We can only wish Mr. Ball a boost in sales after the one and only Anders Hejlsberg recently announced a rewrite of the TypeScript compiler… using the Go programming language, precisely.

Definitely worthy of mention are also “Modern Compiler Design”, a book written in 2000 by Grune, Bal, Jacobs, and Langendoen. The beautiful and recent “Crafting Interpreters” by Robert Nystrom. Or the 1996 “Compiler Construction” book by none other than Niklaus Wirth. Speaking about celebrities, the long-awaited Volume 7 of “The Art of Computer Programming” by Donald Knuth will be titled “Compiler Techniques”… hopefully.

It would be unfair to leave Jack Crenshaw’s classic “Let’s Build a Compiler” series out of this review. Originally published between 1988 and 1995 at the “comp.compilers” Usenet newsgroup, and illustrating the construction of a compiler written in the Pascal programming language targeting the Motorola 68000 CPU architecture, this resource has been adapted and prettified numerous times, for example into C compiling to x86 code, in Go, in JavaScript, and yes, even in Rust, because we have to rewrite all things with it.

Maybe you prefer to see the source code of a compiler? Instead of dealing with open source behemoths such as LLVM, GCC, GraalVM, or the V8 JavaScript engine, you could instead study a compiler for a small subset of Scala, or the embeddable and short (merely 20'000 lines of code) LCC compiler. If you are still interested in diving into the LLVM source code, remember that Amy Brown and Greg Wilson have your back.

Want more? Check out the seminal paper titled “A Catalogue of Optimizing Transformations” written in 1971 by IBM engineers Frances Elizabeth Allen (the first woman to win a Turing Award) and John Cocke (usually referred to as “the father of the RISC architecture”). On pages 34 to 52 of the October 1978 edition of Byte Magazine, interspersed in between all the advertising, you could find the commented source code of a Pascal compiler written in BASIC. There is also Loren Segal’s article called “Writing Your Own Toy Compiler Using Flex, Bison and LLVM”, and Douglas Thain’s free e-book, “Introduction to Compilers and Language Design”. And we could go on and on, including tutorials and online courses and university lectures about the subject.

Phew. Clearly, a lot of ink has been spilled about compilers during the past 50 years. No need to say more; instead, and following our style, we decided to steer away from dry subjects such as abstract syntax trees, generators, P-code, and what-have-you, instead focusing on a book that deserves more praise. One that, in all honesty, we completely forgot to mention when we reviewed our brief history of programming artists, more than 6 years ago. We feel bad about this omission, so here we are trying to fix this injustice.

This month’s Library entry is “Geek Sublime: Writing Fiction, Coding Software”, a 2014 book by Vikram Chandra, and which, if you have not already, I beg you to grab a copy of and read it. Never before have I implored my readers to read a book; I am doing this now.

And no, this is not going to be a classic book review article, either; we leave that job to Jacob Silverman from The New Republic, who did an excellent job at precisely that in 2014:

If it’s not apparent already, this isn’t your typical tech book. Despite its thin profile, Geek Sublime is unusually expansive and rich. Its concerns are deeply heterodox: the difficulty and joys of coding, Sanskrit linguistics and literary theory, free market ideology, British colonial history, Indians in Silicon Valley, the writing of Chandra’s first novel, suppressed Hindu sects, women’s diminished status in the tech industry (in India, the situation is markedly better).

In my own personal website I sketched some notes that convey the sense of wonder I got through the lecture of this gem back in the day:

An absolute surprise, a delightful read. Astonishing and very, very deep. The geek part is actually almost irrelevant. The key is language, communication, gender, history, preservation, unity, rasa and dhvani through literature and poetry. Extraordinary.

What? Rasa? Dhvani? What are those things, and what do they have to do with code? Vikram Chandra explains:

Dhvani derives from dhvan, “to reverberate”; dhvani poetry therefore causes an endless resonance within the reader—“the suggested sense [flashes] forth in an instant in the minds of intelligent auditors who are averse to the literal sense and in quest of the real meaning.” (…)
So rasa—the word literally means “taste” or “juice”—is not emotion (bhava); it is the aestheticized satisfaction or “sentiment” of tasting artificially induced emotions.

And the connection comes in chapter 10:

The effects of code will spill out from the compiler; its vyanjana or suggestiveness will echo through the world and the human body. Undoubtedly, artists will—and already do—arrange this suggestion to manifest dhvani and rasa.

In his ground-breaking “Tractatus Logico-Philosophicus” published in 1922, Austrian philosopher Ludwig Wittgenstein wrote this (often quoted) phrase:

Die Grenzen meiner Sprache bedeuten die Grenzen meiner Welt.

In English: “The limits of my language stand for the limits of my world”.

Programmers, as users of compilers, experience Wittgenstein’s observation every day; newer programming languages provide more sophisticated ways to express algorithms, thereby expanding the limits of their own programming capacity, LLMs and “vibe coding” notwithstanding. Compiler and language designers “frame” the ways in which an algorithm can be described, and thus, how a programmer can express themselves, hopefully providing Turing completeness in the mix.

In “Geek Sublime”, Chandra connects East and West, Lacan and Abhinavagupta, and, needless to say, in a much more serious way than Geoffrey James’ “Tao of Programming”:

Jacques Lacan broke from the psychoanalytic establishment with his famous manifesto “The Function and Field of Speech and Language in Psychoanalysis,” and in this speech he refers directly to Abhinavagupta and dhvani theory, invoking “the teaching of Abhinavagupta” to elaborate upon “the property of speech by which it communicates what it does not actually say.” Lacan argued that the unconscious “does not express itself in speech; it reveals itself through suggestion,” and that the analyst should deploy the power of dhvani “in a carefully calculated fashion in the semantic resonances of his remarks.”

As programmers, we have a never-ending duty of expanding our horizons, learning new languages every so often (of the human and programming kind), and increasing our capacity for understanding. This ongoing task will make us not only better programmers, but also better humans. In this time and age, we need more of this superpower called empathy. And Vikram Chandra’s book is all about his own personal quest for knowledge and wisdom, both through computer and human lingo.

No need to drop acid, as Steve Jobs allegedly once told Bill Gates; this book will do, thankyousomuch.

Now that the summer months are approaching in the Northern Hemisphere, I can only wish you to carry in your bag a copy of “Geek Sublime” by Vikram Chandra, either in paper or in electronic form, and enjoy your well-deserved time off with a book that speaks not just to your brain, but also, and most importantly, directly to your heart.

Cover photo from the book’s website.

Back to top