try allocating in a thread pool