Especially the .hyper method that turns a regular sequence into hyper sequence that gets processed in parallel. First 5000 prime numbers:
# single-thread, takes 14.893s
put ^∞ .grep(*.is-prime).head: 5000
# multi-threaded, takes 8.853s on my 2-core box
put ^∞ .hyper.grep(*.is-prime).head: 5000
Especially the .hyper method that turns a regular sequence into hyper sequence that gets processed in parallel. First 5000 prime numbers: