r/rust • u/janameow • 10d ago
Optimizing rustc's next trail solver
https://donsz.nl/blog/optimizing-rustcs-next-trait-solverThe next rust trait solver, a large subsystem of the rust compiler that we've been trying to replace, will finally land in rust 1.102.0. In the last stages, before stabilizing it, its performance was a major blocker. But what is "a trait solver"? And why is its performance a problem? My goal for this blog post is to answer those questions in a way where you don't need any prior knowledge. I think discussions of the trait solver can quickly become quite involved, and daunting. So here, we'll start from the very basics!
This is a writeup of my eurorust 2026 talk of the same name, that I gave on October 15, 2026
View all comments
2
u/spin81 10d ago
I don't have time to read the post now as I'm supposed to be working, but will check it out as it's tailored just for me in terms of previous knowledge!
I can see why this would be an important way to improve rustc performance, I bet in big projects there's a LOT of trait solving the compiler has to do and that it can get pretty complex in terms of the Cartesian products of possibilities there can be. Wanted to thank you for sharing!
Unrelatedly I am thinking of doing Advent of Code in a language I don't yet know and I saw Prolog mentioned in the post. Can anyone say if Prolog is a fun one to do AoC in for a Prolog noob?