Skip to content

Commit

Permalink
Fixup test
Browse files Browse the repository at this point in the history
  • Loading branch information
vmaksimo committed Jun 17, 2024
1 parent d10135c commit 1339812
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions test/transcoding/ptr_diff.ll
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@
; RUN: FileCheck < %t.spt %s --check-prefix=CHECK-SPIRV
; RUN: spirv-val %t.spv

; RUN: llvm-spirv -r %t.spv -o %t.rev.bc
; RUN: llvm-dis %t.rev.bc
; RUN: llvm-spirv -r --opaque-pointers %t.spv -o %t.rev.bc
; RUN: llvm-dis -opaque-pointers=1 %t.rev.bc
; RUN: FileCheck < %t.rev.ll %s --check-prefix=CHECK-LLVM

; CHECK-ERROR: RequiresVersion: Cannot fulfill SPIR-V version restriction:
Expand All @@ -32,10 +32,10 @@ define spir_kernel void @test(float %a) local_unnamed_addr #0 {
entry:
%0 = alloca float, align 4
store float %a, float* %0, align 4
; CHECK-LLVM: %[[#Arg1:]] = ptrtoint float* %[[#]] to i64
; CHECK-LLVM: %[[#Arg2:]] = ptrtoint float* %[[#]] to i64
; CHECK-LLVM: %[[#Arg1:]] = ptrtoint ptr %[[#]] to i64
; CHECK-LLVM: %[[#Arg2:]] = ptrtoint ptr %[[#]] to i64
; CHECK-LLVM: %[[#Sub:]] = sub i64 %[[#Arg1]], %[[#Arg2]]
; CHECK-LLVM: sdiv exact i64 %[[#Sub]], ptrtoint (i32* getelementptr (i32, i32* null, i32 1) to i64)
; CHECK-LLVM: sdiv exact i64 %[[#Sub]], ptrtoint (ptr getelementptr (i32, ptr null, i32 1) to i64)
%1 = call spir_func noundef i32 @_Z15__spirv_PtrDiff(float* %0, float* %0)
ret void
}
Expand Down

0 comments on commit 1339812

Please sign in to comment.