3 ms·
Using fuel to enable a binary search to uncover misapplied optimizations is very clever! I always just figured that fuel was used to avoid pathological behavior
by kibwen 10y ago
Using fuel to enable a binary search to uncover misapplied optimizations is very clever! I always just figured that fuel was used to avoid pathological behavior in the optimizer by putting an upper bound on the time spent optimizing.
- CAMLORN 10y agoThe first time I think I saw the idea was [0], but I don't know if this is the post that got linked in the discussion threads. Rust didn't have fuel at all until after my changes, and I don't think it's necessary to use it as a limit unless you're letting the optimizer run on the optimizer's output until it stops changing. The number of optimizations Rustc can run is already finite because it doesn't do so. nonetheless, the idea isn't original to us. 0: http://blog.ezyang.com/2011/06/debugging-compilers-with-optimization-fuel/ http://blog.ezyang.com/2011/06/debugging-compilers-with-opti...