54,99 €
inkl. MwSt.
Versandkostenfrei*
Erscheint vorauss. 24. September 2024
payback
27 °P sammeln
  • Broschiertes Buch

A hands-on, example-filled guide to the theory and practice of writing a C compiler: a computer program that translates code written by programmers into code the computer can read. Compilers are at the heart of everything programmers do—and they’re cool as heck—but they have an intimidating reputation. Writing a C Compiler makes this fascinating topic fun and accessible. This book is a step-by-step guide to writing your own compiler for a large subset of C. Your compiler will generate assembly code for the ubiquitous x64 processor architecture, so you’ll learn what it takes to compile a…mehr

Produktbeschreibung
A hands-on, example-filled guide to the theory and practice of writing a C compiler: a computer program that translates code written by programmers into code the computer can read. Compilers are at the heart of everything programmers do—and they’re cool as heck—but they have an intimidating reputation. Writing a C Compiler makes this fascinating topic fun and accessible. This book is a step-by-step guide to writing your own compiler for a large subset of C. Your compiler will generate assembly code for the ubiquitous x64 processor architecture, so you’ll learn what it takes to compile a real-world programming language to run on a real-world processor. You’ll build a working compiler for the simplest possible C programs in Chapter 1, then add a new feature in each subsequent chapter. You won’t need any prior knowledge of compiler construction or assembly code, and the implementation is presented in pseudocode, so you can write your compiler in whatever language you like.  You’ll learn how to: * Write a lexer and recursive descent parser to turn source code into an abstract syntax tree (AST) * Implement arithmetic operations, control-flow statements, and other C language constructs in x64 assembly * Use your system’s calling convention to call functions defined in external libraries * Perform several common optimizations, including constant folding and dead store elimination * Write a graph coloring register allocator to efficiently assign values to hardware registers In Writing a C Compiler, you’ll tackle a fun, challenging project—and gain a deeper understanding of the code you write and the systems it runs on.
Autorenporträt
Nora Sandler is a software engineer based in Seattle. She holds a BS in computer science from the University of Chicago, where she researched the implementation of parallel programming languages. After several years as a penetration tester, she found her way back to compilers. Most recently, she worked on domain-specific languages at an endpoint security company. You can read her blog about pranks, compilers, and other computer science topics at https://norasandler.com.