added gc from old g branch