Skip to main content

Applying Code Specialization to FFT Libraries for Integral Parameters

  • Conference paper
Book cover Languages and Compilers for Parallel Computing (LCPC 2006)

Part of the book series: Lecture Notes in Computer Science ((LNTCS,volume 4382))

Abstract

Code specialization is an approach that can be used to improve the sequence of optimizations to be performed by the compiler. The performance of code after specialization may vary, depending upon the structure of the application. For FFT libraries, the specialization of code with different parameters may cause an increase in code size, thereby impacting overall behavior of applications executing in environment with small instruction caches.

In this article, we propose a new approach for specializing FFT code that can be effectively used to improve performance while limiting the code increase by incorporating dynamic specialization. Our approach makes use of a static compile time analysis and adapts a single version of code to multiple values through runtime specialization. This technique has been applied to different FFT libraries over Itanium IA-64 platform using icc compiler v 9.0. For highly efficient libraries, we are able to achieve speedup of more than 80% with small increase in code size.

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. Makholm, H.: Specializing c- an introduction to the principles behind c-mix. Technical report, Computer Science Department, University of Copenhagen (1999)

    Google Scholar 

  2. Consel, C., et al.: Tempo: Specializing Systems Applications and Beyond. ACM Computing Surveys 30(3es) (1998), citeseer.ist.psu.edu/consel98tempo.html

  3. Noël, F., et al.: Automatic, template-based run-time specialization: Implementation and experimental study. In: International Conference on Computer Languages (ICCL’98), February (1998)

    Google Scholar 

  4. Leone, M., Lee, P.: Dynamic Specialization in the Fabius System. ACM Computing Surveys 30(3es) (1998)

    Google Scholar 

  5. Consel, C., et al.: A uniform approach for compile-time and run-time specialization. In: Danvy, O., Thiemann, P., Glück, R. (eds.) Partial Evaluation. LNCS, vol. 1110, pp. 54–72. Springer, Heidelberg (1996)

    Google Scholar 

  6. Grant, B., et al.: Dyc: An expressive annotation-directed dynamic compiler for c. Technical report, Department of Computer Science and Engineering, University of Washington (1999)

    Google Scholar 

  7. Poletto, M., et al.: ’c and tcc: A language and compiler for dynamic code generation. ACM Transactions on Programming Languages and Systems 21, 324–369 (1999)

    Article  Google Scholar 

  8. Frigo, M., Johnson, S.G.: The design and implementation of fftw3. Proceedings of IEEE 93(2), 216–231 (2005)

    Article  Google Scholar 

  9. Frigo, M., G., J.S.: FFTW: An adaptive software architecture for the FFT. In: Proc. IEEE Intl. Conf. on Acoustics, Speech, and Signal Processing, vol. 3, Seattle, WA, May 1998, pp. 1381–1384. IEEE Computer Society Press, Los Alamitos (1998), citeseer.ist.psu.edu/frigo98fftw.html

    Google Scholar 

  10. Galassi, M., et al.: GNU Scientific Library Reference Manual - Revised Second Edition (2005), http://www.gnu.org/software/gsl/

  11. Gough, B.: SciMark 2.0 (2000), http://math.nist.gov/scimark2/

  12. Valkenburg, P.: FFT2 Library (2006), http://www.jjj.de/fft/

  13. Hein, C.: Numerical Utilities (2003), http://atl.external.lmco.com/projects/csim/xgraph/numutil

  14. Borgerding, M.: KissFFT v1.2.5 (2006), http://sourceforge.net/projects/kissfft/

  15. Jones, N.D., Gomard, C., Sestoft, P.: Partial Evaluation and Automatic Program Generation. International Series in Computer Science. Prentice Hall International, Englewood Cliffs (1993)

    MATH  Google Scholar 

  16. Brifault, K., Charles, H.-P.: Efficient data driven run-time code generation. In: LCR ’04: Proceedings of the 7th workshop on Workshop on languages, compilers, and run-time support for scalable systems, Houston, Texas, pp. 1–7. ACM Press, New York (2004), doi:10.1145/1066650.1066653

    Chapter  Google Scholar 

  17. Locanthi, B.N.: Fast bitblt() with asm() and cpp. In: European UNIX Systems User Group Conference Proceedings (1987)

    Google Scholar 

  18. Grant, B., et al.: Annotation-Directed Run-Time Specialization in C. In: Proceedings of the ACM SIGPLAN Symposium on Partial Evaluation and Semantics-Based Program Manipulation (PEPM’97), June 1997, pp. 163–178. ACM Press, New York (1997), citeseer.ist.psu.edu/63006.html

    Chapter  Google Scholar 

  19. Engler, D.R., Proebsting, T.A.: DCG: An efficient, retargetable dynamic code generation system. In: Proceedings of the Sixth International Conference on Architectural Support for Programming Languages and Operating Systems, San Jose, California, pp. 263–272 (1994), citeseer.ist.psu.edu/engler94dcg.html

  20. Engler, D.R.: Vcode: A retargetable extensible, very fast dynamic code generation system. In: Proceedings of the SIGPLAN 96 Conference on Programming Language Design and Implementation, ACM Press, New York (1996)

    Google Scholar 

  21. Leone, M., Lee, P.: Optimizing ml with run-time code generation. Technical report, School of Computer Science, Carnegie Mellon University (1995)

    Google Scholar 

  22. Leone, M., Lee, P.: A Declarative Approach to Run-Time Code Generation. In: Workshop on Compiler Support for System Software (WCSSS), February (1996), citeseer.ist.psu.edu/leone96declarative.html

Download references

Author information

Authors and Affiliations

Authors

Editor information

George Almási Călin Caşcaval Peng Wu

Rights and permissions

Reprints and permissions

Copyright information

© 2007 Springer Berlin Heidelberg

About this paper

Cite this paper

Khan, M.A., Charles, HP. (2007). Applying Code Specialization to FFT Libraries for Integral Parameters. In: Almási, G., Caşcaval, C., Wu, P. (eds) Languages and Compilers for Parallel Computing. LCPC 2006. Lecture Notes in Computer Science, vol 4382. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-540-72521-3_8

Download citation

  • DOI: https://doi.org/10.1007/978-3-540-72521-3_8

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-540-72520-6

  • Online ISBN: 978-3-540-72521-3

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics