Skip to main content

The Advantages of Post-Link Code Coverage

  • Conference paper
Hardware and Software: Verification and Testing (HVC 2007)

Part of the book series: Lecture Notes in Computer Science ((LNPSE,volume 4899))

Included in the following conference series:

  • 542 Accesses

Abstract

Code coverage is often defined as a measure of the degree to which the source code of a program has been tested [19]. Various metrics for measuring code coverage exist. The vast majority of these metrics require instrumenting the source code to produce coverage data. However, for certain coverage metrics, it is also possible to instrument object code to produce coverage data. Traditionally, such instrumentation has been considered inferior to source level instrumentation because source code is the focus of code coverage. Our experience shows that object code instrumentation, specifically post-link instrumentation, can be very useful to users. Moreover, it does not only alleviate certain side-effects of source-level instrumentation, especially those related to compiler optimizations, but also lends itself to performance optimization that enables low-overhead instrumentation. Our experiments show an average of less than 1% overhead for instrumentation at the function level and an average of 4.1% and 0.4% overhead for SPECint2000 and SPECfp2000, respectively, for instrumentation at the basic block level. This paper demonstrates the advantages of post-link coverage and describes effective methodology and technology for applying it.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 39.99
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 54.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. Balakrishnan, G., Reps, T., Melski, D., Teitelbaum, T.: Wysinwyx: What you see is not what you execute. In: Verified Software: Theories, Tools, Experiments. Springer, Heidelberg (to appear), http://citeseer.ist.psu.edu/762389.html

  2. Code coverage metrics (accessed June 2007), http://www.bullseye.com/coverage.html

  3. Object coverage. (accessed June 2007), http://www.bullseye.com/coverage.html#other_object

  4. Cohn, R., Goodwin, D., Lowney, P.G.: Optimizing alpha executables on windows nt with spike. In: Digital Technical Journal (1997)

    Google Scholar 

  5. Contest concurrent testing tool (accessed June 2007), http://w3.haifa.ibm.com/softwaretesting/ConTest-Java/index.html

  6. Do-178b software considerations in airborne systems and equipment certification (accessed June 2007), http://en.wikipedia.org/wiki/DO-178B

  7. Focus functional and code coverage visuals and analysis (accessed June 2007) http://w3.haifa.ibm.com/softwaretesting/FoCuS/index.html

  8. G-cover object level coverage analysis (accessed June 2007), http://www.ghs.com/products/safety_critical/gcover.html

  9. Gcov coverage with gnu compiler gcc (accessed June 2007), http://gcc.gnu.org/onlinedocs/gcc/Gcov.html

  10. Grinwald, R., Harel, E., Orgad, M., S. U.S., Ziv, A.: User defined coverage - a tool supported methodology for design verification. In: DAC (June 1998)

    Google Scholar 

  11. Haber, G., Henis, E., Eisenberg, V.: Reliable post-link optimizations based on partial information. In: 3rd Workshop on Feedback Directed and Dynamic Optimizations (December 2000)

    Google Scholar 

  12. Haber, G., Klausner, M., Eisnebreg, V., Mendelson, B., Gurevich, M.: Optimization opportunities created by global data reordering. In: 1st International Symposium on Code Generation and Optimization (March 2003)

    Google Scholar 

  13. Henis, E.A., Haber, G., Klausner, M., Warshavsky, A.: Feedback based post-link optimization for large subsystems. In: 2nd Workshop on Feedback Directed Optimization (November 1999)

    Google Scholar 

  14. Muth, R., Debray, S., Watterson, S.: Alto: A link-time optimizer for the compaq alpha. Technical Report, 98-14, Dept. of Computer Science, The University of Arizona (December 1998)

    Google Scholar 

  15. Nahshon, I., Bernstein, D.: Fdpr - a post-pass object code optimization tool. In: Poster Session of the International Conference on Compiler Construction (April 1996)

    Google Scholar 

  16. Romer, T., Voelker, G., Lee, D., Wolman, A., Wong, W., Levy, H., Bershad, B., Chen, B.: Instrumentation and optimization of win32/intel executables using etch. In: USENIX Windows NT Workshop (August 1997)

    Google Scholar 

  17. Schmidt, W.J., Roediger, R.R., Mestad, C.S., Mendelson, B., Shavitt-Lottem, I., Bortnikov-Sitnitsky, V.: Profile-directed restructuring of operating system code. In: IBM Systems Journal (1998)

    Google Scholar 

  18. Schwarz, B., Debray, S., Andrews, G., Legendre, M.: Plto: A link-time optimizer for the intel ia-32 architecture. In: Workshop on Binary Rewriting (September 2001)

    Google Scholar 

  19. Wikipedia: Code coverage (accessed June 2007), http://en.wikipedia.org/wiki/Code_coverage

Download references

Author information

Authors and Affiliations

Authors

Editor information

Karen Yorav

Rights and permissions

Reprints and permissions

Copyright information

© 2008 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

Raz, O. et al. (2008). The Advantages of Post-Link Code Coverage. In: Yorav, K. (eds) Hardware and Software: Verification and Testing. HVC 2007. Lecture Notes in Computer Science, vol 4899. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-540-77966-7_19

Download citation

  • DOI: https://doi.org/10.1007/978-3-540-77966-7_19

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-540-77964-3

  • Online ISBN: 978-3-540-77966-7

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics