skip to main content
article

Pin++: an object-oriented framework for writing pintools

Published:15 September 2014Publication History
Skip Abstract Section

Abstract

This paper presents a framework named Pin++. Pin++ is an object-oriented framework that uses template metaprogramming to implement Pintools, which are analysis tools for the dynamic binary instrumentation tool named Pin. The goal of Pin++ is to simplify programming a Pintool and promote reuse of its components across different Pintools. Our results show that Pintools implemented using Pin++ can have a 54% reduction in complexity, increase its modularity, and up to 60% reduction in instrumentation overhead.

References

  1. C.-K. Luk, R. Cohn, R. Muth, H. Patil, A. Klauser, G. Lowney, S. Wallace, V. J. Reddi, and K. Hazelwood, “Pin: Building Customized Program Analysis Tools with Dynamic Instrumentation,” SIGPLAN Notes, vol. 40, pp. 190–200, June 2005. Google ScholarGoogle ScholarDigital LibraryDigital Library
  2. K. Hazelwood, “Dynamic binary modification: Tools, techniques, and applications,” Synthesis Lectures on Computer Architecture, vol. 6, no. 2, pp. 1–81, 2011. Google ScholarGoogle ScholarDigital LibraryDigital Library
  3. H. Patil, C. Pereira, M. Stallcup, G. Lueck, and J. Cownie, “Pinplay: a framework for deterministic replay and reproducible analysis of parallel programs,” in Proceedings of the 8th annual IEEE/ACM international symposium on Code generation and optimization. ACM, 2010, pp. 2–11. Google ScholarGoogle ScholarDigital LibraryDigital Library
  4. A. Jaleel, R. S. Cohn, C.-K. Luk, and B. Jacob, “Cmp$im: A pinbased on-the-fly multi-core cache simulator,” in Proceedings of the Fourth Annual Workshop on Modeling, Benchmarking and Simulation (MoBS), co-located with ISCA, 2008, pp. 28–36.Google ScholarGoogle Scholar
  5. M. Bach, M. Charney, R. Cohn, E. Demikhovsky, T. Devor, K. Hazelwood, A. Jaleel, C.-K. Luk, G. Lyons, H. Patil et al., “Analyzing parallel programs with pin,” Computer, vol. 43, no. 3, pp. 34–41, 2010. Google ScholarGoogle ScholarDigital LibraryDigital Library
  6. M. Attariyan, M. Chow, and J. Flinn, “X-ray: automating root-cause diagnosis of performance anomalies in production software,” in Proceedings of the 10th USENIX conference on Operating Systems Design and Implementation. USENIX Association, 2012, pp. 307–320. Google ScholarGoogle ScholarDigital LibraryDigital Library
  7. D. Bruening, T. Garnett, and S. Amarasinghe, “An Infrastructure for Adaptive Dynamic Optimization,” in Code Generation and Optimization, 2003. CGO 2003. International Symposium on. IEEE, 2003, pp. 265–275. Google ScholarGoogle ScholarDigital LibraryDigital Library
  8. B. Buck and J. K. Hollingsworth, “An API for Runtime Code Patching,” International Journal of High Performance Computing Applications, vol. 14, no. 4, pp. 317–329, 2000. Google ScholarGoogle ScholarDigital LibraryDigital Library
  9. B. M. Cantrill, M. W. Shapiro, and A. H. Leventhal, “Dynamic Instrumentation of Production Systems,” in 6th Symposium on Operating Systems Design and Implementation, 2004, pp. 15–28. Google ScholarGoogle ScholarDigital LibraryDigital Library
  10. N. Nethercote and J. Seward, “Valgrind: a framework for heavyweight dynamic binary instrumentation,” ACM Sigplan Notices, vol. 42, no. 6, pp. 89–100, 2007. Google ScholarGoogle ScholarDigital LibraryDigital Library
  11. Intel, “Pin Manual,” http://software.intel.com/sites/landingpage/ pintool/docs/61206/Pin/html.Google ScholarGoogle Scholar
  12. R. C. Martin, “Design Principles and Design Patterns,” Object Mentor, pp. 1–34, 2000. 1 Details about these feature can be found in the Pin++ Github repository, and on its wiki (github.com/SEDS/PinPP/wiki).Google ScholarGoogle Scholar
  13. T. McCabe, “A Complexity Measure,” IEEE Transactions on Software Engineering, vol. SE-2, no. 4, pp. 308–320, December 1976. Google ScholarGoogle ScholarDigital LibraryDigital Library
  14. T. Hemmann, “Reuse Approaches in Software Engineering and Knowledge Engineering: A Comparison,” in Position Paper Collection of the 2nd Int. Workshop on Software Reusability, no. 93-69, 1993.Google ScholarGoogle Scholar
  15. K. Czarnecki and U. W. Eisenecker, “Components and Generative Programming,” in Software Engineering–ESEC/FSE ’99. Springer, 1999, pp. 2–19. Google ScholarGoogle ScholarDigital LibraryDigital Library
  16. E. Gamma, R. Helm, R. Johnson, and J. Vlissides, Design Patterns: Elements of Reusable Object-Oriented Software. Reading, MA: Addison-Wesley, 1995. Google ScholarGoogle ScholarDigital LibraryDigital Library
  17. K. Czarnecki and U. Eisenecker, Generative Programming: Methods, Tools, and Applications. Addison-Wesley Professional, 2000. Google ScholarGoogle ScholarDigital LibraryDigital Library
  18. D. Abrahams and A. Gurtovoy, C++ template metaprogramming: Concepts, tools, and techniques from boost and beyond. Addison-Wesley Professional, 2004. Google ScholarGoogle ScholarDigital LibraryDigital Library
  19. R. C. Martin, Clean Code: A Handbook of Agile Software Craftsmanship. Prentice Hall, 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  20. W. H. Brown, R. C. Malveau, and T. J. Mowbray, AntiPatterns: Refactoring Software, Architectures, and Projects in Crisis. New York, NY: Wiley, 1998. Google ScholarGoogle ScholarDigital LibraryDigital Library
  21. J. O. Coplien, “Curiously recurring template patterns,” C++ Report, vol. 7, no. 2, pp. 24–27, 1995. Google ScholarGoogle ScholarDigital LibraryDigital Library
  22. R. E. Schantz and D. C. Schmidt, “Middleware for distributed systems - evolving the common structure for network-centric applications,” 2001.Google ScholarGoogle Scholar
  23. J. de Guzman, “Boost.Spirit,” http://boost-spirit.com.Google ScholarGoogle Scholar
  24. ISO/IEC, “Summary of the ISO EBNF Notation,” www.dataip.co.uk/ Reference/EBNF.php.Google ScholarGoogle Scholar
  25. S. D. Huston, J. C. E. Johnson, and U. Syyid, The ACE Programmer’s Guide. Boston: Addison-Wesley, 2002.Google ScholarGoogle Scholar
  26. WikiBooks, “More C++ Idioms,” http://en.wikibooks.org/wiki/More C%2B%2B Idioms/Scope Guard.Google ScholarGoogle Scholar

Index Terms

  1. Pin++: an object-oriented framework for writing pintools

      Recommendations

      Comments

      Login options

      Check if you have access through your login credentials or your institution to get full access on this article.

      Sign in

      Full Access

      • Published in

        cover image ACM SIGPLAN Notices
        ACM SIGPLAN Notices  Volume 50, Issue 3
        GPCE '14
        March 2015
        141 pages
        ISSN:0362-1340
        EISSN:1558-1160
        DOI:10.1145/2775053
        • Editor:
        • Andy Gill
        Issue’s Table of Contents
        • cover image ACM Conferences
          GPCE 2014: Proceedings of the 2014 International Conference on Generative Programming: Concepts and Experiences
          September 2014
          141 pages
          ISBN:9781450331616
          DOI:10.1145/2658761

        Copyright © 2014 ACM

        Publisher

        Association for Computing Machinery

        New York, NY, United States

        Publication History

        • Published: 15 September 2014

        Check for updates

        Qualifiers

        • article

      PDF Format

      View or Download as a PDF file.

      PDF

      eReader

      View online with eReader.

      eReader
      About Cookies On This Site

      We use cookies to ensure that we give you the best experience on our website.

      Learn more

      Got it!