Compiling dynamic languages via typed functional languages
dc.contributor.author | Bandyopadhyay, Raj | en_US |
dc.contributor.author | Taha, Walid | en_US |
dc.date.accessioned | 2017-08-02T22:03:05Z | en_US |
dc.date.available | 2017-08-02T22:03:05Z | en_US |
dc.date.issued | 2007-10-19 | en_US |
dc.date.note | October 19, 2007 | en_US |
dc.description.abstract | Dynamic languages enable rapid prototyping, while statically typed languages offer early error-detection and efficient execution. As a result, the usual practice in software development is to build a prototype in a dynamic language and then rewrite the application in C or Fortran for high performance. Our thesis is that this costly rewriting step can be avoided if we have good native code compilers for dynamic languages. To overcome the difficulties in building good native code compilers from scratch, we propose that dynamic languages can be compiled into high-performance native code executables by translating to typed functional languages and reusing existing functional language compilers. We demonstrate this approach by compiling a popular dynamic language, Python, by translating it to OCaml, a strongly typed functional language. On performing a compar tive evaluation against several available Python implementations on both Windows and Linux platforms, we obtain highly encouraging results . In this paper, we use Python as proof-of-concept to demonstrate that our approach delivers efficient native code compilers for dynamic languages. We describe how source dynamic language objects and constructs can be expressed in terms of target typed functional language data types. Finally, we present a comparative performance analysis against different Python implementations such as CPython, IronPython, PyPy and Jython to illustrate the effectiveness of our approach. | en_US |
dc.format.extent | 10 pp | en_US |
dc.identifier.citation | Bandyopadhyay, Raj and Taha, Walid. "Compiling dynamic languages via typed functional languages." (2007) https://hdl.handle.net/1911/96363. | en_US |
dc.identifier.digital | TR07-7 | en_US |
dc.identifier.uri | https://hdl.handle.net/1911/96363 | en_US |
dc.language.iso | eng | en_US |
dc.rights | You are granted permission for the noncommercial reproduction, distribution, display, and performance of this technical report in any format, but this permission is only for a period of forty-five (45) days from the most recent time that you verified that this technical report is still available from the Computer Science Department of Rice University under terms that include this permission. All other rights are reserved by the author(s). | en_US |
dc.title | Compiling dynamic languages via typed functional languages | en_US |
dc.type | Technical report | en_US |
dc.type.dcmi | Text | en_US |
Files
Original bundle
1 - 1 of 1