skip to main content
10.1145/1376789.1376791acmconferencesArticle/Chapter ViewAbstractPublication PagessospConference Proceedingsconference-collections
research-article

Writing systems software in a functional language: an experience report

Published: 18 October 2007 Publication History

Abstract

Current practices for developing systems software usually rely on fairly low-level programming languages and tools. As an alternative, our group has been investigating the possibility of using a high-level functional language, Haskell, for kernel and device driver construction, with the hope that it will allow us to produce more reliable and secure software. In this paper, we describe our experience developing a prototype operating system, House, in which the kernel, device drivers, and even a simple GUI, are all written in Haskell. The House system demonstrates that it is indeed possible to construct systems software in a functional language. However, it also suggests some ideas for a new Haskell dialect with features that target specific needs in this domain, including strongly typed support for low-level data structures and facilities for explicit memory accounting.

References

[1]
Sébastian Carlier and Jérémy Bobbio. hOp. http://etudiants.insia.org/~jbobbio/hOp/, 2004.
[2]
Manuel M. T. Chakravarty and the Haskell FFI Team. Haskell 98 Foreign Function Interface (1.0), 2003. http://www.cse.unsw.edu.au/~chak/haskell/ffi.
[3]
Iavor S. Diatchki and Mark P. Jones. Strongly Typed Memory Areas. In Proceedings of ACM SIGPLAN 2006 Haskell Workshop, pages 72--83, Portland, Oregon, September 2006.
[4]
Iavor S. Diatchki, Mark P. Jones, and Rebekah Leslie. High-level Views on Low-level Representations. In Proceedings of the Tenth ACM SIGPLAN International Conference on Functional Programming, pages 168--179, Tallinn, Estonia, September 2005.
[5]
Iavor Sotirov Diatchki. High-Level Abstractions for Low-Level Programming. PhD thesis, OGI School of Science & Engineering at Oregon Health & Science University, May 2007.
[6]
Dhammika Elkaduwe, Philip Derrin, and Kevin Elphinstone. A memory allocation model for an embedded microkernel. In Proceedings of the 1st International Workshop on Microkernels for Embedded Systems, Sydney, Australia, January 2007.
[7]
Guangrui Fu. Design and Implementation of an Operating System in Standard ML. Master's thesis, University of Hawaii at Manoa, August 1999.
[8]
Andreas Haeberlen and Kevin Elphinstone. User-level management of kernel memory. In Proceedings of the Eighth Asia-Pacific Computer Systems Architecture Conference (ACSAC'03), Aizu-Wakamatsu City, Japan, September 2003.
[9]
Thomas Hallgren, Mark P. Jones, Rebekah Leslie, and Andrew Tolmach. A Principled Approach to Operating System Construction in Haskell. In Proceedings of the Tenth ACM SIGPLAN International Conference on Functional Programming, pages 116--128, Tallinn, Estonia, September 2005.
[10]
Robert Harper, Peter Lee, and Frank Pfenning. The Fox project: Advanced Language Technology for Extensible Systems. Technical Report CMU-CS-98-107, School of Computer Science, Carnegie Mellon University, January 1998.
[11]
Galen C. Hunt and James R. Larus. Singularity: rethinking the software stack. Operating Systems Review, 41(2):37--49, 2007.
[12]
Intel Corporation. IA-32 Intel Architecture Software Developer's Manual (Volume 3a), January 2006. http://www.intel.com/products/processor/manuals/index.htm, date viewed: 25 April 2007.
[13]
Mark P. Jones. A System of Constructor Classes: Overloading and Implicit Higher-Order Polymorphism. Journal of Functional Programming, 5(1):1--35, January 1995.
[14]
Mark P. Jones, Magnus Carlsson, and Johan Nordlander. Composed, and in Control: Programming the Timber Robot. Technical report, OGI School of Science & Engineering at OHSU, August 2002.
[15]
Bernhard Kauer. L4.sec Implementation - Kernel Memory Management. Diploma Thesis, Dresden University of Technology, May 2005.
[16]
Brian W. Kernighan and Dennis M. Ritchie. The C Programming Language. Prentice Hall, 1988.
[17]
L4ka Team. L4 eXperimental Kernel Reference Manual, January 2005. http://14ka.org/.
[18]
Xiaoming Liu, Christoph Kreitz, Robbert van Renesse, Jason Hickey, Mark Hayden, Ken Birman, and Robert Constable. Building Reliable, High-Performance Communication Systems from Components. In Proceedings of the Seventeenth ACM Symposium on Operating System Principles, pages 80--92, Kiawah Island Resort, SC, USA, December 1999.
[19]
Andrew McCreight, Zhong Shao, Chunxiao Lin, and Long Li. A general framework for certifying garbage collectors and their mutators. In Proceedings of the 2007 ACM SIGPLAN Conference on Programming Language Design and Implementation (PLDI'07), pages 468--479, San Diego, CA, June 2007.
[20]
Simon Peyton Jones, editor. Haskell 98 Language and Libraries, The Revised Report. Cambridge University Press, 2003.
[21]
Philip Wadler and Stephen Blott. How to Make Ad-hoc Polymorphism Less Ad Hoc. In Proceedings of the Sixteenth ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages, pages 60--76, Austin, TX, USA, January 1989.

Cited By

View all

Recommendations

Comments

Information & Contributors

Information

Published In

cover image ACM Conferences
PLOS '07: Proceedings of the 4th workshop on Programming languages and operating systems
October 2007
55 pages
ISBN:9781595939227
DOI:10.1145/1376789
Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than ACM must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected]

Sponsors

Publisher

Association for Computing Machinery

New York, NY, United States

Publication History

Published: 18 October 2007

Permissions

Request permissions for this article.

Check for updates

Qualifiers

  • Research-article

Conference

PLOS07
Sponsor:

Acceptance Rates

Overall Acceptance Rate 17 of 32 submissions, 53%

Upcoming Conference

SOSP '25
ACM SIGOPS 31st Symposium on Operating Systems Principles
October 13 - 16, 2025
Seoul , Republic of Korea

Contributors

Other Metrics

Bibliometrics & Citations

Bibliometrics

Article Metrics

  • Downloads (Last 12 months)6
  • Downloads (Last 6 weeks)0
Reflects downloads up to 15 Feb 2025

Other Metrics

Citations

Cited By

View all

View Options

Login options

View options

PDF

View or Download as a PDF file.

PDF

eReader

View online with eReader.

eReader

Figures

Tables

Media

Share

Share

Share this Publication link

Share on social media