P3: partitioned path profiling

Acyclic path profile is an abstraction of dynamic control flow paths of procedures and has been found to be useful in a wide spectrum of activities. Unfortunately, the runtime overhead of obtaining such a profile can be high, limiting its use in practice. In this paper, we present partitioned path profiling (P3) which runs K copies of the program in parallel, each with the same input but on a separate core, and collects the profile only for a subset of intra-procedural paths in each copy, thereby, distributing the overhead of profiling. P3 identifies “profitable” procedures and assigns disjoint subsets of paths of a profitable procedure to different copies for profiling. To obtain exact execution frequencies of a subset of paths, we design a new algorithm, called PSPP. All paths of an unprofitable procedure are assigned to the same copy. P3 uses the classic Ball-Larus algorithm for profiling unprofitable procedures. Further, P3 attempts to evenly distribute the profiling overhead across the copies. To the best of our knowledge, P3 is the first algorithm for parallel path profiling. We have applied P3 to profile several programs in the SPEC 2006 benchmark. Compared to sequential profiling, P3 substantially reduced the runtime overhead on these programs averaged across all benchmarks. The reduction was 23%, 43% and 56% on average for 2, 4 and 8 cores respectively. P3 also performed better than a coarse-grained approach that treats all procedures as unprofitable and distributes them across available cores. For 2 cores, the profiling overhead of P3 was on average 5% less compared to the coarse-grained approach across these programs. For 4 and 8 cores, it was respectively 18% and 25% less.

[1]  Michael D. Bond,et al.  Targeted path profiling: lower overhead path profiling for staged dynamic optimization systems , 2004, International Symposium on Code Generation and Optimization, 2004. CGO 2004..

[2]  Vikram S. Adve,et al.  LLVM: a compilation framework for lifelong program analysis & transformation , 2004, International Symposium on Code Generation and Optimization, 2004. CGO 2004..

[3]  Saumya K. Debray,et al.  Profile-guided code compression , 2002, PLDI '02.

[4]  Thomas W. Reps,et al.  Interprocedural Path Profiling , 1999, CC.

[5]  Klaudia Frankfurter Computers And Intractability A Guide To The Theory Of Np Completeness , 2016 .

[6]  Thomas Ball,et al.  Efficiently counting program events with support for on-line queries , 1994, TOPL.

[7]  Michal Young,et al.  Residual test coverage monitoring , 1999, Proceedings of the 1999 International Conference on Software Engineering (IEEE Cat. No.99CB37002).

[8]  William G. Griswold,et al.  Dynamically discovering likely program invariants to support program evolution , 1999, Proceedings of the 1999 International Conference on Software Engineering (IEEE Cat. No.99CB37002).

[9]  Camil Demetrescu,et al.  Ball-Larus path profiling across multiple loop iterations , 2013, OOPSLA.

[10]  Hareton K. N. Leung,et al.  Profiling selected paths with loops , 2014, Science China Information Sciences.

[11]  Trishul M. Chilimbi,et al.  Quantifying the effectiveness of testing via efficient residual path profiling , 2007, ESEC-FSE '07.

[12]  John T. Stasko,et al.  Visualization of test information to assist fault localization , 2002, ICSE '02.

[13]  James R. Larus,et al.  Efficient path profiling , 1996, Proceedings of the 29th Annual IEEE/ACM International Symposium on Microarchitecture. MICRO 29.

[14]  Trishul M. Chilimbi,et al.  HOLMES: Effective statistical debugging via efficient path profiling , 2009, 2009 IEEE 31st International Conference on Software Engineering.

[15]  Myra B. Cohen,et al.  Probe Distribution Techniques to Profile Events in Deployed Software , 2006, 2006 17th International Symposium on Software Reliability Engineering.

[16]  James R. Larus,et al.  Optimally profiling and tracing programs , 1994, TOPL.

[17]  John L. Henning SPEC CPU2006 benchmark descriptions , 2006, CARN.

[18]  Trishul M. Chilimbi,et al.  Preferential path profiling: compactly numbering interesting paths , 2007, POPL '07.

[19]  Michael D. Bond,et al.  Practical path profiling for dynamic optimizers , 2005, International Symposium on Code Generation and Optimization.

[20]  David S. Johnson,et al.  Computers and Intractability: A Guide to the Theory of NP-Completeness , 1978 .

[21]  Mary Jean Harrold,et al.  Selective path profiling , 2002, PASTE '02.

[22]  Subhajit Roy,et al.  Pertinent path profiling: Tracking interactions among relevant statements , 2013, Proceedings of the 2013 IEEE/ACM International Symposium on Code Generation and Optimization (CGO).

[23]  Pankaj Dhoolia,et al.  Distributed program tracing , 2013, ESEC/FSE 2013.

[24]  Alessandro Orso,et al.  Monitoring deployed software using software tomography , 2002, PASTE '02.

[25]  Ronald L. Graham,et al.  Bounds on Multiprocessing Timing Anomalies , 1969, SIAM Journal of Applied Mathematics.