Book cover: Below the Code

A book in progress

Below the Code

How the chips that run your code (CPU, GPU, NPU) are structured and how they work

“How does my code actually run on circuits?”

Every line of code we write is ultimately turned into electrical signals and executed on a chip. Starting from a single transistor and building up layer by layer — logic circuits, computer architecture, and finally software — this book follows, from beginning to end, how code becomes the actual operation of a chip. With that understanding in hand, it then explores why CPUs, GPUs, and NPUs are designed differently, and how chips are made.

Who this book is for

  • Developers who write code but wonder how it actually runs inside a computer
  • Anyone curious about how CPUs, GPUs, and NPUs differ, and why chips matter so much in the age of AI
  • Readers who want to understand, from first principles, how semiconductor chips are designed and made

The path this book takes

  1. The big picture first — before diving into details, grasp the core of how a computer works as concepts.
  2. From the bottom up — start from the transistor and build up step by step: logic circuits, circuits for computation and memory, computer architecture, and software.
  3. Into the world of real chips — building on that understanding, look at how CPUs, GPUs, and NPUs are designed, how chips come into being, and the industry behind them.

Contents

Part 1 — The Principles Beneath the Code: From Circuits to Code

  1. 1. The Chips Working Beneath Your Code
  2. 2. The Computer Is Simpler Than It Looks
  3. 3. From Transistors to Logic Circuits
  4. 4. Electronic Circuits That Compute and Remember
  5. 5. The Computer That Runs on Instructions
  6. 6. The CPU Built from Circuits
  7. 7. Software (feat. the Instructions That Drive Hardware)Coming soon
  8. 8. Connecting Software and Hardware: The ISAComing soon

Part 2 — The Reality Beneath the Code: CPUs, GPUs, NPUs, and the World Where Chips Are Made

  1. 9. From the PC to AI: What Happened Beneath the CodeNEW
  2. 10. The CPU, Built to Run All Kinds of Programs FastComing soon
  3. 11. The GPU, Evolved to Draw the ScreenComing soon
  4. 12. The NPU, Built for AI's Repetitive ComputationComing soon
  5. 13. How Does My Code Use the CPU, GPU, and NPU?Coming soon
  6. 14. How a Chip Becomes a ProductComing soon
  7. 15. The People Who Make Chips, and How to Get StartedComing soon

New chapters are added here as they are completed. About this book and site →