PAST: accurate instrumentation on fully optimized program
2015; Wiley; Volume: 46; Issue: 3 Linguagem: Inglês
10.1002/spe.2313
ISSN1097-024X
Autores Tópico(s)Software Engineering Research
ResumoSoftware: Practice and ExperienceVolume 46, Issue 3 p. 341-360 Research Article PAST: accurate instrumentation on fully optimized program Jie Yin, Corresponding Author Jie Yin Tsinghua University, Beijing, China Correspondence to: Jie Yin, West Main Building 1-417, Tsinghua University, Beijing 100084, China. E-mail: [email protected]Search for more papers by this authorChao Ma, Chao Ma Tsinghua University, Beijing, ChinaSearch for more papers by this authorShi-Min Hu, Shi-Min Hu Tsinghua University, Beijing, ChinaSearch for more papers by this author Jie Yin, Corresponding Author Jie Yin Tsinghua University, Beijing, China Correspondence to: Jie Yin, West Main Building 1-417, Tsinghua University, Beijing 100084, China. E-mail: [email protected]Search for more papers by this authorChao Ma, Chao Ma Tsinghua University, Beijing, ChinaSearch for more papers by this authorShi-Min Hu, Shi-Min Hu Tsinghua University, Beijing, ChinaSearch for more papers by this author First published: 16 January 2015 https://doi.org/10.1002/spe.2313Citations: 2Read the full textAboutPDF ToolsRequest permissionExport citationAdd to favoritesTrack citation ShareShare Give accessShare full text accessShare full-text accessPlease review our Terms and Conditions of Use and check box below to share full-text version of article.I have read and accept the Wiley Online Library Terms and Conditions of UseShareable LinkUse the link below to share a full-text version of this article with your friends and colleagues. Learn more.Copy URL Share a linkShare onEmailFacebookTwitterLinkedInRedditWechat Summary Instrumentation is a powerful technique for monitoring, profiling, debugging, logging and tracing the software. In order to determine the instrumentation location, the user needs to know where the current executed location is in the source code. Previous instrumentation approaches rely on debugging information to find the location in the source code. For fully optimized programs, debugging information is not complete, which limits the application of those approaches. In this paper, we present pattern-based abstract syntax tree (PAST) instrumentation, an ideal instrumentation methodology that accurately instruments the fully optimized program. The instrumentation location is specified in an intuitive way that matches the source code at the abstract syntax tree level. The program can be instrumented either at the compile time using the ordinary compiling or when it is running using the just-in-time compiling. Experimental results show that PAST can accurately instrument the target program. There is negligible run time overhead when the running program is instrumented without any operation. We have implemented PAST on both x86-32 and x86-64 to show that PAST is easily portable across different architecture. Copyright © 2015 John Wiley & Sons, Ltd. References 1Cantrill B, Shapiro M, Leventhal A. Dynamic instrumentation of production systems. In Proceedings of the Annual Conference on Usenix Annual Technical Conference. USENIX Association: Berkeley, CA, USA, 2004; 2–2. 2Bernat AR, Miller BP. Anywhere, any-time binary instrumentation. In Proceedings of the 10th ACM SIGPLAN-SIGSOFT Workshop on Program Analysis for Software Tools. ACM: New York, NY, USA, 2011; 9–16. 3Bruening D, Garnett T, Amarasinghe S. An infrastructure for adaptive dynamic optimization. In International Symposium on Code Generation and Optimization, 2003. CGO 2003. IEEE: New York, NY, USA, 2003; 265–275. 4Nethercote N, Seward J. Valgrind: a framework for heavyweight dynamic binary instrumentation. In ACM Sigplan Notices, Vol. 42. ACM: New York, NY, USA, 2007; 89–100. 5Aho A, Lam M, Sethi R, Ullman J. Compilers: Principles, Techniques, and Tools. Pearson/Addison Wesley: Boston, MA, USA, 2007. 6Lattner C. Clang: a c language family frontend for llvm, 2007. 7Lattner C, Adve V. LLVM: a compilation framework for lifelong program analysis & transformation. In International Symposium on Code Generation and Optimization, 2004. CGO 2004. IEEE: New York, NY, USA, 2004; 75–86. 8 Lighttped-bug, 2012. Available at: http://redmine.lighttpd.net/issues/2413 [last accessed 11 January 2015]. 9 lighttpd, 2003. Available at: http://en.wikipedia.org/wiki/lighttpd [last accessed 11 January 2015]. 10Klimek M. The Clang AST - a tutorial, 2013. 11 Apache-Httpd-Bug, 2013. Available at: https://issues.apache.org/bugzilla/show_bug.cgi?id=54881 [last accessed 11 January 2015]. 12Sager T, Bernstein A, Pinzger M, Kiefer C. Detecting similar Java classes using tree algorithms. In Proceedings of the 2006 International Workshop on Mining Software Repositories. ACM: New York, NY, USA, 2006; 65–71. 13Neamtiu I, Foster JS, Hicks M. Understanding source code evolution using abstract syntax tree matching. In ACM SIGSOFT SOFTWARE Engineering Notes, Vol. 30. ACM: New York, NY, USA, 2005; 1–5. 14Necula GC, McPeak S, Rahul SP, Weimer W. CIL: intermediate language and tools for analysis and transformation of C programs. In Compiler Construction. Springer: Berlin, German, 2002; 213–228. 15Erlingsson Ú, Peinado M, Peter S, Budiu M. Fay: extensible distributed tracing from kernels to clusters. In Proceedings of the Twenty-Third ACM Symposium on Operating Systems Principles. ACM: New York, NY, USA, 2011; 311–326. 16Hui K, Soules C, Wisniewski R, Da D, Orran S, Marc K, Edelsohn A, Gamsa B, Ganger G, P Mckenney, Ostrowski M, Rosenburg B, Stumm M, Xenidis J. Enabling autonomic system software with hot-swapping. In IBM Systems Journal. Citeseer: Armonk, NY, USA, 2003; 60–76. 17Prasad V, Cohen W, Eigler F, Hunt M, Keniston J, Chen B. Locating system problems using dynamic instrumentation. 2005 Ottawa Linux Symposium, Ottawa, Ontario, Canada, 2005; 49–64. 18Kiczales G, Hilsdale E, Hugunin J, Kersten M, Palm J, Griswold W. An overview of aspectJ. ECOOP 2001 Object-Oriented Programming, Budapest, Hungary, 2001; 327–354. 19Coady Y, Kiczales G, Feeley M, Smolyn G. Using aspectC to improve the modularity of path-specific customization in operating system code. ACM SIGSOFT Software Engineering Notes 2001; 26(5): 88–98. 20Cook J, Nusayr A. Using AOP for detailed runtime monitoring instrumentation. WODA 2008: The Sixth International Workshop on Dynamic Analysis, Seattle, Washington, USA, 2008; 8–14. 21Van Put L, Chanet D, De Bus B, De Sutter B, De Bosschere K. Diablo: a reliable, retargetable and extensible link-time rewriting framework. In Proceedings of the Fifth IEEE International Symposium on Signal Processing and Information Technology, 2005. IEEE: Athens, Greece, 2005; 7–12. 22Srivastava A, Eustace A. ATOM: A System for Building Customized Program Analysis Tools, Vol. 29. ACM: New York, NY, USA, 1994. 23Muth R, Debray SK, Watterson S, De Bosschere K. Alto: a link-time optimizer for the compaq alpha. Software: Practice and Experience 2001; 31(1): 67–101. 24Cohn R, Goodwin D, Lowney PG, Rubin N. Spike: an optimizer for alpha/NT executables. USENIX Windows NT Workshop, Seattle, Washington, USA, 1997; 17–24. 25Anand K, Smithson M, Elwazeer K, Kotha Aparna, Gruen J, Giles N, Barua R. A compiler-level intermediate representation based binary analysis and rewriting system. In Proceedings of the 8th ACM European Conference on Computer Systems. ACM: New York, NY, USA, 2013; 295–308. 26Olszewski M, Mierle K, Czajkowski A, Brown A. JIT instrumentation: a novel approach to dynamically instrument operating systems. ACM SIGOPS Operating Systems Review 2007; 41(3): 3–16. 27Luk C, Cohn R, Muth R, Patil H, Klauser A, Lowney G, Wallace S, Reddi V, K Hazelwood. PIN: building customized program analysis tools with dynamic instrumentation. In ACM Sigplan Notices, Vol. 40. ACM: New York, NY, USA, 2005; 190–200. Citing Literature Volume46, Issue3March 2016Pages 341-360 ReferencesRelatedInformation
Referência(s)