[Mlir-commits] [mlir] [MLIR][GPU] Support synchronous gpu.alloc and gpu.dealloc in gpu-to-llvm (PR #191661)

Durgadoss R llvmlistbot at llvm.org
Tue May 19 01:21:58 PDT 2026


durga4github wrote:

> @durga4github thanks for taking a look. Here are the results of tests on my Ampere-based workstation:
> 
> ```
>jhoberock at jhoberock-dt3 in llvm-project-fork  gpu-sync-alloc-dealloc [?] via 🐍 v3.12.3 
> ❯   build/bin/llvm-lit mlir/test/Integration/GPU/CUDA/
> -- Testing: 37 tests, 32 workers --
> UNSUPPORTED: MLIR :: Integration/GPU/CUDA/sm90/tma_load_64x64_swizzle128b.mlir (1 of 37)
> UNSUPPORTED: MLIR :: Integration/GPU/CUDA/sm90/transform-dialect/tma_load_64x8_8x128_noswizzle-transform.mlir (2 of 37)
> UNSUPPORTED: MLIR :: Integration/GPU/CUDA/sm90/tma_load_64x8_8x128_noswizzle.mlir (3 of 37)
> UNSUPPORTED: MLIR :: Integration/GPU/CUDA/sm90/python/tools/nvgpucompiler.py (4 of 37)
> UNSUPPORTED: MLIR :: Integration/GPU/CUDA/sm90/python/matmul.py (5 of 37)
> UNSUPPORTED: MLIR :: Integration/GPU/CUDA/sm90/tma_load_128x64_swizzle128b.mlir (6 of 37)
> UNSUPPORTED: MLIR :: Integration/GPU/CUDA/sm90/tma_load_128x128_stride_noswizzle.mlir (7 of 37)
> UNSUPPORTED: MLIR :: Integration/GPU/CUDA/sm90/python/tools/matmulBuilder.py (8 of 37)
> UNSUPPORTED: MLIR :: Integration/GPU/CUDA/sm90/gemm_f32_f16_f16_128x128x128.mlir (9 of 37)
> UNSUPPORTED: MLIR :: Integration/GPU/CUDA/sm90/cga_cluster.mlir (10 of 37)
> UNSUPPORTED: MLIR :: Integration/GPU/CUDA/sm90/gemm_pred_f32_f16_f16_128x128x128.mlir (11 of 37)
> PASS: MLIR :: Integration/GPU/CUDA/module-to-binary-compiler-log.mlir (12 of 37)
> PASS: MLIR :: Integration/GPU/CUDA/command-line-arg.mlir (13 of 37)
> PASS: MLIR :: Integration/GPU/CUDA/dump-ptx.mlir (14 of 37)
> PASS: MLIR :: Integration/GPU/CUDA/dump-sass.mlir (15 of 37)
> PASS: MLIR :: Integration/GPU/CUDA/alloc-host-shared.mlir (16 of 37)
> PASS: MLIR :: Integration/GPU/CUDA/printf.mlir (17 of 37)
> PASS: MLIR :: Integration/GPU/CUDA/concurrent-kernels.mlir (18 of 37)
> PASS: MLIR :: Integration/GPU/CUDA/TensorCore/wmma-matmul-f32.mlir (19 of 37)
> PASS: MLIR :: Integration/GPU/CUDA/TensorCore/wmma-matmul-f32-bare-ptr.mlir (20 of 37)
> PASS: MLIR :: Integration/GPU/CUDA/all-reduce-op.mlir (21 of 37)
> PASS: MLIR :: Integration/GPU/CUDA/shuffle.mlir (22 of 37)
> PASS: MLIR :: Integration/GPU/CUDA/all-reduce-minsi.mlir (23 of 37)
> PASS: MLIR :: Integration/GPU/CUDA/all-reduce-or.mlir (24 of 37)
> PASS: MLIR :: Integration/GPU/CUDA/all-reduce-region.mlir (25 of 37)
> PASS: MLIR :: Integration/GPU/CUDA/all-reduce-xor.mlir (26 of 37)
> PASS: MLIR :: Integration/GPU/CUDA/assert.mlir (27 of 37)
> PASS: MLIR :: Integration/GPU/CUDA/multiple-all-reduce.mlir (28 of 37)
> PASS: MLIR :: Integration/GPU/CUDA/TensorCore/sm80/wmma-matmul-f64.mlir (29 of 37)
> PASS: MLIR :: Integration/GPU/CUDA/TensorCore/sm80/transform-mma-sync-matmul-f16-f16-accum.mlir (30 of 37)
> PASS: MLIR :: Integration/GPU/CUDA/two-modules.mlir (31 of 37)
> PASS: MLIR :: Integration/GPU/CUDA/all-reduce-maxsi.mlir (32 of 37)
> PASS: MLIR :: Integration/GPU/CUDA/gpu-to-cubin.mlir (33 of 37)
> PASS: MLIR :: Integration/GPU/CUDA/TensorCore/wmma-matmul-f16.mlir (34 of 37)
> PASS: MLIR :: Integration/GPU/CUDA/TensorCore/sm80/transform-mma-sync-matmul-f32.mlir (35 of 37)
> PASS: MLIR :: Integration/GPU/CUDA/async.mlir (36 of 37)
> PASS: MLIR :: Integration/GPU/CUDA/all-reduce-and.mlir (37 of 37)
> 
> Testing Time: 5.25s
> 
> Total Discovered Tests: 37
>   Unsupported: 11 (29.73%)
>   Passed     : 26 (70.27%)
> 
>jhoberock at jhoberock-dt3 in llvm-project-fork  gpu-sync-alloc-dealloc [?] via 🐍 v3.12.3 took 5s 
> ❯   build/bin/llvm-lit mlir/test/Examples/
> -- Testing: 90 tests, 32 workers --
> PASS: MLIR :: Examples/transform/Ch2/invalid.mlir (1 of 90)
> PASS: MLIR :: Examples/transform/Ch2/ops.mlir (2 of 90)
> PASS: MLIR :: Examples/Toy/Ch5/affine-lowering.mlir (3 of 90)
> PASS: MLIR :: Examples/transform/Ch4/multiple.mlir (4 of 90)
> PASS: MLIR :: Examples/mlir-opt/loop_fusion_default.mlir (5 of 90)
> PASS: MLIR :: Examples/transform/Ch4/features.mlir (6 of 90)
> PASS: MLIR :: Examples/transform-opt/external-def.mlir (7 of 90)
> PASS: MLIR :: Examples/Toy/Ch7/affine-lowering.mlir (8 of 90)
> PASS: MLIR :: Examples/transform-opt/pass.mlir (9 of 90)
> PASS: MLIR :: Examples/Toy/Ch6/affine-lowering.mlir (10 of 90)
> PASS: MLIR :: Examples/Toy/Ch7/invalid.mlir (11 of 90)
> PASS: MLIR :: Examples/mlir-opt/loop_fusion.mlir (12 of 90)
> PASS: MLIR :: Examples/Toy/Ch7/llvm-lowering.mlir (13 of 90)
> PASS: MLIR :: Examples/Toy/Ch7/transpose_transpose.toy (14 of 90)
> PASS: MLIR :: Examples/transform-opt/syntax-error.mlir (15 of 90)
> PASS: MLIR :: Examples/transform/Ch1/invalidation-2.mlir (16 of 90)
> PASS: MLIR :: Examples/mlir-opt/loop_fusion_options.mlir (17 of 90)
> PASS: MLIR :: Examples/transform/Ch3/invalid.mlir (18 of 90)
> PASS: MLIR :: Examples/Toy/Ch7/struct-codegen.toy (19 of 90)
> PASS: MLIR :: Examples/Toy/Ch6/llvm-lowering.mlir (20 of 90)
> PASS: MLIR :: Examples/transform/Ch3/ops.mlir (21 of 90)
> PASS: MLIR :: Examples/Toy/Ch7/codegen.toy (22 of 90)
> PASS: MLIR :: Examples/Toy/Ch6/transpose_transpose.toy (23 of 90)
> PASS: MLIR :: Examples/mlir-opt/ctlz.mlir (24 of 90)
> PASS: MLIR :: Examples/Toy/Ch7/shape_inference.mlir (25 of 90)
> PASS: MLIR :: Examples/Toy/Ch6/invalid.mlir (26 of 90)
> PASS: MLIR :: Examples/mlir-opt/ctlz_pipeline.mlir (27 of 90)
> PASS: MLIR :: Examples/Toy/Ch6/codegen.toy (28 of 90)
> PASS: MLIR :: Examples/Toy/Ch6/trivial_reshape.toy (29 of 90)
> PASS: MLIR :: Examples/Toy/Ch7/struct-opt.mlir (30 of 90)
> PASS: MLIR :: Examples/Toy/Ch6/shape_inference.mlir (31 of 90)
> PASS: MLIR :: Examples/Toy/Ch7/trivial_reshape.toy (32 of 90)
> PASS: MLIR :: Examples/Toy/Ch7/ast.toy (33 of 90)
> PASS: MLIR :: Examples/Toy/Ch5/shape_inference.mlir (34 of 90)
> PASS: MLIR :: Examples/Toy/Ch7/struct-ast.toy (35 of 90)
> PASS: MLIR :: Examples/Toy/Ch7/scalar.toy (36 of 90)
> PASS: MLIR :: Examples/transform/Ch2/sequence.mlir (37 of 90)
> PASS: MLIR :: Examples/Toy/Ch7/empty.toy (38 of 90)
> PASS: MLIR :: Examples/transform/Ch1/invalidation-1.mlir (39 of 90)
> PASS: MLIR :: Examples/Toy/Ch4/trivial_reshape.toy (40 of 90)
> PASS: MLIR :: Examples/Toy/Ch2/codegen.toy (41 of 90)
> PASS: MLIR :: Examples/Toy/Ch6/empty.toy (42 of 90)
> PASS: MLIR :: Examples/Toy/Ch6/ast.toy (43 of 90)
> PASS: MLIR :: Examples/Toy/Ch4/codegen.toy (44 of 90)
> PASS: MLIR :: Examples/Toy/Ch4/shape_inference.mlir (45 of 90)
> PASS: MLIR :: Examples/Toy/Ch2/scalar.toy (46 of 90)
> PASS: MLIR :: Examples/Toy/Ch3/codegen.toy (47 of 90)
> PASS: MLIR :: Examples/Toy/Ch5/trivial_reshape.toy (48 of 90)
> PASS: MLIR :: Examples/Toy/Ch5/transpose_transpose.toy (49 of 90)
> PASS: MLIR :: Examples/Toy/Ch4/transpose_transpose.toy (50 of 90)
> PASS: MLIR :: Examples/Toy/Ch3/transpose_transpose.toy (51 of 90)
> PASS: MLIR :: Examples/Toy/Ch5/scalar.toy (52 of 90)
> PASS: MLIR :: Examples/Toy/Ch3/scalar.toy (53 of 90)
> PASS: MLIR :: Examples/Toy/Ch4/ast.toy (54 of 90)
> PASS: MLIR :: Examples/Toy/Ch4/scalar.toy (55 of 90)
> PASS: MLIR :: Examples/Toy/Ch5/ast.toy (56 of 90)
> PASS: MLIR :: Examples/Toy/Ch6/jit.toy (57 of 90)
> PASS: MLIR :: Examples/Toy/Ch3/trivial_reshape.toy (58 of 90)
> PASS: MLIR :: Examples/Toy/Ch5/codegen.toy (59 of 90)
> UNSUPPORTED: MLIR :: Examples/NVGPU/tools/nvdsl.py (60 of 90)
> UNSUPPORTED: MLIR :: Examples/NVGPU/tools/nvgpucompiler.py (61 of 90)
> PASS: MLIR :: Examples/transform/Ch4/sequence.mlir (62 of 90)
> PASS: MLIR :: Examples/Toy/Ch4/invalid.mlir (63 of 90)
> PASS: MLIR :: Examples/transform/Ch3/sequence.mlir (64 of 90)
> PASS: MLIR :: Examples/Toy/Ch1/ast.toy (65 of 90)
> PASS: MLIR :: Examples/Toy/Ch6/scalar.toy (66 of 90)
> PASS: MLIR :: Examples/Toy/Ch4/empty.toy (67 of 90)
> UNSUPPORTED: MLIR :: Examples/standalone/test.wheel.toy (68 of 90)
> PASS: MLIR :: Examples/Toy/Ch2/empty.toy (69 of 90)
> PASS: MLIR :: Examples/Toy/Ch2/ast.toy (70 of 90)
> PASS: MLIR :: Examples/Toy/Ch3/ast.toy (71 of 90)
> PASS: MLIR :: Examples/Toy/Ch3/empty.toy (72 of 90)
> PASS: MLIR :: Examples/Toy/Ch3/invalid.mlir (73 of 90)
> PASS: MLIR :: Examples/Toy/Ch2/invalid.mlir (74 of 90)
> PASS: MLIR :: Examples/Toy/Ch1/empty.toy (75 of 90)
> PASS: MLIR :: Examples/Toy/Ch5/invalid.mlir (76 of 90)
> PASS: MLIR :: Examples/Toy/Ch5/empty.toy (77 of 90)
> PASS: MLIR :: Examples/Toy/Ch7/jit.toy (78 of 90)
> PASS: MLIR :: Examples/transform/Ch1/sequence.mlir (79 of 90)
> PASS: MLIR :: Examples/transform-opt/external-decl.mlir (80 of 90)
> PASS: MLIR :: Examples/NVGPU/Ch2.py (81 of 90)
> PASS: MLIR :: Examples/NVGPU/Ch0.py (82 of 90)
> PASS: MLIR :: Examples/NVGPU/Ch3.py (83 of 90)
> PASS: MLIR :: Examples/transform-opt/empty.mlir (84 of 90)
> PASS: MLIR :: Examples/NVGPU/Ch5.py (85 of 90)
> PASS: MLIR :: Examples/transform-opt/self-contained.mlir (86 of 90)
> PASS: MLIR :: Examples/NVGPU/Ch1.py (87 of 90)
> PASS: MLIR :: Examples/NVGPU/Ch4.py (88 of 90)
> PASS: MLIR :: Examples/standalone/test.toy (89 of 90)
> PASS: MLIR :: Examples/transform/ChH/full.mlir (90 of 90)
> 
> Testing Time: 0.98s
> 
> Total Discovered Tests: 90
>   Unsupported:  3 (3.33%)
>   Passed     : 87 (96.67%)
> ```

Thanks @jaredhoberock. I am also interested in the sm90 test results. Would it be possible for you to give them a try on an sm90 machine?

https://github.com/llvm/llvm-project/pull/191661


More information about the Mlir-commits mailing list