FEAT: Optimize some edit operations for INPUT.

Optimize append, move and delete at tail.