We are pleased to announce the release of our book Rust Under the Hood.
Discover How Rust Works Under the Hood
- Learn how Rust represents, and pattern matches enums, tuples, and structs.
- Dig into implicit heap operations with
Box
andVec
. - Understand
string
and&str
representation and generated code.
Understand Dispatch Mechanisms
- Compare and contrast static vs. dynamic dispatch and the pivotal role of Vtables.
- Grasp how closures interact with their environments and manage state.
Rust Compiler Optimizations and SIMD
- Understand loop optimization and SIMD auto-vectorization.
- Explore strategies used for branch avoidance and function inlining.
- Learn how tail call optimization transforms recursive functions into loops.
Async Programming Insights
- Learn how Rust transforms async functions into state machines.
- Unravel the workings of async executors and the role of polling in async/await constructs.
Practical Learning
Use tools like Compiler Explorer and Rust Playground to reinforce your learning and gain hands-on experience with the generated x86-64 assembly.