Count words challenge

I used @views in my function declaration, so you don’t need @view in the body of my function — all slices are views.

1 Like

Ahh that would explain it! I think the Automata code expands to basically the same loop as your code, which would explain getting the same benchmark results.

Note that they perform the benchmark by running julia foo.jl, which means it includes startup/compilation time. This probably makes the results much less interesting since they don’t reflect how Julia is actually used for performance-critical problems.

I commented on this in the PR.

2 Likes

Also, it might be worth pointing out that AbstractArray hashing was way slower than it should have been until very recently. 1.7 will be about 6x faster for hashing small Arrrays (and at least 2x faster for all AbstractArrays).

3 Likes

Ouch … as I see this is based on julia version 1.4.1

my theory: on ubuntu:20.04 - the default apt-get install julia
has a same version → Ubuntu ⛬ julia/1.4.1+dfsg-1
So this is not an official “binary”