Discovering discrepancies in numerical libraries
Jackson Vanover, Xuan Deng, Cindy Rubio-González
Abstract
Numerical libraries constitute the building blocks for software applications that perform numerical calculations. Thus, it is paramount that such libraries provide accurate and consistent results. To that end, this paper addresses the problem of finding discrepancies between synonymous functions in different numerical libraries as a means of identifying incorrect behavior. Our approach automatically finds such synonymous functions, synthesizes testing drivers, and executes differential tests to discover meaningful discrepancies across numerical libraries. We implement our approach in a tool named FPDiff, and provide an evaluation on four popular numerical libraries: GNU Scientific Library (GSL), SciPy, mpmath, and jmat. FPDiff finds a total of 126 equivalence classes with a 95.8% precision and 79.0% recall, and discovers 655 instances in which an input produces a set of disagreeing outputs between function synonyms, 150 of which we found to represent 125 unique bugs. We have reported all bugs to library maintainers; so far, 30 bugs have been fixed, 9 have been found to be previously known, and 25 more have been acknowledged by developers. CCS CONCEPTS • Software and its engineering → Software testing and debugging; Software reliability; Empirical software validation.
Ask about this paper
Your agent reads all of it.
Lune indexed this paper to the last equation, along with the top-tier papers that cite it. Ask a question and the answer quotes them.
Your agent calls
Luneget_paper_fulltext
Free to start. No credit card required.
Terminal
Install the CLIlune papers fulltext 87a813bb-a9cb-4aee-ab50-8cb5f1b9ea06Cited by top-tier papers7
- Fuzzing deep-learning libraries via automated relational API inferenceYinlin Deng, Chenyuan Yang, Anjiang Wei, Lingming ZhangFSE 2022 · 83 citations
- DocTer: documentation-guided fuzzing for testing deep learning API functionsDanning Xie, Yitong Li, Mijung Kim, Hung Viet Pham et al.ISSTA 2022 · 72 citations
- EAGLE: Creating Equivalent Graphs to Test Deep Learning LibrariesJiannan Wang, Thibaud Lutellier, Shangshu Qian, Hung Viet Pham et al.ICSE 2022 · 31 citations
- pLiner: isolating lines of floating-point code for compiler-induced variabilityHui Guo, Ignacio Laguna, Cindy Rubio-GonzálezSC 2020 · 15 citations
- Oracle-free repair synthesis for floating-point programsDaming Zou, Yuchen Gu, Yuanfeng Shi, Mingzhe Wang et al.OOPSLA 2022 · 9 citations
Related papers
- An Investigation on Numerical Bugs in GPU Programs Towards Automated Bug DetectionRavishka Rathnasuriya, Nidhi Majoju, Zihe Song, Wei YangISSTA 2025
- Mathematically-Guided Detection of Floating-Point ErrorsYoushuai Tan, Zhanwei Zhang, Haonan Zhang, Lianyu Zheng et al.ISSTA 2026
- Spying on the Floating Point Behavior of Existing, Unmodified Scientific ApplicationsPeter A. Dinda, Alex Bernat, Conor HetlandHPDC 2020 · 20 citations
- Fidelity of Cloud Emulators: The Imitation Game of Testing Cloud-Based SoftwareAnna Mazhar, Saad Sher Alam, William X. Zheng, Yinfang Chen et al.ICSE 2025 · 2 citations
- M3: Semantic API MigrationsBruce Collie, Philip Ginsbach, Jackson Woodruff, Ajitha Rajan et al.ASE 2020 · 14 citations
