remove threading (performance increase negligible)