code cleanup, changes thread composite dir to be size-determined