• This repository has been archived on 03/Feb/2019
  • Stars
    star
    125
  • Rank 286,335 (Top 6 %)
  • Language
    Clojure
  • License
    Eclipse Public Li...
  • Created over 10 years ago
  • Updated almost 9 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

[ABANDONED] An optimizing Clojure compiler

Project Oxcart

Then, I heard it. The click of the mic button from the back seat. Very professionally, and with no emotion, Walter spoke: "Los Angeles Center, Aspen 20, can you give us a ground speed check?" There was no hesitation, and the replay came as if was an everyday request. "Aspen 20, I show you at one thousand eight hundred and forty-two knots, across the ground."

–– Brian Schul, "Sled Driver: Flying the World's Fastest Jet"

—– http://oppositelock.jalopnik.com/favorite-sr-71-story-1079127041

Oxcart is a prototype Clojure compiler which seeks to provide aggressive AOT compilation for performance and memory usage. At present Oxcart is a holding tank for changes which will likely be split up between tools.emitter.jvm, tools.analyzer.jvm and some future tools.optimizer.jvm.

Oxcart is currently on indefinite hiatus, pending changes to Clojure addressing the current clojure.lang.RT <cinit> behavior of loading clojure/core from source. See the blog posts for more information.

Blog Posts

Stuff I read prior to starting Oxcart

Oxcart posts

Demos

The script "bench.sh" in the root of the Oxcart project is designed to run the various Oxcart benchmarks with minimal effort. Usage is bash bench.sh NS where NS is the namespace in the Oxcart source tree to be run as a benchmark. That namespace will be loaded first with Clojure 1.6, and then compiled & run via Oxcart. Runs are wraped in time invocations, although several benchmarks do their own timing internally.

test.call

Usage: bash bench.sh test.call

This namespace is designed to assess the cost of making function calls between Oxcart and core Clojure. It repeatedly invokes the test.call/vcall function to perform primitive arithmetic and is intended to measure the speedup from eliminating var indirection on test.call/vcall.

test.hello

Usage: bash bench.sh test.hello

This namespace just prints "Hello, World" as a test. Not actually a benchmark, unless you want to measure how long it takes to boot a Clojure instance, do minimal work and exit.

test.load

Usage: bash bench.sh test.load

This namespace loads a slightly modified version of test.vars, except that all the vars but test.load/-main are unreachable. This is intended as a demonstration of how slow it is to compile programs from source compared to loading them from compiled classes.

test.vars

Usage: bash bench.sh test.vars

This namespace defines 502 functions, most of which are trivial, and then calls a random set of them in a tight loop. This is also designed to stress the costs of var indirection as the tight loop function is much too large to reasonably inline across and the set of vars called in each iteration is random on each pair of possible functions which kills the branch predictor and increases the inlining cost.

License

Copyright Β© 2014 Reid McKenzie, Rich Hickey & contributors.

Distributed under the Eclipse Public License, the same as Clojure.

More Repositories

1

katamari

Roll up all your software into artifacts!
Clojure
67
star
2

shelving

A toolkit for building data stores.
Clojure
38
star
3

stacks

Sketches at a new documentation tool
Clojure
33
star
4

git-bump

A semantic versioning bump script
Python
33
star
5

guten-tag

Good tags for a good day!
Clojure
30
star
6

SimpleVM

a simple virtual machine which simulates a register machine
C
30
star
7

skrode

An exocortex
Python
11
star
8

rules_zapp

Zapp! your Python apps into zipapps
Python
10
star
9

pascal

A Pascal compiler & compiler toolkit written in Clojure
Clojure
10
star
10

toothpick

A Clojure assembler suite
Clojure
10
star
11

meajure

A Clojure math with units library
Clojure
8
star
12

Voicely

A voice command interface for Linux, and a fork of the Voximp project
Python
8
star
13

fortunes

Collected fortune files
8
star
14

blather

Grammars and noise
Clojure
8
star
15

source

Reid's monorepo
Python
6
star
16

plotter

A Clojure graphing toolkit wrapping gnuplot
Clojure
6
star
17

microfiche

[alpha] Javadoc as data for Clojure
Clojure
6
star
18

OpenSourcerer

An open source Magic : The Gathering implementation and AI
Python
6
star
19

cuddlefish

A cute little git wrapper
Clojure
5
star
20

sad

a Clojure parser compiler
Clojure
5
star
21

hyperwave

Clojure
4
star
22

ospl-mode

An Emacs minor mode for formatting Mardown with one sentence per line
Emacs Lisp
4
star
23

imprecise

A Clojure interval arithmetic library
Clojure
4
star
24

sounds-of-silence

Silence is golden
Clojure
4
star
25

AIM-514

A Verilog implementation of the AIM-514 Lisp Machine
HTML
3
star
26

detritus

Clojure bits and bats. Mainly bats.
Clojure
3
star
27

arrdem

2
star
28

decomp

An HTML to Clojure translator
Clojure
2
star
29

crashpad

Clojure
2
star
30

zsh-goto

a goto tool for zshell
Shell
2
star
31

batbridge

A collection of simulators for the Batbridge ISA written in Clojure
Clojure
2
star
32

pants.el

Front-end to the pants build system
Emacs Lisp
1
star
33

lein-template

A template for my projects
Clojure
1
star
34

cclj

A C generation DSL in CLojure
Clojure
1
star