Remove some uneccesary allocations