(i: R.Tensor((), "int32"), s: R.Tensor((2, 3), "float32"))
| 220 | def main(x: R.Tensor((2, 3), "float32")) -> R.Tensor: |
| 221 | @R.function |
| 222 | def while_loop(i: R.Tensor((), "int32"), s: R.Tensor((2, 3), "float32")) -> R.Tensor( |
| 223 | (2, 3), "float32" |
| 224 | ): |
| 225 | cond: R.Tensor((), "bool") = R.call_pure_packed( |
| 226 | "test.vm.less", i, R.const(10), sinfo_args=(R.Tensor((), dtype="bool")) |
| 227 | ) |
| 228 | c: R.Tensor((), "int32") = R.const(1, dtype="int32") |
| 229 | if cond: |
| 230 | new_i: R.Tensor((), "int32") = R.add(i, c) |
| 231 | new_s: R.Tensor((2, 3), "float32") = R.add(s, x) |
| 232 | r: R.Tensor((2, 3), "float32") = while_loop(new_i, new_s) |
| 233 | else: |
| 234 | r: R.Tensor((2, 3), "float32") = s |
| 235 | return r |
| 236 | |
| 237 | gv: R.Tensor((2, 3), "float32") = while_loop(R.const(0), x) |
| 238 | return gv |
nothing calls this directly
no test coverage detected