Skip to main content

Using Rewriting to Synthesize Functional Languages to Digital Circuits

  • Conference paper

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

Abstract

A straightforward synthesis from functional languages to digital circuits transforms variables to wires. The types of these variables determine the bit-width of the wires. Assigning a bit-width to polymorphic and function-type variables within this direct synthesis scheme is impossible. Using a term rewrite system, polymorphic and function-type binders can be completely eliminated from a circuit description, given only minor and reasonable restrictions on the input. The presented term rewrite system is used in the compiler for CλaSH: a polymorphic, higher-order, functional hardware description language.

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

Buying options

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   49.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

Learn about institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. Baaij, C.P.R., Kooijman, M., Kuper, J., Boeijink, W.A., Gerards, M.E.T.: CλaSH: Structural Descriptions of Synchronous Hardware using Haskell. In: Proceedings of the 13th Conference on Digital System Design, USA, pp. 714–721. IEEE Computer Society (September 2010)

    Google Scholar 

  2. Gerards, M.E.T., Baaij, C.P.R., Kuper, J., Kooijman, M.: Higher-Order Abstraction in Hardware Descriptions with CλaSH. In: Proceedings of the 14th Conference on Digital System Design, USA, pp. 495–502. IEEE Computer Society (August 2011)

    Google Scholar 

  3. Mitchell, N., Runciman, C.: Losing Functions without Gaining Data. In: Proceedings of the Second Symposium on Haskell, pp. 13–24. ACM (September 2009)

    Google Scholar 

  4. Frankau, S.: Hardware Synthesis from a Stream-Processing Functional Language. PhD thesis, University of Cambridge (July 2004)

    Google Scholar 

  5. Peyton Jones, S. (ed.): Haskell 98 Language and Libraries. Journal of Functional Programming, vol. 13 (2003)

    Google Scholar 

  6. The GHC Team: The GHC Compiler, version 7.6.1 (January 2013), http://haskell.org/ghc

  7. Mycroft, A., Sharp, R.: A Statically Allocated Parallel Functional Language. In: Montanari, U., Rolim, J.D.P., Welzl, E. (eds.) ICALP 2000. LNCS, vol. 1853, pp. 37–48. Springer, Heidelberg (2000)

    Chapter  Google Scholar 

  8. Nikhil, R.S.: Bluespec: A General-Purpose Approach to High-Level Synthesis Based on Parallel Atomic Transactions. In: Coussy, P., Morawiec, A. (eds.) High-Level Synthesis - From Algorithm to Digital Circuit, pp. 129–146. Springer, Netherlands (2008)

    Google Scholar 

  9. Hoe, J.C., Arvind.: Hardware Synthesis from Term Rewriting Systems. In: Proceedings of the tenth International Conference on VLSI, pp. 595–619 (1999)

    Google Scholar 

  10. Bjesse, P., Claessen, K., Sheeran, M., Singh, S.: Lava: Hardware Design in Haskell. In: Proceedings of the Third International Conference on Functional Programming (ICFP), pp. 174–184. ACM (1998)

    Google Scholar 

  11. Gill, A.: Type-Safe Observable Sharing in Haskell. In: Proceedings of the Second Haskell Symposium, pp. 117–128. ACM (September 2009)

    Google Scholar 

  12. Ghica, D.R.: Geometry of Synthesis: A structured approach to VLSI design. In: Proceedings of the 34th Annual Symposium on Principles of Programming Languages (POPL), pp. 363–375. ACM (2007)

    Google Scholar 

  13. Reynolds, J.C.: Definitional Interpreters for Higher-Order Programming Languages. In: Proceedings of the 25th ACM National Conference, pp. 717–740. ACM Press (1972)

    Google Scholar 

  14. Pottier, F., Gauthier, N.: Polymorphic Typed Defunctionalization. In: Proceedings of the 31st Symposium on Principles of Programming Languages (POPL), pp. 89–98. ACM (2004)

    Google Scholar 

  15. Bell, J.M., Bellegarde, F., Hook, J.: Type-Driven Defunctionalization. In: Proceedings of the Second International Conference on Functional Programming (ICFP), pp. 25–37 (1997)

    Google Scholar 

  16. Peyton Jones, S., Santos, A.: Compilation by Transformation in the Glasgow Haskell Compiler. In: Functional Programming Workshops in Computing, pp. 184–204. Springer (1994)

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2014 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

Baaij, C., Kuper, J. (2014). Using Rewriting to Synthesize Functional Languages to Digital Circuits. In: McCarthy, J. (eds) Trends in Functional Programming. TFP 2013. Lecture Notes in Computer Science, vol 8322. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-642-45340-3_2

Download citation

  • DOI: https://doi.org/10.1007/978-3-642-45340-3_2

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-642-45339-7

  • Online ISBN: 978-3-642-45340-3

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics