Using a nice Pure Nix Flake now, implement Koka-style rb-tree test (only running on 100 instead of 42,000,000 - .06s compiled, 40m54s interpreted!!!), also a small fact to test loops - spoiler alert we need tail-call-elimination

This commit is contained in:
Nathan Braswell
2022-05-09 23:42:39 -04:00
parent 20d554dfe6
commit a966c0c0ba
12 changed files with 187 additions and 95 deletions

52
flake.nix Normal file
View File

@@ -0,0 +1,52 @@
{
description = "Env for Kraken and the extacted Koka bencmarks";
inputs = {
#flake.lock pins a particular version of 21.11 that has non-broken Swift
nixpkgs.url = "nixpkgs/nixos-21.11";
#nixpkgs.url = "github:NixOS/nixpkgs";
# Pure-er, so we don't have to mess with the --impure flag
moz_overlay.url = "github:oxalica/rust-overlay";
#moz_overlay.url = "github:mozilla/nixpkgs-mozilla";
flake-utils.url = "github:numtide/flake-utils";
};
outputs = { self, nixpkgs, moz_overlay, flake-utils }:
(flake-utils.lib.eachDefaultSystem (system:
let
pkgs = import nixpkgs {
inherit system;
overlays = [ moz_overlay.overlay ];
};
in {
devShell = pkgs.mkShell {
buildInputs = with pkgs; [
chicken
#gambit
gambit-unstable
chez
wabt
wasmtime
wasm3
wasmer
leiningen
clang
kakoune
hyperfine
(rust-bin.stable.latest.default.override {
targets = [ "wasm32-wasi" ];
})
cmake
stack (haskellPackages.ghcWithPackages (p: [p.parallel]))
koka
ocaml
jdk
swift
];
};
}
));
}