Journal article
Multi-stage programming with functors and monads: Eliminating abstraction overhead from generic code
Abstract
We use multi-stage programming, monads and Ocaml’s advanced module system to demonstrate how to eliminate all abstraction overhead from generic programs, while avoiding any inspection of the resulting code. We demonstrate this clearly with Gaussian Elimination as a representative family of symbolic and numeric algorithms. We parameterize our code to a great extent–over domain, input and permutation matrix representations, determinant and rank …
Authors
Carette J; Kiselyov O
Journal
Science of Computer Programming, Vol. 76, No. 5, pp. 349–375
Publisher
Elsevier
Publication Date
5 2011
DOI
10.1016/j.scico.2008.09.008
ISSN
0167-6423