fix stack rewinding bug, and add life test and benchmark