Loop Quasi-Invariant Chunk Motion by peeling with statement composition

Jean-Yves Moyen, Thomas Rubiano, T. Seiller
{"title":"Loop Quasi-Invariant Chunk Motion by peeling with statement composition","authors":"Jean-Yves Moyen, Thomas Rubiano, T. Seiller","doi":"10.4204/EPTCS.248.9","DOIUrl":null,"url":null,"abstract":"Several techniques for analysis and transformations are used in compilers. Among them, the peeling of loops for hoisting quasi-invariants can be used to optimize generated code, or simply ease developers' lives. In this paper, we introduce a new concept of dependency analysis borrowed from the field of Implicit Computational Complexity (ICC), allowing to work with composed statements called Chunks to detect more quasi-invariants. Based on an optimization idea given on a WHILE language, we provide a transformation method - reusing ICC concepts and techniques - to compilers. This new analysis computes an invariance degree for each statement or chunks of statements by building a new kind of dependency graph, finds the maximum or worst dependency graph for loops, and recognizes if an entire block is Quasi-Invariant or not. This block could be an inner loop, and in that case the computational complexity of the overall program can be decreased. We already implemented a proof of concept on a toy C parser 1 analysing and transforming the AST representation. In this paper, we introduce the theory around this concept and present a prototype analysis pass implemented on LLVM. In a very near future, we will implement the corresponding transformation and provide benchmarks comparisons.","PeriodicalId":196864,"journal":{"name":"DICE-FOPARA@ETAPS","volume":"56 14 1","pages":"0"},"PeriodicalIF":0.0000,"publicationDate":"2017-04-19","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"5","resultStr":null,"platform":"Semanticscholar","paperid":null,"PeriodicalName":"DICE-FOPARA@ETAPS","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/10.4204/EPTCS.248.9","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
引用次数: 5

Abstract

Several techniques for analysis and transformations are used in compilers. Among them, the peeling of loops for hoisting quasi-invariants can be used to optimize generated code, or simply ease developers' lives. In this paper, we introduce a new concept of dependency analysis borrowed from the field of Implicit Computational Complexity (ICC), allowing to work with composed statements called Chunks to detect more quasi-invariants. Based on an optimization idea given on a WHILE language, we provide a transformation method - reusing ICC concepts and techniques - to compilers. This new analysis computes an invariance degree for each statement or chunks of statements by building a new kind of dependency graph, finds the maximum or worst dependency graph for loops, and recognizes if an entire block is Quasi-Invariant or not. This block could be an inner loop, and in that case the computational complexity of the overall program can be decreased. We already implemented a proof of concept on a toy C parser 1 analysing and transforming the AST representation. In this paper, we introduce the theory around this concept and present a prototype analysis pass implemented on LLVM. In a very near future, we will implement the corresponding transformation and provide benchmarks comparisons.
通过语句组合剥离循环准不变块运动
编译器中使用了几种分析和转换技术。其中,剥离提升准不变量的循环可以用来优化生成的代码,或者简单地简化开发人员的工作。在本文中,我们引入了从隐式计算复杂性(ICC)领域借鉴的依赖分析的新概念,允许使用称为chunk的组合语句来检测更多的准不变量。基于WHILE语言的优化思想,我们为编译器提供了一种转换方法——重用ICC的概念和技术。这种新的分析方法通过构建一种新的依赖图来计算每个语句或语句块的不变性程度,找到循环的最大依赖图或最差依赖图,并识别整个块是否为准不变性。这个块可以是一个内循环,在这种情况下,整个程序的计算复杂性可以降低。我们已经在一个简单的C解析器1上实现了概念验证,该解析器分析并转换AST表示。在本文中,我们围绕这一概念介绍了理论,并提出了一个在LLVM上实现的原型分析通道。在不久的将来,我们将实现相应的转换并提供基准比较。
本文章由计算机程序翻译,如有差异,请以英文原文为准。
求助全文
约1分钟内获得全文 求助全文
来源期刊
自引率
0.00%
发文量
0
×
引用
GB/T 7714-2015
复制
MLA
复制
APA
复制
导出至
BibTeX EndNote RefMan NoteFirst NoteExpress
×
提示
您的信息不完整,为了账户安全,请先补充。
现在去补充
×
提示
您因"违规操作"
具体请查看互助需知
我知道了
×
提示
确定
请完成安全验证×
copy
已复制链接
快去分享给好友吧!
我知道了
右上角分享
点击右上角分享
0
联系我们:info@booksci.cn Book学术提供免费学术资源搜索服务,方便国内外学者检索中英文文献。致力于提供最便捷和优质的服务体验。 Copyright © 2023 布克学术 All rights reserved.
京ICP备2023020795号-1
ghs 京公网安备 11010802042870号
Book学术文献互助
Book学术文献互助群
群 号:481959085
Book学术官方微信