added globals test that breaks it
removed the nasty "global lastAssignedReg; lastAssignedReg = regnum" idiom and made the genInstr() dispatch function take care of it for all cases. This makes the code cleaner and fixes bugs simultaneously (YAY!) a result "globals" test is working