first implementation garbage collector