Updated GC so it accounts for class variables.