Date and time:
Thursday, April 15, 2010 - 15:50 - 17:30
- Type Specialization in Scala
Iulian Dragos
Compilation of polymorphic code through type erasure gives compact code but performance on primitive types is significantly hurt. Full specialization gives good performance, but at the cost of increased code size and compilation time. Instead we propose a mixed approach, which allows the programmer decide what code to specialize. Our approach supports separate compilation, allows mixing of specialized and generic code, and gives very good results in practice.
- Leaky Monads - An Experiment with Automatic Resource Management
Josh Suereth
This talk covers an experimental library I've been working on for Automatic Resource Management. The goal was to come up with some kind of abstraction that would work across Sockets, File I/O, JDBC, JTA and JNDI/RMI. The library also needed to have configurable methods of obtaining connections, including optional-retry and various execution styles (e.g. threaded). The most interesting aspect was the desire to allow the “managed” monad to automatically “leak” other monads when it is safe to do so. This library makes use of new Scala features found in 2.8 to do so. The talk will cover the basic abstraction, implementation for JNDI/RMI and how to create “leaks” in the monad.
- Mnemonics - Type-safe bytecode generation with Scala
Johannes Rudolph
Mnemonics is a Scala library for generating method bodies in JVM bytecode at run time. Mnemonics supports a large subset of the JVM instructions, for which the static typing of the generator guarantees the well-formedness of the generated bytecode. The library exploits a number of features of Scala's type system (type inference, implicit parameters, and reflection) to guarantee that the compiler only accepts legal combinations of instructions at compile time. Additional instructions can be supported at the price of a check at run time of the generator. In either case, bytecode verification of generated code is guaranteed to succeed.
Due to space constraints, this session is limited to max 50-60 people.