Profiling with AspectJ

David J. Pearce, Matthew Webster, Robert Berry, Paul H.J. Kelly

Research output: Contribution to journalArticle

Abstract

This paper investigates whether AspectJ can be used for efficient profiling of Java programs. Profiling differs from other applications of AOP (e.g. tracing), since it necessitates efficient and often complex interactions with the target program. As such, it was uncertain whether AspectJ could achieve this goal. Therefore, we investigate four common profiling problems (heap usage, object lifetime, wasted time and time-spent) and report on how well AspectJ handles them. For each, we provide an efficient implementation, discuss any trade-offs or limitations and present the results of an experimental evaluation into the costs of using it. Our conclusions are mixed. On the one hand, we find that AspectJ is sufficiently expressive to describe the four profiling problems and reasonably efficient in most cases. On the other hand, we find several limitations with the current AspectJ implementation that severely hamper its suitability for profiling. Copyright © 2006 John Wiley & Sons, Ltd.
Original languageEnglish
Pages (from-to)747-777
Number of pages31
JournalSoftware practice and experience
Volume37
Issue number7
Early online date23 Nov 2006
DOIs
Publication statusPublished - 1 Jun 2007

Fingerprint

Costs

Keywords

  • AspectJ
  • AOP
  • JAVA
  • profiling
  • performance

Cite this

Pearce, D. J., Webster, M., Berry, R., & Kelly, P. H. J. (2007). Profiling with AspectJ. Software practice and experience, 37(7), 747-777. https://doi.org/10.1002/spe.788
Pearce, David J. ; Webster, Matthew ; Berry, Robert ; Kelly, Paul H.J. / Profiling with AspectJ. In: Software practice and experience. 2007 ; Vol. 37, No. 7. pp. 747-777.
@article{ce689e19e6504df3b1a4415e5b3c0a0e,
title = "Profiling with AspectJ",
abstract = "This paper investigates whether AspectJ can be used for efficient profiling of Java programs. Profiling differs from other applications of AOP (e.g. tracing), since it necessitates efficient and often complex interactions with the target program. As such, it was uncertain whether AspectJ could achieve this goal. Therefore, we investigate four common profiling problems (heap usage, object lifetime, wasted time and time-spent) and report on how well AspectJ handles them. For each, we provide an efficient implementation, discuss any trade-offs or limitations and present the results of an experimental evaluation into the costs of using it. Our conclusions are mixed. On the one hand, we find that AspectJ is sufficiently expressive to describe the four profiling problems and reasonably efficient in most cases. On the other hand, we find several limitations with the current AspectJ implementation that severely hamper its suitability for profiling. Copyright {\circledC} 2006 John Wiley & Sons, Ltd.",
keywords = "AspectJ, AOP, JAVA, profiling, performance",
author = "Pearce, {David J.} and Matthew Webster and Robert Berry and Kelly, {Paul H.J.}",
year = "2007",
month = "6",
day = "1",
doi = "10.1002/spe.788",
language = "English",
volume = "37",
pages = "747--777",
journal = "Software practice and experience",
issn = "0038-0644",
publisher = "John Wiley and Sons Ltd",
number = "7",

}

Pearce, DJ, Webster, M, Berry, R & Kelly, PHJ 2007, 'Profiling with AspectJ', Software practice and experience, vol. 37, no. 7, pp. 747-777. https://doi.org/10.1002/spe.788

Profiling with AspectJ. / Pearce, David J.; Webster, Matthew; Berry, Robert; Kelly, Paul H.J.

In: Software practice and experience, Vol. 37, No. 7, 01.06.2007, p. 747-777.

Research output: Contribution to journalArticle

TY - JOUR

T1 - Profiling with AspectJ

AU - Pearce, David J.

AU - Webster, Matthew

AU - Berry, Robert

AU - Kelly, Paul H.J.

PY - 2007/6/1

Y1 - 2007/6/1

N2 - This paper investigates whether AspectJ can be used for efficient profiling of Java programs. Profiling differs from other applications of AOP (e.g. tracing), since it necessitates efficient and often complex interactions with the target program. As such, it was uncertain whether AspectJ could achieve this goal. Therefore, we investigate four common profiling problems (heap usage, object lifetime, wasted time and time-spent) and report on how well AspectJ handles them. For each, we provide an efficient implementation, discuss any trade-offs or limitations and present the results of an experimental evaluation into the costs of using it. Our conclusions are mixed. On the one hand, we find that AspectJ is sufficiently expressive to describe the four profiling problems and reasonably efficient in most cases. On the other hand, we find several limitations with the current AspectJ implementation that severely hamper its suitability for profiling. Copyright © 2006 John Wiley & Sons, Ltd.

AB - This paper investigates whether AspectJ can be used for efficient profiling of Java programs. Profiling differs from other applications of AOP (e.g. tracing), since it necessitates efficient and often complex interactions with the target program. As such, it was uncertain whether AspectJ could achieve this goal. Therefore, we investigate four common profiling problems (heap usage, object lifetime, wasted time and time-spent) and report on how well AspectJ handles them. For each, we provide an efficient implementation, discuss any trade-offs or limitations and present the results of an experimental evaluation into the costs of using it. Our conclusions are mixed. On the one hand, we find that AspectJ is sufficiently expressive to describe the four profiling problems and reasonably efficient in most cases. On the other hand, we find several limitations with the current AspectJ implementation that severely hamper its suitability for profiling. Copyright © 2006 John Wiley & Sons, Ltd.

KW - AspectJ

KW - AOP

KW - JAVA

KW - profiling

KW - performance

UR - http://onlinelibrary.wiley.com/doi/10.1002/spe.788/abstract

U2 - 10.1002/spe.788

DO - 10.1002/spe.788

M3 - Article

VL - 37

SP - 747

EP - 777

JO - Software practice and experience

JF - Software practice and experience

SN - 0038-0644

IS - 7

ER -

Pearce DJ, Webster M, Berry R, Kelly PHJ. Profiling with AspectJ. Software practice and experience. 2007 Jun 1;37(7):747-777. https://doi.org/10.1002/spe.788