Overview
Save Big on Coursera Plus. 7,000+ courses at $160 off. Limited Time Only!
Explore benchmarking and optimization techniques for Rust libraries in this 31-minute conference talk from RustConf 2018. Dive into the journey of consistently and fairly benchmarking library functions, and discover strategies for enhancing performance. Learn about micro vs. macro benchmarking, obtaining realistic workloads, and returning to fundamentals. Examine practical examples, including PostgreSQL write performance and storing decimal numbers. Investigate techniques such as exploiting fixed-size primitive types, copying vs. borrowing, and the potential use of unsafe code. Gain insights into developing high-quality, ergonomic, and performant Rust libraries to contribute to the growing Rust ecosystem.
Syllabus
Intro
New Zealand Accent 101
Growing Ecosystem
Micro vs Macro benchmarking
Obtaining realistic workloads
Back to fundamentals
Ex: PostgreSQL write performance
E.g. storing the number 3.14
Base-10 Implementation
Math implementation
Performance of math calculations
Representing a decimal
Exploiting fixed size primitive types
Copying vs Borrowing
What about unsafe?
Closing Thoughts
Taught by
Rust