brintos

brintos / llvm-project-archived public Read only

0
0
Text · 787 B · 77a4fa0 Raw
22 lines · plain
1// RUN: mlir-opt %s \2// RUN:  | mlir-opt -gpu-lower-to-nvvm-pipeline="cubin-chip=sm_80 ptxas-cmd-options='-v --register-usage-level=8' allow-pattern-rollback=0" -debug-only=serialize-to-binary \3// RUN:  2>&1 | FileCheck %s4 5func.func @host_function(%arg0 : f32, %arg1 : memref<?xf32>) {6    %cst = arith.constant 1 : index7    %c0 = arith.constant 0 : index8    %cst2 = memref.dim %arg1, %c0 : memref<?xf32>9    10    gpu.launch blocks(%bx, %by, %bz) in (%grid_x = %cst, %grid_y = %cst, %grid_z = %cst)11                threads(%tx, %ty, %tz) in (%block_x = %cst2, %block_y = %cst, %block_z = %cst) {12        memref.store %arg0, %arg1[%tx] : memref<?xf32>13        gpu.terminator14    }15 16    return17}18 19// CHECK: ptxas -arch sm_8020// CHECK-SAME: -v 21// CHECK-SAME: --register-usage-level=822