Procedure placement using temporal-ordering information: dealing with code size expansion

C. Guillon, F. Rastello, Thierry Bidault, Florent Bouchez
{"title":"Procedure placement using temporal-ordering information: dealing with code size expansion","authors":"C. Guillon, F. Rastello, Thierry Bidault, Florent Bouchez","doi":"10.1145/1023833.1023870","DOIUrl":null,"url":null,"abstract":"In a direct-mapped instruction cache, all instructions that have the same memory address modulo the cache size, share a common and unique cache slot. Instruction cache conflicts can be partially handled at linked time by procedure placement. Pettis and Hansen give in [1] an algorithm that reorders procedures in memory by aggregating them in a greedy fashion. The Gloy and Smith algorithm [2] greatly decreases the number of con ict-misses but increases the code size by allowing gaps between procedures. The latter contains two main stages: the cache-placement phase assigns modulo addresses to minimizes cache-conflicts; the memory-placement phase assigns final memory addresses under the modulo placement constraints, and minimizes the code size expansion. In this paper: (1) we state the NP-completeness of the cache-placement problem; (2) we provide an optimal algorithm to the memory-placement problem with complexity O(n min(n; L) log* (n)) (n is the number of procedures, L the cache size); (3) we take final program size into consideration during the cache-placement phase. Our modifications to the Gloy and Smith algorithm gives on average a code size expansion of 8% over the original program size, while the initial algorithm gave an expansion of 177%. The cache miss reduction is nearly the same as the Gloy and Smith solution with 35% cache miss reduction.","PeriodicalId":422048,"journal":{"name":"J. Embed. Comput.","volume":"60 1","pages":"0"},"PeriodicalIF":0.0000,"publicationDate":"2004-09-22","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"27","resultStr":null,"platform":"Semanticscholar","paperid":null,"PeriodicalName":"J. Embed. Comput.","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/10.1145/1023833.1023870","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
引用次数: 27

Abstract

In a direct-mapped instruction cache, all instructions that have the same memory address modulo the cache size, share a common and unique cache slot. Instruction cache conflicts can be partially handled at linked time by procedure placement. Pettis and Hansen give in [1] an algorithm that reorders procedures in memory by aggregating them in a greedy fashion. The Gloy and Smith algorithm [2] greatly decreases the number of con ict-misses but increases the code size by allowing gaps between procedures. The latter contains two main stages: the cache-placement phase assigns modulo addresses to minimizes cache-conflicts; the memory-placement phase assigns final memory addresses under the modulo placement constraints, and minimizes the code size expansion. In this paper: (1) we state the NP-completeness of the cache-placement problem; (2) we provide an optimal algorithm to the memory-placement problem with complexity O(n min(n; L) log* (n)) (n is the number of procedures, L the cache size); (3) we take final program size into consideration during the cache-placement phase. Our modifications to the Gloy and Smith algorithm gives on average a code size expansion of 8% over the original program size, while the initial algorithm gave an expansion of 177%. The cache miss reduction is nearly the same as the Gloy and Smith solution with 35% cache miss reduction.
使用临时排序信息的过程放置:处理代码大小的扩展
在直接映射的指令缓存中,所有具有相同内存地址的指令(对缓存大小取模)共享一个公共且唯一的缓存槽。指令缓存冲突可以通过过程放置在链接时部分处理。Pettis和Hansen在[1]中给出了一种算法,该算法通过贪婪的方式将程序聚合在一起,从而在内存中重新排序。Gloy和Smith算法[2]大大减少了冲突缺失的数量,但由于允许过程之间的间隔,增加了代码的大小。后者包含两个主要阶段:缓存放置阶段分配模地址以最小化缓存冲突;内存放置阶段在模放置约束下分配最终内存地址,并最小化代码大小扩展。本文:(1)给出了缓存放置问题的np完备性;(2)给出了复杂度为O(n) min(n)的内存放置问题的最优算法;L) log* (n)) (n为进程数,L为缓存大小);(3)在缓存放置阶段,我们将最终的程序大小考虑在内。我们对Gloy和Smith算法的修改使代码大小在原始程序大小的基础上平均扩展了8%,而初始算法的扩展幅度为177%。缓存丢失的减少几乎与Gloy和Smith的解决方案相同,缓存丢失减少了35%。
本文章由计算机程序翻译,如有差异,请以英文原文为准。
求助全文
约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学术文献互助群
群 号:604180095
Book学术官方微信