Small perf optimization