cleanup trace generator from elem