Daffodil How Functional Programming leads to tight C code at Runtime
summary
Shows that a Scala compiler using lazy attribute grammars and aggressive lazy evaluation turns DFDL schemas into tight, hand-comparable C by generating structs, unions and direct parse/unparse calls. The project is Apache Daffodil with a 720,000-line TDML test suite and ~115,000 lines of Scala; the new runtime2 C generator emits flat, statically allocated C, drops backtracking and huge heaps, and already produces correct parsers for small schemas. Example: a 174-byte binary message inflates to 1,493 bytes as XML but remains ~160 bytes as EXI.
AI-written summary · about
chapters (31)
- 0:00Introduction
- 1:35What is Daffodil
- 2:30ISO 853
- 3:35Daffodil Innovations
- 4:30Daffodil Unparsing
- 5:20Data Conversion
- 7:15Daffodil Infoset
- 8:25Daffodil in Scala
- 9:20The C Runtime
- 9:45Whats in Daffodil
- 10:15Daffodil for Space
- 11:20How Compilers Work
- 12:35Lazy Evaluation
- 14:30Schema Model
- 15:15Attribute Grammars
- 17:40Lazy Evaluation Initiative
- 23:20Leg Hosts
- 25:50Grammar Tree
- 26:20Optimizer Framework
- 28:29Runtime
- 29:07Schema
- 29:44Runtime 2 goals
- 30:59Runtime 2 infoset
- 32:30How Runtime 2 works
- 33:22Simple schema
- 34:18Union structure
- 35:10Unparse
- 35:59Error Handling
- 36:33Data Format Debugger
- 37:55EXI
- 40:53Questions
