Optimization: re-use buffer