(shape: R.Shape(["m", "n"]))
| 42 | class Expected: |
| 43 | @R.function(pure=False) |
| 44 | def main(shape: R.Shape(["m", "n"])): # type: ignore |
| 45 | m = T.int64() |
| 46 | n = T.int64() |
| 47 | storage: R.Object = R.call_packed( |
| 48 | "runtime.disco.cuda_ipc.alloc_storage", |
| 49 | R.shape([m, n]), |
| 50 | R.dtype("float16"), |
| 51 | sinfo_args=(R.Object,), |
| 52 | ) |
| 53 | alloc: R.Tensor((m, n), dtype="float16") = R.memory.alloc_tensor( # type: ignore |
| 54 | storage, R.prim_value(0), R.shape([m, n]), R.dtype("float16") |
| 55 | ) |
| 56 | return alloc |
| 57 | |
| 58 | mod = relax.transform.LowerGPUIPCAllocStorage()(Module) |
| 59 | tvm.ir.assert_structural_equal(mod, Expected) |
nothing calls this directly
no test coverage detected