Implementing primes using unboxed vectors