Use irange in torch/csrc/jit (#55716)
Summary: Pull Request resolved: https://github.com/pytorch/pytorch/pull/55716
Test Plan: Sandcastle
Reviewed By: ngimel
Differential Revision: D27690245
fbshipit-source-id: 6052b0acd792a9527d131822453a17cdb7ae3ba5