skip to main content
10.1145/1640089.1640112acmconferencesArticle/Chapter ViewAbstractPublication PagessplashConference Proceedingsconference-collections
research-article

Enhancing source-level programming tools with an awareness of transparent program transformations

Published:25 October 2009Publication History

ABSTRACT

Programs written in managed languages are compiled to a platform-independent intermediate representation, such as Java bytecode. The relative high level of Java bytecode has engendered a widespread practice of changing the bytecode directly, without modifying the maintained version of the source code. This practice, called bytecode engineering or enhancement, has become indispensable in introducing various concerns, including persistence, distribution, and security, transparently. For example, transparent persistence architectures help avoid the entanglement of business and persistence logic in the source code by changing the bytecode directly to synchronize objects with stable storage. With functionality added directly at the bytecode level, the source code reflects only partial semantics of the program. Specifically, the programmer can neither ascertain the program's runtime behavior by browsing its source code, nor map the runtime behavior back to the original source code.

This paper presents an approach that improves the utility of source-level programming tools by providing enhancement specifications written in a domain-specific language. By interpreting the specifications, a source-level programming tool can gain an awareness of the bytecode enhancements and improve its precision and usability. We demonstrate the applicability of our approach by making a source code editor and a symbolic debugger enhancements-aware.

References

  1. C. Andreae, J. Noble, S. Markstrum, and T. Millstein. A framework for implementing pluggable type systems. SIGPLAN Not., 41(10):57--74, 2006. Google ScholarGoogle Scholar
  2. Apache Jakarta Project. The Byte Code Engineering Library. http://jakarta.apache.org/bcel/manual.html.Google ScholarGoogle Scholar
  3. T. Apiwattanapong, A. Orso, and M. Harrold. A differencing algorithm for object-oriented programs. Automated Software Engineering, 2004. Proceedings. 19th International Conference on, pages 2--13, Sept. 2004. Google ScholarGoogle Scholar
  4. M. P. Atkinson. The Napier88 persistent programming language and environment, 1988.Google ScholarGoogle Scholar
  5. M. P. Atkinson, L. Daynes, M. J. Jordan, T. Printezis, and S. Spence. An orthogonally persistent java. SIGMOD Rec., 25(4):68--75, 1996. Google ScholarGoogle Scholar
  6. C. Bauer, G. King, and I. NetLibrary. Hibernate in Action. Manning, 2005. Google ScholarGoogle Scholar
  7. G. Brooks, G. J. Hansen, and S. Simmons. A new approach to debugging optimized code. In PLDI '92: Proceedings of the ACM SIGPLAN 1992 conference on Programming language design and Implementation, pages 1--11, 1992. Google ScholarGoogle Scholar
  8. T. M. Chilimbi, B. Davidson, and J. R. Larus. Cacheconscious structure definition. SIGPLAN Not., 34(5):13--24, 1999. Google ScholarGoogle Scholar
  9. M. Copperman. Debugging optimized code without being misled. ACM Trans. Program. Lang. Syst., 16(3):387--427, 1994. Google ScholarGoogle Scholar
  10. K. Czarnecki. Framework-specific modeling languages with round-trip engineering. In In MoDELS, pages 692--706, 2006. Google ScholarGoogle Scholar
  11. M. Dahm. Byte code engineering. Java Informations Tage, pages 267--277, 1999.Google ScholarGoogle Scholar
  12. M. Dmitriev. Language-specific make technology for the Java programming language. SIGPLAN Not., 37(11):373--385, 2002. Google ScholarGoogle Scholar
  13. B. Dufour, B. G. Ryder, and G. Sevitsky. Blended analysis for performance understanding of framework-based applications. In ISSTA '07: Proceedings of the 2007 international symposium on Software testing and analysis, pages 118--128, New York, NY, USA, 2007. ACM. Google ScholarGoogle Scholar
  14. M. Eaddy, A. Aho, W. Hu, P. McDonald, and J. Burger. Debugging aspect-enabled programs. In Software Composition, pages 200--215. 2007. Google ScholarGoogle Scholar
  15. Eclipse Foundation. Eclipse Java development tools, March 2008. http://www.eclipse.org/jdtGoogle ScholarGoogle Scholar
  16. M. Fahndrich, M. Carbin, and J. R. Larus. Reflective program generation with patterns. In GPCE '06: Proceedings of the 5th international conference on Generative programming and component engineering, pages 275--284, New York, NY, USA, 2006. ACM. Google ScholarGoogle Scholar
  17. R. E. Faith. Debugging programs after structure-changing transformation. PhD thesis, 1998. Adviser-Jan F. Prins. Google ScholarGoogle Scholar
  18. J. Flen and A. Linden. Gartners hype cycle special report. Technical report, Gartner Research, 2005. www.gartner.com.Google ScholarGoogle Scholar
  19. P. Fritzson. A systematic approach to advanced debugging through incremental compilation (preliminary draft). In Proceedings of the ACM SIGSOFT/SIGPLAN software engineering symposium on High-level debugging, pages 130--139, 1983. Google ScholarGoogle Scholar
  20. Glen McCluskey. Using Java Reflection. http://java.sun.com/developer/technicalArticles/ALT/Reflection/index.html.Google ScholarGoogle Scholar
  21. J. Hennessy. Symbolic debugging of optimized code. ACM Trans. Program. Lang. Syst., 4(3):323--344, 1982. Google ScholarGoogle Scholar
  22. U. Holzle, C. Chambers, and D. Ungar. Debugging optimized code with dynamic deoptimization. SIGPLAN Not., 27(7):32--43, 1992. Google ScholarGoogle Scholar
  23. T. Ishio, S. Kusumoto, and K. Inoue. Debugging support for aspect-oriented program based on program slicing and call graph. In ICSM '04: Proceedings of the 20th IEEE International Conference on Software Maintenance, pages 178--187, 2004. Google ScholarGoogle Scholar
  24. G. Kiczales, E. Hilsdale, J. Hugunin, M. Kersten, J. Palm, and W. G. Griswold. An overview of AspectJ. In Proceedings of the 15th European Conference on Object-Oriented Programming (ECOOP), pages 327--353, London, UK, 2001. Springer-Verlag. Google ScholarGoogle Scholar
  25. G. Kiczales, J. Lamping, A. Mendhekar, C. Maeda, C. Lopes, J. M. Loingtier, and J. Irwing. Aspect-oriented programming. In ECOOP. Springer-Verlag, 1997.Google ScholarGoogle Scholar
  26. M. Kim, D. Notkin, and D. Grossman. Automatic inference of structural changes for matching across program versions. In ICSE '07: Proceedings of the 29th International Conference on Software Engineering, pages 333--343, 2007. Google ScholarGoogle Scholar
  27. J. C. King. Symbolic execution and program testing. Commun. ACM, 19(7):385--394, 1976. Google ScholarGoogle Scholar
  28. N. Kumar, B. R. Childers, and M. L. Soffa. Tdb: a source-level debugger for dynamically translated programs. In AADEBUG'05: Proceedings of the sixth international symposium on Automated analysis-driven debugging, pages 123--132, 2005. Google ScholarGoogle Scholar
  29. B. Liskov, A. Adya, M. Castro, S. Ghemawat, R. Gruber, U. Maheshwari, A. C. Myers, M. Day, and L. Shrira. Safe and efficient sharing of persistent objects in thor. In SIGMOD '96: Proceedings of the ACM SIGMOD international conference on management of data, pages 318--329. ACM, 1996. Google ScholarGoogle Scholar
  30. A. Marquez, S. Blackburn, G. Mercer, and J. N. Zigman. Implementing orthogonally persistent java. In POS-9: Revised Papers from the 9th International Workshop on Persistent Object Systems, pages 247--261, London, UK, 2001. Springer-Verlag. Google ScholarGoogle Scholar
  31. Microsoft. Microsoft Open Database Connectivity. http://msdn.microsoft.com/en-us/library/ms710252(VS. 85).aspx.Google ScholarGoogle Scholar
  32. A. Orso and B. Kennedy. Selective Capture and Replay of Program Executions. In Proceedings of the Third International ICSE Workshop on Dynamic Analysis (WODA 2005), pages 29--35, St. Louis, MO, USA, May 2005. Google ScholarGoogle Scholar
  33. A. Orso, A. Rao, and M. J. Harrold. A technique for dynamic updating of Java software. Proceedings of the International Conference on Software Maintenance (ICSM'02), October 2002. Google ScholarGoogle Scholar
  34. M. Philippsen and M. Zenger. JavaParty-transparent remote objects in Java. Concurrency Practice and Experience, 9(11):1225--1242, 1997.Google ScholarGoogle Scholar
  35. G. Pothier and Eric Tanter. Extending omniscient debugging to support aspect-oriented programming. In SAC '08: Proceedings of the 2008 ACM symposium on Applied computing, pages 266--270, 2008. Google ScholarGoogle Scholar
  36. S. C. Previtali and T. R. Gross. Dynamic updating of software systems based on aspects. Proceedings of the 22nd IEEE International Conference on Software Maintenance, pages 83 -- 92, September 2006. Google ScholarGoogle Scholar
  37. C. Richardson. Untangling enterprise Java. ACM Queue, 4(5):36--44, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  38. C. Russell. Java Data Objects 2.1, June 2007. http://db.apache.org/jdo/specifications.html.Google ScholarGoogle Scholar
  39. Shigeru Chiba. Java Programming Assistant. http://www.csg.is.titech.ac.jp/~chiba/javassist.Google ScholarGoogle Scholar
  40. G. Sittampalam, O. de Moor, and K. F. Larsen. Incremental execution of transformation specifications. In POPL '04: Proceedings of the 31st ACM SIGPLAN-SIGACT symposium on Principles of programming languages, pages 26--38, 2004. Google ScholarGoogle ScholarDigital LibraryDigital Library
  41. M. Song. The structural enhancement rules language website. http://research.cs.vt.edu/vtspaces/ser.Google ScholarGoogle Scholar
  42. H. Stuart, R. R. Hansen, J. L. Lawall, J. Andersen, Y. Padioleau, and G. Muller. Towards easing the diagnosis of bugs in os code. In PLOS '07: Proceedings of the 4th workshop on Programming languages and operating systems, pages 1--5, New York, NY, USA, 2007. ACM. Google ScholarGoogle Scholar
  43. Sun Microsystems. Java Platform Debugger Architecture. http://java.sun.com/javase/technologies/core/toolsapis/jpda/.Google ScholarGoogle Scholar
  44. Sun Microsystems. JavaBeans Specification. http://java.sun.com/javase/technologies/desktop/javabeans/docs/spec.html.Google ScholarGoogle Scholar
  45. Sun Microsystems. The Java Database Connectivity. http://java.sun.com/products/jdbc/overview.html.Google ScholarGoogle Scholar
  46. W. Tansey and E. Tilevich. Annotation refactoring: inferring upgrade transformations for legacy applications. In OOPSLA'08: Proceedings of the 23rd ACM SIGPLAN conference on Object oriented programming systems languages and applications, pages 295--312, 2008. Google ScholarGoogle Scholar
  47. E. Tilevich and Y. Smaragdakis. J-Orchestra: Automatic Java application partitioning. In Proceedings of the European Conference on Object-Oriented Programming (ECOOP), pages 178--204. Springer-Verlag, LNCS 2374, 2002. Google ScholarGoogle Scholar
  48. E. Tilevich and Y. Smaragdakis. Binary refactoring: Improving code behind the scenes. In Proceedings of International Conference on Software Engineering (ICSE), pages 264--273, May 2005. Google ScholarGoogle ScholarDigital LibraryDigital Library
  49. M. Verbaere, R. Ettinger, and O. de Moor. JunGL: a scripting language for refactoring. In ICSE '06: Proceedings of the 28th International Conference on Software Engineering, pages 172--181, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  50. E. Visser, Z. el Abidine Benaissa, and A. Tolmach. Building program optimizers with rewriting strategies. SIGPLAN Not., 34(1):13--26, 1999. Google ScholarGoogle Scholar
  51. D. L. Whitfield and M. L. Soffa. An approach for exploring code improving transformations. ACM Trans. Program. Lang. Syst., 19(6):1053--1084, 1997. Google ScholarGoogle Scholar

Index Terms

  1. Enhancing source-level programming tools with an awareness of transparent program transformations

          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

          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!