remove allocations by using thread-local data structures or reuse the same variables during repetitive operations