It doesn't make any sense to convert any arbitrary recursion into tail called optimized.
If the recursion can be tail called optimized then yes the loop is the optimized performant implementation.
But if the recursion fundamentally utilizes the call stack then the reverse is actually true. The recursion is now the performant implementation of a for loop. So a loop conversion optimization actually doesn't make sense here. That's partly why a compiler won't optimize this.
Why? Because in recursion you utilize the call stack, in the for loop you're going to create a heap allocated stack and allocate on it repeatedly. Allocation slows down the iterations.
The only advantage of the for loop in this case is that there won't be stack overflow, but overall the recursive version will actually be faster.