International Symposium on Code Generation and Optimization (CGO'04)
Extending Path Profiling across Loop Backedges and Procedure Boundaries
San Jose, California
March 20-March 24
ISBN: 0-7695-2102-9
Since their introduction, path profiles have been used to guide the application of aggressive code optimizations and performing instruction scheduling. However, for optimization and scheduling, it is often desirable to obtain frequency counts of paths that extend across loop iterations and cross procedure boundaries. These longer paths, referred to as interesting paths in this paper, account for over 75% of the flow in a subset of SPEC benchmarks. Although the frequency counts of interesting paths can be estimated from path profiles, the degree of imprecision of these estimates is very high. We extend Ball Larus (BL) paths to create slightly longer overlapping paths and develop an instrumentation algorithm to collect their frequencies. While these paths are slightly longer than BL paths, they enable very precise estimation of frequencies of potentially much longer interesting paths. Our experiments show that the average cost of collecting frequencies of overlapping paths is 86.8% which is 4.2 times that of BL paths. However, while the average imprecision in estimated total flow of interesting paths derived from BL path frequencies ranges from -38 % to +138 %, the average imprecision in flow estimates derived from overlapping path frequencies ranges only from -4% to +8%.
Index Terms:
path profiles, overlapping path profiles, profile guided optimization, and instruction scheduling
Citation:
Sriraman Tallam, Xiangyu Zhang, Rajiv Gupta, "Extending Path Profiling across Loop Backedges and Procedure Boundaries," cgo, pp.251, International Symposium on Code Generation and Optimization (CGO'04), 2004