some progress on keeping track of modified vars