optimization. local buffer