Book description
Get to grips with LLVM essentials and use the core libraries to build advanced tools
In Detail
LLVM is a bleeding edge compiler technology framework. Easily extendable and designed as a multitude of libraries, LLVM provides a smooth experience for compiler newcomers and reduces the steep learning curve often associated with compiler development.
To start, this book will show you how to configure, build, and install LLVM libraries, tools, and external projects. Next, you will be introduced to LLVM design and how it works in practice throughout each LLVM compiler stage: frontend, IR, backend, the JIT engine, cross-compilation capabilities, and the plugin interface. With multiple hands-on examples and source code snippets, Getting Started with LLVM Core Libraries ensures a solid and smooth first step into the LLVM compiler development environment.
What You Will Learn
- Configure, build, and install extra LLVM open source projects including Clang tools, static analyzer, Compiler-RT, LLDB, DragonEgg, libc++, and LLVM test-suite
- Understand the LLVM library design and interaction between libraries and standalone tools
- Increase your knowledge of source code processing stages by learning how the Clang frontend uses a lexer, parser, and syntax analysis
- Manipulate, generate, and play with LLVM IR files while writing custom IR analyses and transformation passes
- Write tools to use LLVM Just-in-Time (JIT) compilation capabilities
- Find bugs and improve your code by using the static analyzer
- Design source code analysis and transformation tools using LibClang, LibTooling, and the Clang plugin interface
Publisher resources
Table of contents
-
Getting Started with LLVM Core Libraries
- Table of Contents
- Getting Started with LLVM Core Libraries
- Credits
- About the Authors
- About the Reviewers
- www.PacktPub.com
- Preface
- 1. Build and Install LLVM
- 2. External Projects
- 3. Tools and Design
- 4. The Frontend
- 5. The LLVM Intermediate Representation
-
6. The Backend
- Overview
- Learning the backend code structure
- Knowing the backend libraries
- Learning how to use TableGen for LLVM backends
- Understanding the instruction selection phase
- Scheduler
- Machine instructions
- Register allocation
- Prologue and epilogue
- Understanding the machine code framework
- Writing your own machine pass
- Summary
- 7. The Just-in-Time Compiler
- 8. Cross-platform Compilation
- 9. The Clang Static Analyzer
- 10. Clang Tools with LibTooling
- Index
Product information
- Title: Getting Started with LLVM Core Libraries
- Author(s):
- Release date: August 2014
- Publisher(s): Packt Publishing
- ISBN: 9781782166924
You might also like
book
Mastering Reverse Engineering
Implement reverse engineering techniques to analyze software, exploit software targets, and defend against security threats like …
book
HBR Guide to Critical Thinking
Tackle complex situations with critical thinking. You're facing a problem at work. There are many ways …
book
Build Your Own Programming Language
Written by the creator of the Unicon programming language, this book will show you how to …
book
Hands-On Embedded Programming with Qt
A comprehensive guide that will get you up and running with embedded software development using Qt5 …