Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
skip to main content
10.1145/258915.258924acmconferencesArticle/Chapter ViewAbstractPublication PagespldiConference Proceedingsconference-collections
Article
Free access

Exploiting hardware performance counters with flow and context sensitive profiling

Published: 01 May 1997 Publication History
  • Get Citation Alerts
  • Abstract

    A program profile attributes run-time costs to portions of a program's execution. Most profiling systems suffer from two major deficiencies: first, they only apportion simple metrics, such as execution frequency or elapsed time to static, syntactic units, such as procedures or statements; second, they aggressively reduce the volume of information collected and reported, although aggregation can hide striking differences in program behavior.This paper addresses both concerns by exploiting the hardware counters available in most modern processors and by incorporating two concepts from data flow analysis--flow and context sensitivity--to report more context for measurements. This paper extends our previous work on efficient path profiling to flow sensitive profiling, which associates hardware performance metrics with a path through a procedure. In addition, it describes a data structure, the calling context tree, that efficiently captures calling contexts for procedure-level measurements.Our measurements show that the SPEC95 benchmarks execute a small number (3--28) of hot paths that account for 9--98% of their L1 data cache misses. Moreover, these hot paths are concentrated in a few routines, which have complex dynamic behavior.

    References

    [1]
    Thomas Ball. Efficiently counting program events with support for on-line queries. A CM Transactions on Programming Languages and Systems, 16(5):1399-1410, September 1994.
    [2]
    Jim Bennett (PureAtria, Inc.). Personal communication, November 1996.
    [3]
    R. Bodik, R. Gupta, and M. L. Sofia. interprocedural conditional branch elimination. In Proceedings of the SIG- PLAN '97 Conference on Programming Language Design and Implementation, June 1997.
    [4]
    T. Ball and J. R. Larus. Optimally profiling and tracing programs. A CM Transactions on Programming Languages and Systems, 16(3):1319-1360, July 1994.
    [5]
    T. Ball and J. R. Larus. Efficient path profiling, in Pro. ceedings of MICRO 96, pages 46-57, December 1996.
    [6]
    P. P. Chang, S. A. Mahlke, and W-M. W. Hwu. Using profile information to assist classic code optimiza~ lions. Software-Practice and Experience, 21(12):1301- 1321, December 1991.
    [7]
    S.L. Graham, P. B. Kessler, and M. K. McKusick. An execution profiler for modular programs. Software-Practice and Experience, 13:671-685, 1983.
    [8]
    R.J. Hall. Call path profiling. In Proceedings of the J.tth International Conference on Software Engineering (iCSE92), pages 296-306, 1992.
    [9]
    R.J. Hall and A. J. Goldberg. Call path profiling of monotonic program resources in UNIX. In Proceedings of the USENIX Summer 1993 Technical Conference, pages 1- 14., Cincinnati, OH, 1993.
    [10]
    D.F. Jerding, J. T. Stasko, and T. Ball. Visualizing interactions in program executions. In Proceedings of 1997 International Conference on Software Engineering (to appear), May 1997.
    [11]
    D.E. Knuth. An empirical study of FORTH, AN programs. Software-Practice and Experience, 1(2):I05-133, June 1971.
    [12]
    James R. Larus and Eric Schnarr. EEL: Machineindependent executable editing. In Proceedings of the SIGPLAN '95 Conference on Programming Language Design and Implementation (PLDI), pages 291-300, June 1995.
    [13]
    Alvin R. Lebeck and David A. Wood. Cache profiling and the spec benchmarks: A case study. IEEE Computer, 27(10):15-26, October 1994.
    [14]
    E. Morel and C. Renvoise. lnterprocedural elimination of partial redundancies. In S.S. Muchnick and N.D. Jones, editors, Program Flow Analysis: Theory and Applica. lions. Prentice-Hall, Englewood Cliffs, N J, 1981.
    [15]
    Allen D. Malony, Daniel A. Reed, and Harry A. G. Wijshoff. Performance measurement instrusion and perturbation analysis. IEEE Transactions on Parallel and Distributed Systems, 3(4):433-450, July 1992.
    [16]
    F. Mueller and D. B. Whalley. Avoiding conditional branches by code replication. In Proceedings of the SIG- PLAN '95 Conference on Programming Language Design and implementation, pages 56-66, June 1995.
    [17]
    C. Ponder and R. J. Fateman. Inaccuracies in program profilers. Software-Practice and Experience, 18:459-467, May 1988.
    [18]
    T. Reps, T. Ball, M. Das, and J. R. Larus. The use of program profiling for software maintenance with applica~ tions to the year 2000 problem. In Technical Report 1335, Computer Sciences Department, University of Wiscon. sin, Madison, WI, January 1997.
    [19]
    Pure Software. Quantify User's Guide. 1993.
    [20]
    Micha Sharir and Amir Pnueli. Two approaches to interprocedural data flow analysis. In Steven S. Muchnick and Nell D. Jones, editors, Program Flow Analysis: Theory and Applications, pages 189-233. Prentice-Hall, 198I.
    [21]
    Sun Microelectronics. UltraSPARC User's Manual, 1996.
    [22]
    M. R. Woodward, D. Hedley, and M. A. Hennell. Experience with path analysis and testing of programs. IEEE Transactions on Software Engineering, 6(3):278- 286, May 1980.

    Cited By

    View all
    • (2024)FlowProf: Profiling Multi-threaded Programs using Information-FlowProceedings of the 33rd ACM SIGPLAN International Conference on Compiler Construction10.1145/3640537.3641577(137-149)Online publication date: 17-Feb-2024
    • (2023)On the feasibility of malware unpacking via hardware-assisted loop profilingProceedings of the 32nd USENIX Conference on Security Symposium10.5555/3620237.3620656(7481-7498)Online publication date: 9-Aug-2023
    • (2023)Optimization-Aware Compiler-Level Event ProfilingACM Transactions on Programming Languages and Systems10.1145/3591473Online publication date: 10-Apr-2023
    • Show More Cited By

    Recommendations

    Comments

    Information & Contributors

    Information

    Published In

    cover image ACM Conferences
    PLDI '97: Proceedings of the ACM SIGPLAN 1997 conference on Programming language design and implementation
    May 1997
    365 pages
    ISBN:0897919076
    DOI:10.1145/258915
    Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than ACM must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected]

    Sponsors

    Publisher

    Association for Computing Machinery

    New York, NY, United States

    Publication History

    Published: 01 May 1997

    Permissions

    Request permissions for this article.

    Check for updates

    Qualifiers

    • Article

    Conference

    PLDI97
    Sponsor:
    PLDI97: Conference on Programming Language
    June 16 - 18, 1997
    Nevada, Las Vegas, USA

    Acceptance Rates

    PLDI '97 Paper Acceptance Rate 31 of 158 submissions, 20%;
    Overall Acceptance Rate 406 of 2,067 submissions, 20%

    Contributors

    Other Metrics

    Bibliometrics & Citations

    Bibliometrics

    Article Metrics

    • Downloads (Last 12 months)184
    • Downloads (Last 6 weeks)22

    Other Metrics

    Citations

    Cited By

    View all
    • (2024)FlowProf: Profiling Multi-threaded Programs using Information-FlowProceedings of the 33rd ACM SIGPLAN International Conference on Compiler Construction10.1145/3640537.3641577(137-149)Online publication date: 17-Feb-2024
    • (2023)On the feasibility of malware unpacking via hardware-assisted loop profilingProceedings of the 32nd USENIX Conference on Security Symposium10.5555/3620237.3620656(7481-7498)Online publication date: 9-Aug-2023
    • (2023)Optimization-Aware Compiler-Level Event ProfilingACM Transactions on Programming Languages and Systems10.1145/3591473Online publication date: 10-Apr-2023
    • (2023)Leveraging Hardware Performance Counters for Efficient Classification of Binary Packers2023 IEEE 22nd International Conference on Trust, Security and Privacy in Computing and Communications (TrustCom)10.1109/TrustCom60117.2023.00252(1859-1864)Online publication date: 1-Nov-2023
    • (2022)EdgeTuneProceedings of the 23rd ACM/IFIP International Middleware Conference10.1145/3528535.3533273(1-14)Online publication date: 7-Nov-2022
    • (2022)Physical Attack Protection Techniques for IC Chip Level Hardware SecurityIEEE Transactions on Very Large Scale Integration (VLSI) Systems10.1109/TVLSI.2021.307394630:1(5-14)Online publication date: Jan-2022
    • (2022)T-SYS: Timed-Based System Security for Real-Time Kernels2022 ACM/IEEE 13th International Conference on Cyber-Physical Systems (ICCPS)10.1109/ICCPS54341.2022.00029(247-258)Online publication date: May-2022
    • (2021)JPortal: precise and efficient control-flow tracing for JVM programs with Intel processor traceProceedings of the 42nd ACM SIGPLAN International Conference on Programming Language Design and Implementation10.1145/3453483.3454096(1080-1094)Online publication date: 19-Jun-2021
    • (2021)GRAPHSPY: Fused Program Semantic Embedding through Graph Neural Networks for Memory Efficiency2021 58th ACM/IEEE Design Automation Conference (DAC)10.1109/DAC18074.2021.9586120(1045-1050)Online publication date: 5-Dec-2021
    • (2020)DrCCTProfProceedings of the International Conference for High Performance Computing, Networking, Storage and Analysis10.5555/3433701.3433740(1-16)Online publication date: 9-Nov-2020
    • Show More Cited By

    View Options

    View options

    PDF

    View or Download as a PDF file.

    PDF

    eReader

    View online with eReader.

    eReader

    Get Access

    Login options

    Media

    Figures

    Other

    Tables

    Share

    Share

    Share this Publication link

    Share on social media