- Добавил: literator
- Дата: 1-01-2024, 18:09
- Комментариев: 0
Название: Introduction to Compiler Design 3rd Edition
Автор: Torben Ægidius Mogensen
Издательство: Springer
Серия: Undergraduate Topics in Computer Science
Год: 2024
Страниц: 303
Язык: английский
Формат: pdf (true), epub
Размер: 23.6 MB
In order to reduce the complexity of designing and building computers, nearly all of these are made to execute relatively simple commands (but do so very quickly). A program for a computer must be built by combining these very simple commands into a program in what is called machine language. Since this is a tedious and error-prone process, most programming is done using a high-level programming language. This language can be very different from the machine language that the computer can execute, so some means of bridging the gap is required. This is where the compiler comes in. A compiler translates (or compiles) a program written in a high-level programming language that is suitable for human programmers into the low-level machine language that is required by computers. During this process, the compiler will also attempt to detect and report obvious programmer mistakes. Using a high-level language for programming has a large impact on how fast programs can be developed. The third edition of this textbook has been fully revised and adds material about the SSA form, polymorphism, garbage collection, and pattern matching. It presents techniques for making realistic compilers for simple to intermediate-complexity programming languages. The techniques presented in the book are close to those used in professional compilers, albeit in places slightly simplified for presentation purposes. "Further reading" sections point to material about the full versions of the techniques. All phases required for translating a high-level language to symbolic machine language are covered, and some techniques for optimising code are presented. The intermediate language is translated to assembly language (a textual representation of machine code) for a specific machine architecture. The assembly language code is translated into binary representation and addresses of variables, functions, etc., are determined.
Автор: Torben Ægidius Mogensen
Издательство: Springer
Серия: Undergraduate Topics in Computer Science
Год: 2024
Страниц: 303
Язык: английский
Формат: pdf (true), epub
Размер: 23.6 MB
In order to reduce the complexity of designing and building computers, nearly all of these are made to execute relatively simple commands (but do so very quickly). A program for a computer must be built by combining these very simple commands into a program in what is called machine language. Since this is a tedious and error-prone process, most programming is done using a high-level programming language. This language can be very different from the machine language that the computer can execute, so some means of bridging the gap is required. This is where the compiler comes in. A compiler translates (or compiles) a program written in a high-level programming language that is suitable for human programmers into the low-level machine language that is required by computers. During this process, the compiler will also attempt to detect and report obvious programmer mistakes. Using a high-level language for programming has a large impact on how fast programs can be developed. The third edition of this textbook has been fully revised and adds material about the SSA form, polymorphism, garbage collection, and pattern matching. It presents techniques for making realistic compilers for simple to intermediate-complexity programming languages. The techniques presented in the book are close to those used in professional compilers, albeit in places slightly simplified for presentation purposes. "Further reading" sections point to material about the full versions of the techniques. All phases required for translating a high-level language to symbolic machine language are covered, and some techniques for optimising code are presented. The intermediate language is translated to assembly language (a textual representation of machine code) for a specific machine architecture. The assembly language code is translated into binary representation and addresses of variables, functions, etc., are determined.