[flang][cuda] Adapt ExternalNameConversion to work in gpu module (#117039)
[llvm-project.git] / clang / test / CodeGenOpenCL / intel-subgroups-avc-ext-types.cl
blob49e1eaf91fdd23999aa0461cdeb44bd885cade63
1 // RUN: %clang_cc1 %s -triple spir-unknown-unknown -cl-std=CL1.2 -cl-ext=+cl_intel_device_side_avc_motion_estimation -emit-llvm -o - -O0 | FileCheck %s
3 // CHECK: store target("spirv.AvcImePayloadINTEL") zeroinitializer,
4 // CHECK: store target("spirv.AvcRefPayloadINTEL") zeroinitializer,
5 // CHECK: store target("spirv.AvcSicPayloadINTEL") zeroinitializer,
7 // CHECK: store target("spirv.AvcImeResultINTEL") zeroinitializer,
8 // CHECK: store target("spirv.AvcRefResultINTEL") zeroinitializer,
9 // CHECK: store target("spirv.AvcSicResultINTEL") zeroinitializer,
11 // CHECK: store target("spirv.AvcImeResultSingleReferenceStreamoutINTEL") zeroinitializer,
12 // CHECK: store target("spirv.AvcImeResultDualReferenceStreamoutINTEL") zeroinitializer,
13 // CHECK: store target("spirv.AvcImeSingleReferenceStreaminINTEL") zeroinitializer,
14 // CHECK: store target("spirv.AvcImeDualReferenceStreaminINTEL") zeroinitializer,
16 // CHECK: store target("spirv.AvcImePayloadINTEL") zeroinitializer,
17 // CHECK: store target("spirv.AvcRefPayloadINTEL") zeroinitializer,
18 // CHECK: store target("spirv.AvcSicPayloadINTEL") zeroinitializer,
20 // CHECK: store target("spirv.AvcImeResultINTEL") zeroinitializer,
21 // CHECK: store target("spirv.AvcRefResultINTEL") zeroinitializer,
22 // CHECK: store target("spirv.AvcSicResultINTEL") zeroinitializer,
24 // CHECK: store target("spirv.AvcImeResultSingleReferenceStreamoutINTEL") zeroinitializer,
25 // CHECK: store target("spirv.AvcImeResultDualReferenceStreamoutINTEL") zeroinitializer,
26 // CHECK: store target("spirv.AvcImeSingleReferenceStreaminINTEL") zeroinitializer,
27 // CHECK: store target("spirv.AvcImeDualReferenceStreaminINTEL") zeroinitializer,
29 #pragma OPENCL EXTENSION cl_intel_device_side_avc_motion_estimation : enable
31 // Using 0x0 directly allows us not to include opencl-c.h header and not to
32 // redefine all of these CLK_AVC_*_INTITIALIZE_INTEL macro. '0x0' value must
33 // be in sync with ones defined in opencl-c.h
35 void foo() {
36 intel_sub_group_avc_mce_payload_t payload_mce; // No literal initializer for mce types
37 intel_sub_group_avc_ime_payload_t payload_ime = 0x0;
38 intel_sub_group_avc_ref_payload_t payload_ref = 0x0;
39 intel_sub_group_avc_sic_payload_t payload_sic = 0x0;
41 intel_sub_group_avc_mce_result_t result_mce; // No literal initializer for mce types
42 intel_sub_group_avc_ime_result_t result_ime = 0x0;
43 intel_sub_group_avc_ref_result_t result_ref = 0x0;
44 intel_sub_group_avc_sic_result_t result_sic = 0x0;
46 intel_sub_group_avc_ime_result_single_reference_streamout_t sstreamout = 0x0;
47 intel_sub_group_avc_ime_result_dual_reference_streamout_t dstreamout = 0x0;
48 intel_sub_group_avc_ime_single_reference_streamin_t sstreamin = 0x0;
49 intel_sub_group_avc_ime_dual_reference_streamin_t dstreamin = 0x0;
51 // Initialization with initializer list was supported in the first version
52 // of the extension. So we check for backward compatibility here.
53 intel_sub_group_avc_ime_payload_t payload_ime_list = {0};
54 intel_sub_group_avc_ref_payload_t payload_ref_list = {0};
55 intel_sub_group_avc_sic_payload_t payload_sic_list = {0};
57 intel_sub_group_avc_ime_result_t result_ime_list = {0};
58 intel_sub_group_avc_ref_result_t result_ref_list = {0};
59 intel_sub_group_avc_sic_result_t result_sic_list = {0};
61 intel_sub_group_avc_ime_result_single_reference_streamout_t sstreamout_list = {0};
62 intel_sub_group_avc_ime_result_dual_reference_streamout_t dstreamout_list = {0};
63 intel_sub_group_avc_ime_single_reference_streamin_t sstreamin_list = {0};
64 intel_sub_group_avc_ime_dual_reference_streamin_t dstreamin_list = {0};