Fix thread marking on dummy roots