Most of the posts in this meme have talked about what makes their language fast, this is the first I’ve seen that talks about what makes the language slow. And it does it in an interesting, insightful way. Kudos!
~/Downloads> time -l wc big.txt
128457 1095695 6488666 big.txt
0.03 real 0.02 user 0.00 sys
1871872 maximum resident set size
0 average shared memory size
0 average unshared data size
0 average unshared stack size
467 page reclaims
1 page faults
0 swaps
0 block input operations
0 block output operations
0 messages sent
0 messages received
0 signals received
4 voluntary context switches
54 involuntary context switches
~/Downloads> time -l racket wc.rkt big.txt
128457 1095695 6488666 big.txt
0.17 real 0.14 user 0.02 sys
33656832 maximum resident set size
0 average shared memory size
0 average unshared data size
0 average unshared stack size
9269 page reclaims
0 page faults
0 swaps
0 block input operations
0 block output operations
0 messages sent
0 messages received
0 signals received
0 voluntary context switches
592 involuntary context switches
Though the comparison is a little unfair to Racket here since most of that time is startup time for the Racket VM and the run time is short enough that the JIT doesn’t really get to kick in. Are the larger test files mentioned in the Go and Haskell posts available anywhere? I’d like to see how this program does against those.
I did run ‘raco make’. ‘raco exe’ wouldn’t help improve the VM startup time significantly, though, because all it does is pack the runtime along with the code.
Most of the posts in this meme have talked about what makes their language fast, this is the first I’ve seen that talks about what makes the language slow. And it does it in an interesting, insightful way. Kudos!
Glad it was worth the read! I was a bit worried it might have been a bit too detailed.
No it’s a great article! The internet doesn’t lack for articles lacking in detail, but articles like this are a rarity.
How closely does the gabage collector mirror the paper that introduced that introduced it?
Inko implements all of Immix, but with some differences/additions:
Great write-up! It made me curious about how Racket would fare.
This 40 line Racket program is within about an order of magnitude of the
wc
implementation on my machine:Though the comparison is a little unfair to Racket here since most of that time is startup time for the Racket VM and the run time is short enough that the JIT doesn’t really get to kick in. Are the larger test files mentioned in the Go and Haskell posts available anywhere? I’d like to see how this program does against those.
You should get better start-up times with
raco make wc.rkt
and (optionally? I forget)raco exe -o rkt-wc wc.rkt
.I did run ‘raco make’. ‘raco exe’ wouldn’t help improve the VM startup time significantly, though, because all it does is pack the runtime along with the code.
I think most of these posts (unfortunately) don’t publish what input files they use.