Skip to content

Commit

Permalink
Merge pull request #57 from tstellarAMD/mcbnt-metadata
Browse files Browse the repository at this point in the history
hsail-amdgpu-wrapper: Add range metadata to mbcnt intrinsics
  • Loading branch information
whchung committed May 7, 2016
2 parents d649442 + 9dea5d0 commit 2defb7b
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/hsail-amdgpu-wrapper.ll
Original file line number Diff line number Diff line change
Expand Up @@ -495,7 +495,7 @@ define linkonce_odr spir_func i32 @__hsail_get_num_groups(i32 %i) #5 {
; Function Attrs: alwaysinline nounwind readnone
define linkonce_odr spir_func i32 @__hsail_get_lane_id() #2 {
%1 = call i32 @llvm.amdgcn.mbcnt.lo(i32 -1, i32 0)
%2 = call i32 @llvm.amdgcn.mbcnt.hi(i32 -1, i32 %1)
%2 = call i32 @llvm.amdgcn.mbcnt.hi(i32 -1, i32 %1), !range !2
ret i32 %2
}

Expand Down Expand Up @@ -729,3 +729,4 @@ attributes #8 = { nounwind argmemonly }

!0 = !{}
!1 = !{i32 0, i32 2048}
!2 = !{i32 0, i32 64}

0 comments on commit 2defb7b

Please sign in to comment.