BLAS和LAPACK的建议一致异常处理
Proposed Consistent Exception Handling for the BLAS and LAPACK
摘要:
在许多情况下,可能由溢出、除0或sqrt(-1)等操作或收敛失败引起的数值异常是不可避免的,特别是当软件用于不可预见和困难的输入时。随着社会的更多方面变得自动化,例如,自动驾驶汽车、健康监测器和网络物理系统等越来越普遍的应用中,设计对异常具有弹性并以一致的方式响应异常的软件变得越来越重要。一致性是允许用户构建更高级别的软件所必需的,这些软件也是有弹性和一致的(递归地等等)。在本文中,我们探讨了广泛使用的BLAS和LAPACK线性代数库的一致异常处理的设计空间,指出了各种不一致的异常处理在当前版本的实例,并提出了一个新的设计,平衡一致性,复杂性,易用性和性能。需要做出一些妥协,因为存在预先存在的不一致性,这些不一致性超出了我们的控制范围,包括现有供应商BLAS实现中或之间、不同的程序设计语言,甚至是相同程序设计语言的编译器。我们调查中的用户请求非常多样化。我们也建议我们的设计作为其他数值软件的可能模式,并欢迎对我们的设计选择的意见。
英文摘要:
Numerical exceptions, which may be caused by overflow, operations like division by 0 or sqrt(-1), or convergence failures, are unavoidable in many cases, in particular when software is used on unforeseen and difficult inputs. As more aspects of society become automated, e.g., self-driving cars, health monitors, and cyber-physical systems more generally, it is becoming increasingly important to design software that is resilient to exceptions, and that responds to them in a consistent way. Consistency is needed to allow users to build higher-level software that is also resilient and consistent (and so on recursively). In this paper we explore the design space of consistent exception handling for the widely used BLAS and LAPACK linear algebra libraries, pointing out a variety of instances of inconsistent exception handling in the current versions, and propose a new design that balances consistency, complexity, ease of use, and performance. Some compromises are needed, because there are preexisting inconsistencies that are outside our control, including in or between existing vendor BLAS implementations, different programming languages, and even compilers for the same programming language. And user requests from our surveys are quite diverse. We also propose our design as a possible model for other numerical software, and welcome comments on our design choices.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。