That’s not type-stable. x = [@SMatrix randn(5,5) for i in 1:10000] is a type stable way to compute an array of random SMatrices, and that nearly doubles the speed of the computation and removes the allocations down to 2, i.e. from:
2.549 ms (29496 allocations: 1.44 MiB)
to
1.469 ms (2 allocations: 390.70 KiB)
for me. Still a nice performance for Grassmann.jl, but seems to be <2x.