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

Dynamic instrumentation of threaded applications

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

    The use of threads is becoming commonplace in both sequential and parallel programs. This paper describes our design and initial experience with non-trace based performance instrumentation techniques for threaded programs. Our goal is to provide detailed performance data while maintaining control of instrumentation costs. We have extended Paradyn's dynamic instrumentation (which can instrument programs without recompiling or relinking) to handle threaded programs.Controlling instrumentation costs means efficient instrumentation code and avoiding locks in the instrumentation. Our design is based on low contention data structures. To associate performance data with individual threads, we have all threads share the same instrumentation code and assign each thread with its own private copy of performance counters or timers. The asynchrony in a threaded program poses a major challenge to dynamic instrumentation. To implement time-based metrics on a per-thread basis, we need to instrument thread context switches, which can cause instrumentation code to interleave. Interleaved instrumentation can not only corrupt performance data, but can also cause a scenario we call self-deadlock where an instrumentation code deadlocks a thread. We introduce thread-conscious locks to avoid self-deadlock, and per-thread virtual CPU timers to reduce the chance of interleaved instrumentation accessing the same performance counter or timer, and to reduce the number of expensive timer calls at thread context switches.Our initial implementation is on SPARC Solaris 2.5 and 2.6 including multiprocessor Sun UltraSPARC Enterprise machines. We tested our tool on large multithreaded applications, including the Java Virtual Machine (JVM). We show how our new techniques helped us to speed up a Java graphics native method by 42% and consequently increase by 24% the amount of work that can be done in unit time in a game applet.

    References

    [1]
    Hollingsworth, j. K., Miller, B. P., Gon#alves, M. J. R., Naim, O., Xu, Z., and Zheng, L. MDL: A Language and Compiler for Dynamic Program Insmamentation. international Conference on Parallel Architectures and Compilation Techniques, San Francisco, CA. (Nov., 1997).
    [2]
    Ji, M., Felton, E. W., and Li, K. Performance Measurements for Multithreaded Programs.,4CM SiGME TRiCS/Pe#ormance, (i998).
    [3]
    Miller, B. P., Callaghan, M. D., Cargille, J. M., Hollingsworth, J. K., Irvin, R. B., Karavanie, K. L., Kunchithapadam, K., and Newhall, T. The Paradyn Parallel Performance L'#o)x wlcasur#mcm t ools. lr.#r_. #ompmer l l, (Nov., 1995).
    [4]
    Loukides, M. and Oram, A. Programming with GNU Software. O'Reilly & Associates, Inc. (Jan. 1997).
    [5]
    Ousterhout, J. Why Threads Are A Bad Idea (for most purposes). Invited talk at the 1996 USENIX Conference, (1996). Also available at http ://www.scdptics.com/people/j ohn.ousterhout/threads. #V.ya. #o#yL., A 7J#I.
    [6]
    Vahalla, U. UNIX Internals: The New Frontiers. Prentice Hall. (i 996), 48-80.
    [7]
    Voss, A. Instrumentation and Measurement of Muitithreaded Applications. Thesis. Institut fuer Mathematische Maschinen und Datenverarbeittmg,
    [8]
    Wu, P.-T., and Narayan, P. Multithreaded Performance Analysis with Sun WorkShopTM Thread Event Analyzer. Technical White Paper. (April, 1998), Revision 03.
    [9]
    Zhao, Q. A., and Stasko, J. T. Visuaiizmg the Execution of Threads-based Parallel Programs. Technical Report GIT- Gk#'.95-Ol, rapmcs, Visualization and Usability Georgia Institute of Technology, Atlanta, GA. (Jan., 1995).

    Cited By

    View all
    • (2012)Profiling divergences in GPU applicationsConcurrency and Computation: Practice and Experience10.1002/cpe.285325:6(775-789)Online publication date: 12-Jun-2012
    • (2010)Temporal vertical profilingSoftware—Practice & Experience10.5555/1840756.184075940:8(627-654)Online publication date: 1-Jul-2010
    • (2010)Performance Debugging of GPGPU Applications with the Divergence MapProceedings of the 2010 22nd International Symposium on Computer Architecture and High Performance Computing10.1109/SBAC-PAD.2010.38(33-40)Online publication date: 27-Oct-2010
    • Show More Cited By

    Recommendations

    Comments

    Information & Contributors

    Information

    Published In

    cover image ACM Conferences
    PPoPP '99: Proceedings of the seventh ACM SIGPLAN symposium on Principles and practice of parallel programming
    May 1999
    192 pages
    ISBN:1581131003
    DOI:10.1145/301104
    • Chairmen:
    • Marc Snir,
    • Andrew A. Chien
    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 1999

    Permissions

    Request permissions for this article.

    Check for updates

    Qualifiers

    • Article

    Conference

    PPoPP99
    Sponsor:

    Acceptance Rates

    PPoPP '99 Paper Acceptance Rate 17 of 79 submissions, 22%;
    Overall Acceptance Rate 230 of 1,014 submissions, 23%

    Contributors

    Other Metrics

    Bibliometrics & Citations

    Bibliometrics

    Article Metrics

    • Downloads (Last 12 months)52
    • Downloads (Last 6 weeks)11
    Reflects downloads up to 09 Aug 2024

    Other Metrics

    Citations

    Cited By

    View all
    • (2012)Profiling divergences in GPU applicationsConcurrency and Computation: Practice and Experience10.1002/cpe.285325:6(775-789)Online publication date: 12-Jun-2012
    • (2010)Temporal vertical profilingSoftware—Practice & Experience10.5555/1840756.184075940:8(627-654)Online publication date: 1-Jul-2010
    • (2010)Performance Debugging of GPGPU Applications with the Divergence MapProceedings of the 2010 22nd International Symposium on Computer Architecture and High Performance Computing10.1109/SBAC-PAD.2010.38(33-40)Online publication date: 27-Oct-2010
    • (2010)Temporal vertical profilingSoftware: Practice and Experience10.1002/spe.97240:8(627-654)Online publication date: 18-Jun-2010
    • (2008)Middleware Support for Performance Improvement of MABS Applications in the Grid EnvironmentMulti-Agent-Based Simulation VIII10.1007/978-3-540-70916-9_3(20-35)Online publication date: 1-Apr-2008
    • (2005)Automating vertical profilingACM SIGPLAN Notices10.1145/1103845.109483440:10(281-296)Online publication date: 12-Oct-2005
    • (2005)Automating vertical profilingProceedings of the 20th annual ACM SIGPLAN conference on Object-oriented programming, systems, languages, and applications10.1145/1094811.1094834(281-296)Online publication date: 17-Oct-2005
    • (2005)An efficient multi-level trace toolkit for multi-threaded applicationsProceedings of the 11th international Euro-Par conference on Parallel Processing10.1007/11549468_21(166-175)Online publication date: 30-Aug-2005
    • (2004)Using hardware performance monitors to understand the behavior of java applicationsProceedings of the 3rd conference on Virtual Machine Research And Technology Symposium - Volume 310.5555/1267242.1267247(5-5)Online publication date: 6-May-2004
    • (2004)Vertical profilingACM SIGPLAN Notices10.1145/1035292.102899839:10(251-269)Online publication date: 1-Oct-2004
    • 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