Writing a C Compiler
By: Nora Sandler | Publisher: No Starch Press | Year: 2024
ISBN: 9781718500426
MRP: Rs. 6,894.00
You Pay: Rs. 5,859.00
You save: Rs. 1,035.00 ( 15% )
Usually ships in 2-3 days
Reward points: 58 points
Available for delivery worldwide.
Description
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.
A comprehensive, hands-on tutorial to writing a C compiler: a computer program that translates code written by the programmer into code the computer can understand. By building a compiler, readers will gain invaluable knowledge about how programming languages work; knowledge that will make them better programmers. Readers are gently led step-by-step to build a small working compiler and will develop throughout the book. Writing a C Compiler offers readers an accessible, practical approach to this complex and often overly theoretical topic.
About the Author
Nora Sandler is a software engineer. After graduating from the University of Chicago, she worked as a penetration tester at Security Innovation, and then as a compiler developer at CrowdStrike, fuelling her interest and research into how computers work under the hood. Sandler writes C Compiler tutorials and has created test programs on her popular blog (https://norasandler.com/) to make writing a C compiler more accessible.
Table of contents
Introduction
Part I: The Basics
1. Introduction to Compilers
2. Returning an Integer
3. Unary Operators
4. Binary Operators
5. Logical and Relational Operators
6. Local Variables
7. If Statements and Conditional Expressions
8. Compound Statements
9. Loops
10. Functions
11. Static Variables
Part II: Implementing Types
12. Long Integers
13. Unsigned Integers
14. Floating-point numbers
15. Pointers
16. Arrays and Pointer Arithmetic
17. Characters and Strings
18. Supporting Dynamic Memory Allocation
19. Structures
Part III: Optimizations
20. Optimizing TACKY Programs
21. Register Allocation