CUFP 2008 Abstracts

Invited Talk.
Why Microsoft is Investing in Functional Programming

Speaker: Don Syme, Microsoft
Abstract: Over the last 10 years Microsoft have made investments in programming technologies strongly influenced by functional programming techniques and languages, from generics in C# 2.0, LINQ in .NET 3.5 and futures in the .NET Parallel Extensions Library. Most recently Microsoft has announced that it is bringing F#, a functional/OO language for .NET, to product quality, as well as continuing its research investments in both Haskell and foundational language techniques.

This talk will take a look at these developments and why Microsoft is making these investments. We will focus on F# in particular: where does F# fit in the spectrum of Microsoft development tools? What kind of tasks is F# fashioned for? How has F# grown up over the years to be influenced by OCaml, C#, Haskell, Python and other languages? We'll look at these and other questions as we explore one of the many ways in which research and practice have come together over the last 10 years at Microsoft.

Note: A separate DEFUN tutorial on F# will allow you to take a hands-on look at the more technical side of the language.

Minimizing the “Immune Response” to Functional Programming
Speaker: David Balaban, Amgen
Contributors: David Balaban & Darrell Lewis-Sandy, Amgen
Abstract: Functional programming was introduced at Amgen for three main reasons:

  • To rapidly build software to implement mathematical models and other complex, mathematically oriented applications
  • Provide a more mathematically rigorous validation of software
  • To break developers out of their software development rut by giving them a new way to think about software.

Our experience is that using functional programming reduces the critical conceptual distance between thought/algorithm design and code. In several projects, we have been able to develop code quickly and to verify — to an applied mathematician's satisfaction — the correctness of Haskell code straightforwardly; we have yet to achieve this with more traditional mainstream languages. In several cases, the Haskell code has evolved quickly, matching the pace at which our understanding of the underlying problems has evolved.

We have found that many of the informatics staff are enthusiastic about and inspired by this approach, even though many have not yet begun to apply Haskell in their routine work. On the other hand, those developers who have a more traditional approach to software development may view our prodding toward a more mathematical approach to thinking about algorithms and programming with scepticism. For these staff, our prodding toward a more mathematical approach to thinking about algorithms and programming is viewed as a distraction at best and often produces a genuine intellectual immune response.

We will illustrate the places where functional programming has been useful to us with examples from pharmacodynamics and supply chain management. These will show, for example, how lazy evaluation can greatly simplify the coding of a complex simulation. We will also describe plans to expand the use of functional programming with additional training classes and recruitment strategies that may make it easier to find people with deep functional programming experience and applied mathematics skills.

The Mobile Messaging Gateway, from Idea to Prototype to Launch in 12 Months
Speaker: Francesco Cesarini, Erlang Training and Consulting
Abstract: What might not be obvious from our company name and our website is the fact that our fastest growing business segment is in house software development on behalf of third parties, keeping well over a third of our staff busy. In early 2007, we were awarded a major contract to build a generic multi service / community mobile instant messaging gateway.

More and more operators have started re- routing IP related traffic through gateways. The advantages in using gateways include authentication & authorization, billing, data compression, optimised communication protocols and control over the clients being used. It also facilitates support and maintenance, providing a single point of entrance for all IP related services.

The talk will describe how we convinced the client to bet on Erlang and Functional Programming and go ahead with our solution. It will cover the challenges we faced as an organisation, most specifically on testing and verification, getting our client to migrate from waterfall models to agile development and an ever changing list of requirements. The project was a challenge, not technically, as Erlang was the right choice, but from an organizational point of view, as it allowed us to double in size over 12 months. What was really challenged were our organisational and logistical skills, taking us form a company in start-up phase to a mature organisation capable of handling the growth.

A part of the talk is dedicated to stress testing Erlang on multi-core, and the difficulties in making the system run at 100% CPU. It concludes with many of the myths of Erlang, urban legends which are not true when dealing with true product development.

From OCaml to Javascript at Skydeck
Speaker: Jake Donham, Skydeck
Abstract: Skydeck is a startup software company building a service to help consumers manage their cell phones online. From the beginning we have used OCaml as our primary language for software development.

A key piece of our system is a Firefox extension that imports cell phone bills and phone usage data from phone carrier web sites. Firefox extensions are written in Javascript; to speed our development we wrote OCamljs, a Javascript back-end to the OCaml compiler. Using OCamljs we get the benefits of OCaml's expressiveness and compile-time typechecking, the use of OCaml-specific tools like OCamlbuild and Camlp4, and easier integration with our OCaml server infrastructure. In particular, OCamljs lets us make and deploy changes very quickly with confidence.

This talk will describe OCamljs and how we use it at Skydeck, and reflect briefly on the wisdom of using an atypical language at a startup.

Developing Erlang at Yahoo
Speaker: Nick Gerakines, Yahoo
Contributors: Nick Gerakines & Mark Zweifel, Yahoo
Abstract: Yahoo is no stranger to functional programming languages. It has had significant products in languages like Lisp and Scheme. Somehow Erlang, and other function languages, are often overlooked when most developers are researching various problems and systems. This is very unfortunate given the power and flexibility that these languages provide. At Yahoo there are places where functional languages and make a phenomenal difference in the way problems and solutions are approached. This presentation will cover how Erlang, a powerful and flexible functional language, gave us exactly what we needed at a critical time and how it was approached as a production language at Yahoo.

Controlling Hybrid Vehicles with Haskell
Speaker: Tom Hawkins, Eaton Corporation
Abstract: To address environmental concerns and rising fuel prices, Eaton is developing a family of hydraulic hybrid systems to increase fuel economy for heavy duty trucks. Hydraulic hybrids work much the same as their electric hybrid counterparts. Instead of an electric motor and battery, hydraulic hybrids use pumps, valves, and accumulators to capture and return a vehicle's kinetic energy. Most of these components are under direct software control, and, due to the nature of the application, often require a high level of safety. By using functional languages, we are able to intuitively describe safety critical behavior of the system, thus lowering the chance of introducing bugs in the design phase. Our experimental environment uses a Haskell DSL called Atom, which compiles a program of atomic state transition rules into a form that can be flashed onto a vehicle's electronic control unit (ECU). With proper rule scheduling, Atom can transform a multi-task, multi-rate program into a single thread of execution, thereby eliminating the need for run-time scheduling, context switching, and inter-process communication. We coin this “RTOS Synthesis” as it does most of the work of a real-time operating system, but with compile-time guarantees as opposed to run-time exceptions.

Ad Serving with Erlang
Speaker: Bob Ippolito, Mochimedia
Abstract: We've been using Erlang at Mochi Media since the 2006 launch of MochiAds, our advertising platform for Flash games. It's the first time any of us have done any production software with a functional programming language, and thus far it's turned out to be a great experience. The success of the MochiAds platform led us to writing many other products (internal and external) on the same technology stack. We believe Erlang to be one of the key reasons why we're able to develop more quickly and scale more easily than our competitors.

Xen and the art of OCaml
Speaker: Anil Madhavapeddy, Citrix
Contributors: Anil Madhavapeddy, Dave Scott & Richard Sharp, Citrix
Abstract: XenServer is a virtualization product that offers near bare-metal virtualization performance for virtualized server and desktop operating systems. It includes a comprehensive implementation of the XenAPI, which encapsulates the configuration and deployment of VMs, storage and networking topologies across pools of physical hosts running XenServer. The management tool-stack is written almost entirely in Objective Caml, and is one of the largest systems-level projects written in that language to date.

In this talk, we will firstly describe the architecture of XenServer and the XenAPI and discuss the challenges faced with implementing an Objective Caml based solution. These challenges range from the low-level concerns of interfacing with Xen and the Linux kernel, to the high-level algorithmic problems such as distributed failure planning. In addition, we will discuss the challenges imposed by using OCaml in a commercial environment, such as supporting product upgrades, enhancing supportability and scaling the development team.

Quantitative Finance in F#
Speaker: Howard Mansell, Credit Suisse
Abstract: Building valuation models for derivative trades requires rapid development of mathematical models, made possible by composition of lower-level model components. We have found that F#, with the associated toolset, provides a unique combination of features that make it very well suited to this kind of development. In this talk, I will explain how we are using F# and show why it is a good match. I will also talk about the problems we have had, and outline future enhancements that would benefit this kind of work.

Is HaskellRready for Everyday Computing?
Speaker: Jeff Polakow, Deutsche Bank
Abstract: I will talk about my experience using (mostly) Haskell to design and implement the software infrastructure for a small trading group at Deutsche Bank. Most of the applications I write deal with such quotidian tasks as acquiring data from external sources, linking up related information from different sources, searching for specific patterns and making data available through a webserver. In addition to outlining my overall system architecture and highlighting some novel aspects of my implementation, I will discuss the various pros and cons, technical and otherwise, of using Haskell in a corporate environment.

Buy a Feature: An Adventure in Immutability and Actors
Speaker: David Pollak, Lift Web Framework
Abstract: I will discuss the functional programing paradigms that we used to build Buy a Feature, a multi-user, web-based, real-time, serious game. These paradigms include Actors to manage concurrency, event streams as the sole mechanism for gameplay, and various immutable data structures that are composed based on the event streams. I will also briefly touch on the Scala programming language and lift web framework.

I will then discuss the experience of adding new team members to the project, the kind of defects in the application (hint: none are concurrency related), the experience of adding new features, and a general discussion of how well functional paradigms translate into a real-world web application.

Functions to Junctions: Ultra Low Power Chip Design With Some Help From Haskell
Speaker: Gregory Wright, Antiope
Abstract: Antiope Associates designs custom wireless communication systems. This talk describes how we used Haskell to design a protocol for an ultra-low power radio chip. Haskell played two roles: it was the main language for the simulation system used to design and debug the protocol, and it was used in tools we wrote to verify that the protocol was correctly implemented in silicon.

The challenges of working with customers and vendors unfamiliar with functional programming will be mentioned, as well as the lessons we can draw from using these techniques in a small company.

5 August 2008