EFS: better valid, ported to SIMD, cleaned up code