PHP: generators / primes