can we use AutoBuffer here?