Hi,
I would say this is caused by the “No free lunch theorem” 
This is a rather fundamental limitation of AD I’m afraid.
The issue you have here is thatall your outs and inputs are dependent. And so all the gradient “flowing” for one will flow the same way as the ones flowing for another. And so you get the sum.
Since all you inputs are actually the same Tensor, they all get the sum and you get the same result for each of them.
The solution here would be to use different input Tensors for each forward so that they are independent. But then you will do many times the same forward just to be able to do the same thing as the for-loop but in a single backward call.