Add support for sub profiles in threads