brintos

brintos / llvm-project-archived public Read only

0
0
Text · 1.8 KiB · a7c1c22 Raw
71 lines · plain
1; Test generation of _dvgpr$ symbol for an amdgpu_cs_chain function with dynamic vgprs.2 3; RUN: llc -mtriple=amdgcn-amd-amdpal -mcpu=gfx1200 < %s | FileCheck -check-prefixes=DVGPR %s4 5; Function with 0 VGPRs, which counts as 1 block.6;7; DVGPR-LABEL: func0:8; DVGPR: .set _dvgpr$func0, func0+09;10define amdgpu_cs_chain void @func0() #0 {11  ret void12}13 14; Function with 21 VGPRs, which is 2 blocks.15;16; DVGPR-LABEL: func21:17; DVGPR: .set func21.num_vgpr, 2118; DVGPR: .set _dvgpr$func21, func21+819;20define amdgpu_cs_chain void @func21(<13 x float> %arg) #0 {21  tail call void @func21(<13 x float> %arg)22  ret void23}24 25; Anonymous function with 87 VGPRs, which is 6 blocks.26;27; DVGPR: [[FUNC87:__unnamed[^:]*]]:28; DVGPR: .set [[FUNC87]].num_vgpr, 8729; DVGPR: .set _dvgpr$[[FUNC87]], [[FUNC87]]+4030;31define amdgpu_cs_chain void @0(<79 x float> %arg) #0 {32  tail call void @0(<79 x float> %arg)33  ret void34}35 36; Function with 128 VGPRs, which is 8 blocks.37;38; DVGPR-LABEL: func128:39; DVGPR: .set func128.num_vgpr, 12840; DVGPR: .set _dvgpr$func128, func128+5641;42define amdgpu_cs_chain void @func128(<120 x float> %arg) #0 {43  tail call void @func128(<120 x float> %arg)44  ret void45}46 47; Function with 79 VGPRs, which is 3 blocks with a block size of 32.48;49; DVGPR-LABEL: func79:50; DVGPR: .set func79.num_vgpr, 7951; DVGPR: .set _dvgpr$func79, func79+1652;53define amdgpu_cs_chain void @func79(<71 x float> %arg) #1 {54  tail call void @func79(<71 x float> %arg)55  ret void56}57 58; Function with 225 VGPRs, which is 8 blocks with a block size of 32.59;60; DVGPR-LABEL: func225:61; DVGPR: .set func225.num_vgpr, 22562; DVGPR: .set _dvgpr$func225, func225+5663;64define amdgpu_cs_chain void @func225(<217 x float> %arg) #1 {65  tail call void @func225(<217 x float> %arg)66  ret void67}68 69attributes #0 = { "amdgpu-dynamic-vgpr-block-size"="16" }70attributes #1 = { "amdgpu-dynamic-vgpr-block-size"="32" }71