An SSA-based Algorithm for Optimal Speculative Code Motion under an Execution Profile

被引:2
|
作者
Zhou, Hucheng [1 ]
Chen, Wenguang [1 ]
Chow, Fred
机构
[1] Tsinghua Univ, Beijing 100084, Peoples R China
关键词
Algorithms; Design; Experimentation; Measurement; Performance; Theory; Code motion; Flow network; Minimum cut; Partial redundancy elimination; Profiling; Speculation; Static single assignment;
D O I
10.1145/1993316.1993510
中图分类号
TP31 [计算机软件];
学科分类号
081202 ; 0835 ;
摘要
To derive maximum optimization benefits from partial redundancy elimination (PRE), it is necessary to go beyond its safety constraint. Algorithms for optimal speculative code motion have been developed based on the application of minimum cut to flow networks formed out of the control flow graph. These previous techniques did not take advantage of the SSA form, which is a popular program representation widely used in modern-day compilers. We have developed the MC-SSAPRE algorithm that enables an SSA-based compiler to take full advantage of SSA to perform optimal speculative code motion efficiently when an execution profile is available. Our work shows that it is possible to form flow networks out of SSA graphs, and the min-cut technique can be applied equally well on these flow networks to find the optimal code placement. We provide proofs of the correctness and computational and lifetime optimality of MC-SSAPRE. We analyze its time complexity to show its efficiency advantage. We have implemented MC-SSAPRE in the open-sourced Path64 compiler. Our experimental data based on the full SPEC CPU2006 Benchmark Suite show that MC-SSAPRE can further improve program performance over traditional SSAPRE, and that our sparse approach to the problem does result in smaller problem sizes.
引用
收藏
页码:98 / 108
页数:11
相关论文
共 50 条
  • [1] An SSA-based Algorithm for Optimal Speculative Code Motion under an Execution Profile
    Zhou, Hucheng
    Chen, Wenguang
    Chow, Fred
    PLDI 11: PROCEEDINGS OF THE 2011 ACM CONFERENCE ON PROGRAMMING LANGUAGE DESIGN AND IMPLEMENTATION, 2011, : 98 - 108
  • [2] Quantifying the Benefits of SSA-Based Mobile Code
    Amme, Wolfram
    von Ronne, Jeffery
    Franz, Michael
    ELECTRONIC NOTES IN THEORETICAL COMPUTER SCIENCE, 2005, 141 (02) : 103 - 119
  • [3] SSA-based mobile code: Implementation and empirical evaluation
    Amme, Wolfram
    Von Ronne, Jeffery
    Franz, Michael
    ACM TRANSACTIONS ON ARCHITECTURE AND CODE OPTIMIZATION, 2007, 4 (02) : 13
  • [4] An efficient SSA-based algorithm for complete global value numbering
    Nie, Jiu-Tao
    Cheng, Xu
    PROGRAMMING LANGUAGES AND SYSTEMS, PROCEEDINGS, 2007, 4807 : 319 - 334
  • [5] Optimal SSA-based wideband digital differentiator design for cardiac QRS complex detection application
    Nayak, Chandan
    Saha, Suman Kumar
    Kar, Rajib
    Mandal, Durbadal
    INTERNATIONAL JOURNAL OF NUMERICAL MODELLING-ELECTRONIC NETWORKS DEVICES AND FIELDS, 2019, 32 (02)
  • [6] A new thread-level speculative automatic parallelization model and library based on duplicate code execution
    Martinez, Millan A.
    Fraguela, Basilio B.
    Cabaleiro, Jose C.
    Rivera, Francisco F.
    JOURNAL OF SUPERCOMPUTING, 2024, 80 (10): : 13714 - 13737
  • [7] Optimal Algorithm for Profile-Based Power Gating: A Compiler Technique for Reducing Leakage on Execution Units in Microprocessors
    Park, Danbee
    Lee, Jungseob
    Kim, Nam Sung
    Kim, Taewhan
    2010 IEEE AND ACM INTERNATIONAL CONFERENCE ON COMPUTER-AIDED DESIGN (ICCAD), 2010, : 361 - 364
  • [8] OPTIMAL TRADE EXECUTION UNDER GEOMETRIC BROWNIAN MOTION IN THE ALMGREN AND CHRISS FRAMEWORK
    Gatheral, Jim
    Schied, Alexander
    INTERNATIONAL JOURNAL OF THEORETICAL AND APPLIED FINANCE, 2011, 14 (03) : 353 - 368
  • [9] Optimal design for MTI stagger code based on ant colony algorithm
    Chen, Xixin
    Han, Yanming
    Wang, Feng
    Dianbo Kexue Xuebao/Chinese Journal of Radio Science, 2012, 27 (06): : 1256 - 1260
  • [10] Intelligent prediction algorithm of ship roll and pitch motion based on SSA- optimized BiLSTM network
    Yuan, Peiyin
    Zhao, Wengui
    Zhao, Yu
    OCEAN ENGINEERING, 2025, 320