added gc.h and gc.cc