Moderate setId and openBytes performance improvements