tests pass, impl up to 1024