Skip to content

Instantly share code, notes, and snippets.

landin:lvish lkuper$ cabal test
Re-configuring with test suites enabled. If this fails, please run configure
manually.
Resolving dependencies...
Configuring lvish-1.1.0.3...
Building lvish-1.1.0.3...
Preprocessing library lvish-1.1.0.3...
Control/LVish/SchedIdempotentInternal.hs:33:0:
warning: #warning "Compiling with non-scalable deque."
Last login: Thu Dec 12 12:09:00 on console
landin:~ lkuper$ cd repos/lvars/
landin:lvars lkuper$ git pull
remote: Counting objects: 972, done.
remote: Compressing objects: 100% (494/494), done.
remote: Total 790 (delta 448), reused 598 (delta 258)
Receiving objects: 100% (790/790), 187.72 KiB, done.
Resolving deltas: 100% (448/448), completed with 51 local objects.
From github.com:iu-parfunc/lvars
abeb337..26082c1 master -> origin/master
-- | Blocks until the contents of lv are at or above one element of
-- thrshSet, then returns that one element.
getPureLVar :: (JoinSemiLattice t, Eq t, Ord t) =>
PureLVar s t -> S.Set t -> Par d s t
getPureLVar (PureLVar (WrapLVar iv)) thrshSet =
WrapPar$ LI.getLV iv globalThresh deltaThresh
where globalThresh ref _ = do
x <- readIORef ref
-- Is x above any member of thrshSet? If so, we need to
-- know which member of thrshSet it is.
use std::vec::*;
use std::str::raw::*;
fn reverse_inplace(s: &mut ~[u8]) {
let mut left = 0;
let mut right = s.len() - 1;
let middle = s.len() / 2;
while (left < middle) {
s.swap(left, right);

In our work, we have found that Redex gives us a way to quickly, easily, and rigorously express and experiment with programming language designs. For example, we work on deterministic parallel programming models. In order to mechanically prove that a model is deterministic (that is, that programs always evaluate to the same result regardless of the order of evaluation steps), we would need a full-blown theorem proving tool and a substantial amount of engineering effort. With Redex, though, we can easily evaluate a test suite of programs in every possible order and compare the results with expected results. Being able to use Redex to get the bugs out is an enormous help to our process. In this sense, Redex is a way to take a programming language design for a shakedown cruise before we try to prove anything about it -- because getting halfway through a long proof only to find that the property one is attempting to prove is false is not unlike finding out that one's boat is not seaworthy when halfway across

@lkuper
lkuper / twitter.html
Created October 7, 2013 04:27
source/_includes/asides/twitter.html
{% if site.twitter_user %}
<section>
<h1>Latest Tweets</h1>
<!-- insert your widget generated at https://twitter.com/settings/widgets here -->
</section>
{% endif %}
lkuper@lenny:~/repos/lvars/haskell/fhpc13-lvars$ cabal configure --enable-tests
Resolving dependencies...
Configuring fhpc13-lvars-0.1.0.0...
lkuper@lenny:~/repos/lvars/haskell/fhpc13-lvars$ cabal build
Building fhpc13-lvars-0.1.0.0...
Preprocessing library fhpc13-lvars-0.1.0.0...
In-place registering fhpc13-lvars-0.1.0.0...
Preprocessing test suite 'test-lvarpure' for fhpc13-lvars-0.1.0.0...
test.hs:9:2:
landin:rust lkuper$ make check
cfg: build triple x86_64-apple-darwin
cfg: host triples x86_64-apple-darwin
cfg: target triples x86_64-apple-darwin
cfg: disabling rustc optimization (CFG_DISABLE_OPTIMIZE)
cfg: host for x86_64-apple-darwin is x86_64
cfg: os for x86_64-apple-darwin is apple-darwin
cfg: using gcc
cfg: no pandoc found, omitting docs
cfg: no node found, omitting docs
lkuper@mitzi:~/repos/rust$ make check
cfg: build triple x86_64-unknown-linux-gnu
cfg: host triples x86_64-unknown-linux-gnu
cfg: target triples x86_64-unknown-linux-gnu
cfg: disabling rustc optimization (CFG_DISABLE_OPTIMIZE)
cfg: host for x86_64-unknown-linux-gnu is x86_64
cfg: os for x86_64-unknown-linux-gnu is unknown-linux-gnu
cfg: using gcc
cfg: no llnextgen found, omitting grammar-verification
cfg: including dist rules