Core: Remove some unneeded allocations