Orc – The Oil Runtime Compiler

Orc is a library and set of tools for compiling and executing very simple programs that operate on arrays of data.  The “language” is a generic assembly language that represents many of the features available in SIMD architectures, including saturated addition and subtraction, and many arithmetic operations.

The 0.4 series of Orc releases will be API and ABI compatible, and will be incompatible with the 0.5 series when it comes out.  It is anticipated that 0.5 will follow in a few months.

Features:

  • Users can create, compile, and run simple programs that use the vector extensions of the CPU, all directly from an application.
  • Users can compile Orc programs to assembly source code to be compiled and used without linking against the Orc library.
  • The generic assembly language can be extended by an application by adding new opcodes.
  • An application can add rules for converting existing or new opcodes to binary code for a specific target.
  • Current targets: SSE, MMX, ARM, Altivec, and NEON.  There is also a TI c64x+ DSP target that only generates source code (no runtime).
  • Programs can optionally be emulated, which is useful for testing, or if no rules are available to convert Orc opcodes to executable code.

Download:

Source code releases: code.entropywave.com/download/orc/
Git repository: git://code.entropywave.com/git/orc.git
Repository view: code.entropywave.com/git?p=orc.git;a=summary

Documentation:

Orc Reference Manual

Examples:

The Schroedinger video codec uses Orc extensively.

The GStreamer “Base”, “Good”, and “Bad” use Orc for some of the low-level media processing plugins.  This is an area of active development.

Comments are closed.