InterAspect: aspect-oriented instrumentation with GCC

被引:8
作者
Seyster, Justin [1 ]
Dixit, Ketan [1 ]
Huang, Xiaowan [1 ]
Grosu, Radu [1 ]
Havelund, Klaus [2 ]
Smolka, Scott A. [1 ]
Stoller, Scott D. [1 ]
Zadok, Erez [1 ]
机构
[1] SUNY Stony Brook, Dept Comp Sci, Stony Brook, NY 11794 USA
[2] CALTECH, Jet Prop Lab, Pasadena, CA USA
基金
美国国家科学基金会;
关键词
Program instrumentation; Aspect-oriented programming; GCC; Monitoring; Tracecut;
D O I
10.1007/s10703-012-0171-3
中图分类号
TP301 [理论、方法];
学科分类号
081202 ;
摘要
We present the InterAspect instrumentation framework for GCC, a widely used compiler infrastructure. The addition of plug-in support in the latest release of GCC makes it an attractive platform for runtime instrumentation, as GCC plug-ins can directly add instrumentation by transforming the compiler's intermediate representation. Such transformations, however, require expert knowledge of GCC internals. InterAspect addresses this situation by allowing instrumentation plug-ins to be developed using the familiar vocabulary of Aspect-Oriented Programming: pointcuts, join points, and advice functions. Moreover, InterAspect uses specific information about each join point in a pointcut, possibly including results of static analysis, to support powerful customized instrumentation. We describe the InterAspect API and present several examples that illustrate its practical utility as a runtime-verification platform. We also introduce a tracecut system that uses InterAspect to construct program monitors that are formally specified as regular expressions.
引用
收藏
页码:295 / 320
页数:26
相关论文
共 20 条
  • [1] Adams B., 2008, ACP4IS 08, P1
  • [2] Allan Chris., 2005, P 20 ANN ACM SIGPLAN
  • [3] Avgustinov P., 2005, P 4 INT C ASP OR SOF
  • [4] Bodden E., 2008, Proceedings of the International Symposium on Software Testing and Analysis (ISSTA), P155, DOI DOI 10.1145/1390630.1390650
  • [5] Callanan S., 2007, PROC 2007 GCC DEVELO, P31
  • [6] Chen F, 2007, P 22 ANN ACM SIGPLAN
  • [7] Chiba S, 2000, LECT NOTES COMPUT SC, V1850, P313
  • [8] CHIBA S, 1995, SIGPLAN NOTICES, V30, P285, DOI 10.1145/217839.217868
  • [9] Coady Y., 2001, Software Engineering Notes, V26, P88, DOI 10.1145/503271.503223
  • [10] DOUENCE R, 2005, P 4 INT C ASP OR SOF