protect gc.start with a thread lock