首页> 外文会议>ACM SIGPLAN Conference on Programming Language Design and Implementation >Formal Verification of SSA-Based Optimizations for LLVM
【24h】

Formal Verification of SSA-Based Optimizations for LLVM

机译:基于SSA的SSA优化的正式验证LLVM

获取原文

摘要

Modern compilers, such as LLVM and GCC, use a static single assignment (SSA) intermediate representation (IR) to simplify and enable many advanced optimizations. However, formally verifying the correctness of SSA-based optimizations is challenging because SSA properties depend on a function's entire control-flow graph. This paper addresses this challenge by developing a proof technique for proving SSA-based program invariants and compiler optimizations. We use this technique in the Coq proof assistant to create mechanized correctness proofs of several "micro" transformations that form the building blocks for larger SSA optimizations. To demonstrate the utility of this approach, we formally verify a variant of LLVM's mem2reg transformation in Vellvm, a Coq-based formal semantics of the LLVM IR. The extracted implementation generates code with performance comparable to that of LLVM's unverified implementation.
机译:现代编译器(如LLVM和GCC)使用静态单分配(SSA)中间表示(IR)来简化和启用许多高级优化。但是,正式验证基于SSA的优化的正确性是具有挑战性的,因为SSA属性取决于函数的整个控制流程图。本文通过开发证明基于SSA的程序不变和编译器优化的证明技术来解决这一挑战。我们在COQ验证助理中使用此技术,以创建机械化正确性的几个“Micro”转换,从而为更大的SSA优化形成构建块。为了证明这种方法的效用,我们正式验证VELLVM中LLVM的MEM2REG转化的变体,LLVM IR的COQ的正式语义。提取的实现生成代码,性能与LLVM的未经验证的实现相当。

著录项

相似文献

  • 外文文献
  • 中文文献
  • 专利
获取原文

客服邮箱:kefu@zhangqiaokeyan.com

京公网安备:11010802029741号 ICP备案号:京ICP备15016152号-6 六维联合信息科技 (北京) 有限公司©版权所有
  • 客服微信

  • 服务号