|
| 1 | +;=========================== begin_copyright_notice ============================ |
| 2 | +; |
| 3 | +; Copyright (C) 2025 Intel Corporation |
| 4 | +; |
| 5 | +; SPDX-License-Identifier: MIT |
| 6 | +; |
| 7 | +;============================ end_copyright_notice ============================= |
| 8 | + |
| 9 | +; COM: ;;;;;;;;;; RUNNERS ;;;;;;;;;; |
| 10 | + |
| 11 | +; RUN: %llc_typed_ptrs %s -march=genx64 -mcpu=XeHPC -vc-skip-ocl-runtime-info -finalizer-opts='-dumpcommonisa -isaasmToConsole' -o /dev/null \ |
| 12 | +; RUN: | FileCheck %s |
| 13 | +; RUN: %llc_opaque_ptrs %s -march=genx64 -mcpu=XeHPC -vc-skip-ocl-runtime-info -finalizer-opts='-dumpcommonisa -isaasmToConsole' -o /dev/null \ |
| 14 | +; RUN: | FileCheck %s |
| 15 | + |
| 16 | +; COM: ;;;;;;;;;; CHECKERS ;;;;;;;;;; |
| 17 | + |
| 18 | +; CHECK-DAG: .decl [[DST:V[^ ]+]] v_type=G type=w num_elts=16 |
| 19 | +; CHECK: mov (M1, 8) [[DST]](0,0)<2> V{{[0-9]+}}(0,0)<1;1,0> |
| 20 | + |
| 21 | +; COM: ;;;;;;;;;; KERNEL ;;;;;;;;;; |
| 22 | + |
| 23 | + |
| 24 | +declare <16 x i16> @llvm.genx.wrregioni.v16i16.v8i16.i16.v8i1(<16 x i16>, <8 x i16>, i32, i32, i32, i16, i32, <8 x i1>) |
| 25 | + |
| 26 | +declare void @llvm.genx.svm.scatter.v8i1.v8i64.v16i16(<8 x i1>, i32, <8 x i64>, <16 x i16>) |
| 27 | + |
| 28 | +define spir_kernel void @_ZTSZ4testIN4sycl3_V13ext6oneapi8bfloat16EEbNS1_5queueEiEUlvE_(i8 addrspace(4)* %_arg_Mem, i64 %impl.arg.private.base) #0 { |
| 29 | +entry: |
| 30 | + %call1.i.i.i.esimd = tail call <8 x float> @llvm.vc.internal.cast.from.bf16.v8f32.v8i16(<8 x i16> zeroinitializer) |
| 31 | + br label %for.body.i |
| 32 | + |
| 33 | +for.body.i: ; preds = %for.body.i, %entry |
| 34 | + %Vec.i.sroa.0.01 = phi <8 x i16> [ zeroinitializer, %entry ], [ %bf164, %for.body.i ] |
| 35 | + %call1.i14.i.i.esimd = tail call <8 x float> @llvm.vc.internal.cast.from.bf16.v8f32.v8i16(<8 x i16> %Vec.i.sroa.0.01) |
| 36 | + %bf164 = tail call <8 x i16> @llvm.vc.internal.cast.to.bf16.v8i16.v8f32(<8 x float> %call1.i14.i.i.esimd) |
| 37 | + br i1 undef, label %_ZZ4testIN4sycl3_V13ext6oneapi8bfloat16EEbNS1_5queueEiENKUlvE_clEv.exit, label %for.body.i |
| 38 | + |
| 39 | +_ZZ4testIN4sycl3_V13ext6oneapi8bfloat16EEbNS1_5queueEiENKUlvE_clEv.exit: ; preds = %for.body.i |
| 40 | + %call5.i.i.esimd = tail call <16 x i16> @llvm.genx.wrregioni.v16i16.v8i16.i16.v8i1(<16 x i16> undef, <8 x i16> %bf164, i32 0, i32 8, i32 2, i16 0, i32 0, <8 x i1> <i1 true, i1 true, i1 true, i1 true, i1 true, i1 true, i1 true, i1 true>) |
| 41 | + tail call void @llvm.genx.svm.scatter.v8i1.v8i64.v16i16(<8 x i1> zeroinitializer, i32 0, <8 x i64> zeroinitializer, <16 x i16> %call5.i.i.esimd) |
| 42 | + ret void |
| 43 | +} |
| 44 | + |
| 45 | +declare <8 x float> @llvm.vc.internal.cast.from.bf16.v8f32.v8i16(<8 x i16>) |
| 46 | + |
| 47 | +declare <8 x i16> @llvm.vc.internal.cast.to.bf16.v8i16.v8f32(<8 x float>) |
| 48 | + |
| 49 | +; uselistorder directives |
| 50 | +uselistorder <8 x float> (<8 x i16>)* @llvm.vc.internal.cast.from.bf16.v8f32.v8i16, { 1, 0 } |
| 51 | + |
| 52 | +attributes #0 = { "CMGenxMain" } |
| 53 | + |
| 54 | +!genx.kernels = !{!0} |
| 55 | +!genx.kernel.internal = !{!5} |
| 56 | + |
| 57 | +!0 = !{void (i8 addrspace(4)*, i64)* @_ZTSZ4testIN4sycl3_V13ext6oneapi8bfloat16EEbNS1_5queueEiEUlvE_, !"_ZTSZ4testIN4sycl3_V13ext6oneapi8bfloat16EEbNS1_5queueEiEUlvE_", !1, i32 0, !2, !3, !4, i32 0} |
| 58 | +!1 = !{i32 0, i32 96} |
| 59 | +!2 = !{i32 136, i32 128} |
| 60 | +!3 = !{i32 0} |
| 61 | +!4 = !{!"svmptr_t", !""} |
| 62 | +!5 = !{void (i8 addrspace(4)*, i64)* @_ZTSZ4testIN4sycl3_V13ext6oneapi8bfloat16EEbNS1_5queueEiEUlvE_, !6, !7, !8, !9} |
| 63 | +!6 = !{i32 0, i32 0} |
| 64 | +!7 = !{i32 0, i32 1} |
| 65 | +!8 = !{} |
| 66 | +!9 = !{i32 255, i32 255} |
0 commit comments