Stack cleanup

@hemantkr please review