Affiliation:
1. University of Washington, USA
Abstract
Scientific and engineering applications depend on floating point arithmetic to approximate real arithmetic. This approximation introduces rounding error, which can accumulate to produce unacceptable results. While the numerical methods literature provides techniques to mitigate rounding error, applying these techniques requires manually rearranging expressions and understanding the finer details of floating point arithmetic. We introduce Herbie, a tool which automatically discovers the rewrites experts perform to improve accuracy. Herbie's heuristic search estimates and localizes rounding error using sampled points (rather than static error analysis), applies a database of rules to generate improvements, takes series expansions, and combines improvements for different input regions. We evaluated Herbie on examples from a classic numerical methods textbook, and found that Herbie was able to improve accuracy on each example, some by up to 60 bits, while imposing a median performance overhead of 40%. Colleagues in machine learning have used Herbie to significantly improve the results of a clustering algorithm, and a mathematical library has accepted two patches generated using Herbie.
Funder
National Science Foundation
Publisher
Association for Computing Machinery (ACM)
Subject
Computer Graphics and Computer-Aided Design,Software
Cited by
46 articles.
订阅此论文施引文献
订阅此论文施引文献,注册后可以免费订阅5篇论文的施引文献,订阅后可以查看论文全部施引文献
1. Combining Power and Arithmetic Optimization via Datapath Rewriting;2024 IEEE 31st Symposium on Computer Arithmetic (ARITH);2024-06-10
2. Input Range Generation for Compiler-Induced Numerical Inconsistencies;Proceedings of the 38th ACM International Conference on Supercomputing;2024-05-30
3. SEER: Super-Optimization Explorer for High-Level Synthesis using E-graph Rewriting;Proceedings of the 29th ACM International Conference on Architectural Support for Programming Languages and Operating Systems, Volume 2;2024-04-27
4. Transforming Optimization Problems into Disciplined Convex Programming Form;Lecture Notes in Computer Science;2024
5. Equality Saturation Theory Exploration à la Carte;Proceedings of the ACM on Programming Languages;2023-10-16