Index: llvm/lib/Target/AMDGPU/AMDGPUHSAMetadataStreamer.cpp =================================================================== --- llvm/lib/Target/AMDGPU/AMDGPUHSAMetadataStreamer.cpp +++ llvm/lib/Target/AMDGPU/AMDGPUHSAMetadataStreamer.cpp @@ -768,7 +768,10 @@ if (auto PtrTy = dyn_cast(Ty)) if (auto Qualifier = getAddressSpaceQualifier(PtrTy->getAddressSpace())) - Arg[".address_space"] = Arg.getDocument()->getNode(*Qualifier, /*Copy=*/true); + // Limiting address space to emit only for a certain ValueKind. + if (ValueKind == "global_buffer" || ValueKind == "dynamic_shared_pointer") + Arg[".address_space"] = Arg.getDocument()->getNode(*Qualifier, + /*Copy=*/true); if (auto AQ = getAccessQualifier(AccQual)) Arg[".access"] = Arg.getDocument()->getNode(*AQ, /*Copy=*/true); Index: llvm/test/CodeGen/AMDGPU/hsa-metadata-enqueue-kernel-v3.ll =================================================================== --- llvm/test/CodeGen/AMDGPU/hsa-metadata-enqueue-kernel-v3.ll +++ llvm/test/CodeGen/AMDGPU/hsa-metadata-enqueue-kernel-v3.ll @@ -47,16 +47,13 @@ ; CHECK-NEXT: - .offset: 24 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 32 +; CHECK-NEXT: - .offset: 32 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_hostcall_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 40 +; CHECK-NEXT: - .offset: 40 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_default_queue -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 48 +; CHECK-NEXT: - .offset: 48 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_completion_action ; CHECK: .language: OpenCL C Index: llvm/test/CodeGen/AMDGPU/hsa-metadata-from-llvm-ir-full-v3.ll =================================================================== --- llvm/test/CodeGen/AMDGPU/hsa-metadata-from-llvm-ir-full-v3.ll +++ llvm/test/CodeGen/AMDGPU/hsa-metadata-from-llvm-ir-full-v3.ll @@ -33,8 +33,7 @@ ; CHECK-NEXT: - .offset: 24 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 32 +; CHECK-NEXT: - .offset: 32 ; CHECK-NEXT: .size: 8 ; CHECK-NOT: .value_kind: hidden_default_queue ; CHECK-NOT: .value_kind: hidden_completion_action @@ -68,8 +67,7 @@ ; CHECK-NEXT: - .offset: 24 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 32 +; CHECK-NEXT: - .offset: 32 ; CHECK-NEXT: .size: 8 ; CHECK-NOT: .value_kind: hidden_default_queue ; CHECK-NOT: .value_kind: hidden_completion_action @@ -107,8 +105,7 @@ ; CHECK-NEXT: - .offset: 536 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 544 +; CHECK-NEXT: - .offset: 544 ; CHECK-NEXT: .size: 8 ; CHECK-NOT: .value_kind: hidden_default_queue ; CHECK-NOT: .value_kind: hidden_completion_action @@ -142,20 +139,16 @@ ; CHECK-NEXT: - .offset: 24 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 32 +; CHECK-NEXT: - .offset: 32 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 40 +; CHECK-NEXT: - .offset: 40 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 48 +; CHECK-NEXT: - .offset: 48 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 56 +; CHECK-NEXT: - .offset: 56 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .language: OpenCL C @@ -185,20 +178,16 @@ ; CHECK-NEXT: - .offset: 32 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 40 +; CHECK-NEXT: - .offset: 40 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 48 +; CHECK-NEXT: - .offset: 48 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 56 +; CHECK-NEXT: - .offset: 56 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 64 +; CHECK-NEXT: - .offset: 64 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .language: OpenCL C @@ -228,20 +217,16 @@ ; CHECK-NEXT: - .offset: 48 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 56 +; CHECK-NEXT: - .offset: 56 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 64 +; CHECK-NEXT: - .offset: 64 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 72 +; CHECK-NEXT: - .offset: 72 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 80 +; CHECK-NEXT: - .offset: 80 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .language: OpenCL C @@ -271,20 +256,16 @@ ; CHECK-NEXT: - .offset: 32 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 40 +; CHECK-NEXT: - .offset: 40 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 48 +; CHECK-NEXT: - .offset: 48 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 56 +; CHECK-NEXT: - .offset: 56 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 64 +; CHECK-NEXT: - .offset: 64 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .language: OpenCL C @@ -314,20 +295,16 @@ ; CHECK-NEXT: - .offset: 80 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 88 +; CHECK-NEXT: - .offset: 88 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 96 +; CHECK-NEXT: - .offset: 96 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 104 +; CHECK-NEXT: - .offset: 104 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 112 +; CHECK-NEXT: - .offset: 112 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .language: OpenCL C @@ -357,20 +334,16 @@ ; CHECK-NEXT: - .offset: 144 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 152 +; CHECK-NEXT: - .offset: 152 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 160 +; CHECK-NEXT: - .offset: 160 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 168 +; CHECK-NEXT: - .offset: 168 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 176 +; CHECK-NEXT: - .offset: 176 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .language: OpenCL C @@ -401,20 +374,16 @@ ; CHECK-NEXT: - .offset: 24 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 32 +; CHECK-NEXT: - .offset: 32 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 40 +; CHECK-NEXT: - .offset: 40 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 48 +; CHECK-NEXT: - .offset: 48 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 56 +; CHECK-NEXT: - .offset: 56 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .language: OpenCL C @@ -430,8 +399,7 @@ } ; CHECK: - .args: -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .name: a +; CHECK-NEXT: - .name: a ; CHECK-NEXT: .offset: 0 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .type_name: image2d_t @@ -445,20 +413,16 @@ ; CHECK-NEXT: - .offset: 24 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 32 +; CHECK-NEXT: - .offset: 32 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 40 +; CHECK-NEXT: - .offset: 40 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 48 +; CHECK-NEXT: - .offset: 48 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 56 +; CHECK-NEXT: - .offset: 56 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .language: OpenCL C @@ -488,20 +452,16 @@ ; CHECK-NEXT: - .offset: 24 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 32 +; CHECK-NEXT: - .offset: 32 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 40 +; CHECK-NEXT: - .offset: 40 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 48 +; CHECK-NEXT: - .offset: 48 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 56 +; CHECK-NEXT: - .offset: 56 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .language: OpenCL C @@ -517,8 +477,7 @@ } ; CHECK: - .args: -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .name: a +; CHECK-NEXT: - .name: a ; CHECK-NEXT: .offset: 0 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .type_name: queue_t @@ -532,20 +491,16 @@ ; CHECK-NEXT: - .offset: 24 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 32 +; CHECK-NEXT: - .offset: 32 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 40 +; CHECK-NEXT: - .offset: 40 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 48 +; CHECK-NEXT: - .offset: 48 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 56 +; CHECK-NEXT: - .offset: 56 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .language: OpenCL C @@ -575,20 +530,16 @@ ; CHECK-NEXT: - .offset: 24 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 32 +; CHECK-NEXT: - .offset: 32 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 40 +; CHECK-NEXT: - .offset: 40 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 48 +; CHECK-NEXT: - .offset: 48 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 56 +; CHECK-NEXT: - .offset: 56 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .language: OpenCL C @@ -618,20 +569,16 @@ ; CHECK-NEXT: - .offset: 24 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 32 +; CHECK-NEXT: - .offset: 32 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 40 +; CHECK-NEXT: - .offset: 40 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 48 +; CHECK-NEXT: - .offset: 48 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 56 +; CHECK-NEXT: - .offset: 56 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .language: OpenCL C @@ -661,20 +608,16 @@ ; CHECK-NEXT: - .offset: 48 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 56 +; CHECK-NEXT: - .offset: 56 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 64 +; CHECK-NEXT: - .offset: 64 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 72 +; CHECK-NEXT: - .offset: 72 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 80 +; CHECK-NEXT: - .offset: 80 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .language: OpenCL C @@ -704,20 +647,16 @@ ; CHECK-NEXT: - .offset: 48 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 56 +; CHECK-NEXT: - .offset: 56 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 64 +; CHECK-NEXT: - .offset: 64 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 72 +; CHECK-NEXT: - .offset: 72 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 80 +; CHECK-NEXT: - .offset: 80 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .language: OpenCL C @@ -747,20 +686,16 @@ ; CHECK-NEXT: - .offset: 32 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 40 +; CHECK-NEXT: - .offset: 40 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 48 +; CHECK-NEXT: - .offset: 48 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 56 +; CHECK-NEXT: - .offset: 56 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 64 +; CHECK-NEXT: - .offset: 64 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .language: OpenCL C @@ -800,20 +735,16 @@ ; CHECK-NEXT: - .offset: 32 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 40 +; CHECK-NEXT: - .offset: 40 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 48 +; CHECK-NEXT: - .offset: 48 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 56 +; CHECK-NEXT: - .offset: 56 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 64 +; CHECK-NEXT: - .offset: 64 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .language: OpenCL C @@ -857,20 +788,16 @@ ; CHECK-NEXT: - .offset: 40 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 48 +; CHECK-NEXT: - .offset: 48 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 56 +; CHECK-NEXT: - .offset: 56 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 64 +; CHECK-NEXT: - .offset: 64 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 72 +; CHECK-NEXT: - .offset: 72 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .language: OpenCL C @@ -903,8 +830,7 @@ ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .type_name: 'int addrspace(5)*' ; CHECK-NEXT: .value_kind: global_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .is_pipe: true +; CHECK-NEXT: - .is_pipe: true ; CHECK-NEXT: .name: c ; CHECK-NEXT: .offset: 16 ; CHECK-NEXT: .size: 8 @@ -919,20 +845,16 @@ ; CHECK-NEXT: - .offset: 40 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 48 +; CHECK-NEXT: - .offset: 48 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 56 +; CHECK-NEXT: - .offset: 56 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 64 +; CHECK-NEXT: - .offset: 64 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 72 +; CHECK-NEXT: - .offset: 72 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .language: OpenCL C @@ -951,21 +873,18 @@ ; CHECK: - .args: ; CHECK-NEXT: - .access: read_only -; CHECK-NEXT: .address_space: global ; CHECK-NEXT: .name: ro ; CHECK-NEXT: .offset: 0 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .type_name: image1d_t ; CHECK-NEXT: .value_kind: image ; CHECK-NEXT: - .access: write_only -; CHECK-NEXT: .address_space: global ; CHECK-NEXT: .name: wo ; CHECK-NEXT: .offset: 8 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .type_name: image2d_t ; CHECK-NEXT: .value_kind: image ; CHECK-NEXT: - .access: read_write -; CHECK-NEXT: .address_space: global ; CHECK-NEXT: .name: rw ; CHECK-NEXT: .offset: 16 ; CHECK-NEXT: .size: 8 @@ -980,20 +899,16 @@ ; CHECK-NEXT: - .offset: 40 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 48 +; CHECK-NEXT: - .offset: 48 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 56 +; CHECK-NEXT: - .offset: 56 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 64 +; CHECK-NEXT: - .offset: 64 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 72 +; CHECK-NEXT: - .offset: 72 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .language: OpenCL C @@ -1025,20 +940,16 @@ ; CHECK-NEXT: - .offset: 24 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 32 +; CHECK-NEXT: - .offset: 32 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 40 +; CHECK-NEXT: - .offset: 40 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 48 +; CHECK-NEXT: - .offset: 48 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 56 +; CHECK-NEXT: - .offset: 56 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .language: OpenCL C @@ -1069,20 +980,16 @@ ; CHECK-NEXT: - .offset: 24 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 32 +; CHECK-NEXT: - .offset: 32 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 40 +; CHECK-NEXT: - .offset: 40 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 48 +; CHECK-NEXT: - .offset: 48 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 56 +; CHECK-NEXT: - .offset: 56 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .language: OpenCL C @@ -1113,20 +1020,16 @@ ; CHECK-NEXT: - .offset: 24 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 32 +; CHECK-NEXT: - .offset: 32 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 40 +; CHECK-NEXT: - .offset: 40 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 48 +; CHECK-NEXT: - .offset: 48 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 56 +; CHECK-NEXT: - .offset: 56 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .language: OpenCL C @@ -1157,20 +1060,16 @@ ; CHECK-NEXT: - .offset: 24 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 32 +; CHECK-NEXT: - .offset: 32 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 40 +; CHECK-NEXT: - .offset: 40 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 48 +; CHECK-NEXT: - .offset: 48 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 56 +; CHECK-NEXT: - .offset: 56 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .language: OpenCL C @@ -1201,20 +1100,16 @@ ; CHECK-NEXT: - .offset: 24 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 32 +; CHECK-NEXT: - .offset: 32 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 40 +; CHECK-NEXT: - .offset: 40 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 48 +; CHECK-NEXT: - .offset: 48 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 56 +; CHECK-NEXT: - .offset: 56 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .language: OpenCL C @@ -1245,20 +1140,16 @@ ; CHECK-NEXT: - .offset: 24 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 32 +; CHECK-NEXT: - .offset: 32 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 40 +; CHECK-NEXT: - .offset: 40 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 48 +; CHECK-NEXT: - .offset: 48 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 56 +; CHECK-NEXT: - .offset: 56 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .language: OpenCL C @@ -1289,20 +1180,16 @@ ; CHECK-NEXT: - .offset: 24 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 32 +; CHECK-NEXT: - .offset: 32 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 40 +; CHECK-NEXT: - .offset: 40 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 48 +; CHECK-NEXT: - .offset: 48 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 56 +; CHECK-NEXT: - .offset: 56 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .language: OpenCL C @@ -1333,20 +1220,16 @@ ; CHECK-NEXT: - .offset: 24 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 32 +; CHECK-NEXT: - .offset: 32 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 40 +; CHECK-NEXT: - .offset: 40 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 48 +; CHECK-NEXT: - .offset: 48 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 56 +; CHECK-NEXT: - .offset: 56 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .language: OpenCL C @@ -1382,20 +1265,16 @@ ; CHECK-NEXT: - .offset: 24 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 32 +; CHECK-NEXT: - .offset: 32 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 40 +; CHECK-NEXT: - .offset: 40 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 48 +; CHECK-NEXT: - .offset: 48 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 56 +; CHECK-NEXT: - .offset: 56 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .language: OpenCL C @@ -1432,20 +1311,16 @@ ; CHECK-NEXT: - .offset: 24 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 32 +; CHECK-NEXT: - .offset: 32 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 40 +; CHECK-NEXT: - .offset: 40 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 48 +; CHECK-NEXT: - .offset: 48 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 56 +; CHECK-NEXT: - .offset: 56 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .language: OpenCL C @@ -1475,20 +1350,16 @@ ; CHECK-NEXT: - .offset: 24 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 32 +; CHECK-NEXT: - .offset: 32 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 40 +; CHECK-NEXT: - .offset: 40 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 48 +; CHECK-NEXT: - .offset: 48 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 56 +; CHECK-NEXT: - .offset: 56 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .language: OpenCL C @@ -1518,20 +1389,16 @@ ; CHECK-NEXT: - .offset: 32 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 40 +; CHECK-NEXT: - .offset: 40 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 48 +; CHECK-NEXT: - .offset: 48 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 56 +; CHECK-NEXT: - .offset: 56 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 64 +; CHECK-NEXT: - .offset: 64 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .language: OpenCL C @@ -1562,20 +1429,16 @@ ; CHECK-NEXT: - .offset: 24 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 32 +; CHECK-NEXT: - .offset: 32 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 40 +; CHECK-NEXT: - .offset: 40 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 48 +; CHECK-NEXT: - .offset: 48 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 56 +; CHECK-NEXT: - .offset: 56 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .language: OpenCL C @@ -1655,20 +1518,16 @@ ; CHECK-NEXT: - .offset: 56 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 64 +; CHECK-NEXT: - .offset: 64 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 72 +; CHECK-NEXT: - .offset: 72 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 80 +; CHECK-NEXT: - .offset: 80 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 88 +; CHECK-NEXT: - .offset: 88 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .language: OpenCL C @@ -1754,20 +1613,16 @@ ; CHECK-NEXT: - .offset: 56 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 64 +; CHECK-NEXT: - .offset: 64 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 72 +; CHECK-NEXT: - .offset: 72 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 80 +; CHECK-NEXT: - .offset: 80 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 88 +; CHECK-NEXT: - .offset: 88 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .language: OpenCL C @@ -1803,20 +1658,16 @@ ; CHECK-NEXT: - .offset: 48 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 56 +; CHECK-NEXT: - .offset: 56 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 64 +; CHECK-NEXT: - .offset: 64 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 72 +; CHECK-NEXT: - .offset: 72 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 80 +; CHECK-NEXT: - .offset: 80 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .device_enqueue_symbol: __test_block_invoke_kernel_runtime_handle @@ -1848,20 +1699,16 @@ ; CHECK-NEXT: - .offset: 24 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 32 +; CHECK-NEXT: - .offset: 32 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 40 +; CHECK-NEXT: - .offset: 40 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_default_queue -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 48 +; CHECK-NEXT: - .offset: 48 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_completion_action -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 56 +; CHECK-NEXT: - .offset: 56 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .language: OpenCL C Index: llvm/test/CodeGen/AMDGPU/hsa-metadata-hidden-args-v3.ll =================================================================== --- llvm/test/CodeGen/AMDGPU/hsa-metadata-hidden-args-v3.ll +++ llvm/test/CodeGen/AMDGPU/hsa-metadata-hidden-args-v3.ll @@ -168,8 +168,7 @@ ; CHECK-NEXT: - .offset: 40 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 48 +; CHECK-NEXT: - .offset: 48 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_hostcall_buffer ; CHECK: .name: test32 @@ -211,16 +210,13 @@ ; CHECK-NEXT: - .offset: 40 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 48 +; CHECK-NEXT: - .offset: 48 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_hostcall_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 56 +; CHECK-NEXT: - .offset: 56 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 64 +; CHECK-NEXT: - .offset: 64 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none ; CHECK: .name: test48 @@ -262,20 +258,16 @@ ; CHECK-NEXT: - .offset: 40 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 48 +; CHECK-NEXT: - .offset: 48 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_hostcall_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 56 +; CHECK-NEXT: - .offset: 56 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 64 +; CHECK-NEXT: - .offset: 64 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_none -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 72 +; CHECK-NEXT: - .offset: 72 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg ; CHECK: .name: test56 Index: llvm/test/CodeGen/AMDGPU/hsa-metadata-hidden-args-v5.ll =================================================================== --- llvm/test/CodeGen/AMDGPU/hsa-metadata-hidden-args-v5.ll +++ llvm/test/CodeGen/AMDGPU/hsa-metadata-hidden-args-v5.ll @@ -63,28 +63,22 @@ ; CHECK-NEXT: - .offset: 88 ; CHECK-NEXT: .size: 2 ; CHECK-NEXT: .value_kind: hidden_grid_dims -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 96 +; CHECK-NEXT: - .offset: 96 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_printf_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 104 +; CHECK-NEXT: - .offset: 104 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_hostcall_buffer -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 112 +; CHECK-NEXT: - .offset: 112 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_multigrid_sync_arg -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 120 +; CHECK-NEXT: - .offset: 120 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_heap_v1 -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 128 +; CHECK-NEXT: - .offset: 128 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_default_queue -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 136 +; CHECK-NEXT: - .offset: 136 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_completion_action ; GFX8-NEXT: - .offset: 216 @@ -93,8 +87,7 @@ ; GFX8-NEXT: - .offset: 220 ; GFX8-NEXT: .size: 4 ; GFX8-NEXT: .value_kind: hidden_shared_base -; CHECK: - .address_space: global -; CHECK-NEXT: .offset: 224 +; CHECK: - .offset: 224 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_queue_ptr Index: llvm/test/CodeGen/AMDGPU/hsa-metadata-hostcall-present-v3-asan.ll =================================================================== --- llvm/test/CodeGen/AMDGPU/hsa-metadata-hostcall-present-v3-asan.ll +++ llvm/test/CodeGen/AMDGPU/hsa-metadata-hostcall-present-v3-asan.ll @@ -17,8 +17,7 @@ ; CHECK-NEXT: - .offset: 24 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_global_offset_z -; CHECK-NEXT: - .address_space: global -; CHECK-NEXT: .offset: 32 +; CHECK-NEXT: - .offset: 32 ; CHECK-NEXT: .size: 8 ; CHECK-NEXT: .value_kind: hidden_hostcall_buffer ; CHECK: .language: OpenCL C Index: llvm/test/CodeGen/AMDGPU/hsa-metadata-images-v3.ll =================================================================== --- llvm/test/CodeGen/AMDGPU/hsa-metadata-images-v3.ll +++ llvm/test/CodeGen/AMDGPU/hsa-metadata-images-v3.ll @@ -18,74 +18,62 @@ ; CHECK: --- ; CHECK: amdhsa.kernels: ; CHECK: - .args: -; CHECK: - .address_space: global -; CHECK: .name: a +; CHECK: - .name: a ; CHECK: .offset: 0 ; CHECK: .size: 8 ; CHECK: .type_name: image1d_t ; CHECK: .value_kind: image -; CHECK: - .address_space: global -; CHECK: .name: b +; CHECK: - .name: b ; CHECK: .offset: 8 ; CHECK: .size: 8 ; CHECK: .type_name: image1d_array_t ; CHECK: .value_kind: image -; CHECK: - .address_space: global -; CHECK: .name: c +; CHECK: - .name: c ; CHECK: .offset: 16 ; CHECK: .size: 8 ; CHECK: .type_name: image1d_buffer_t ; CHECK: .value_kind: image -; CHECK: - .address_space: global -; CHECK: .name: d +; CHECK: - .name: d ; CHECK: .offset: 24 ; CHECK: .size: 8 ; CHECK: .type_name: image2d_t ; CHECK: .value_kind: image -; CHECK: - .address_space: global -; CHECK: .name: e +; CHECK: - .name: e ; CHECK: .offset: 32 ; CHECK: .size: 8 ; CHECK: .type_name: image2d_array_t ; CHECK: .value_kind: image -; CHECK: - .address_space: global -; CHECK: .name: f +; CHECK: - .name: f ; CHECK: .offset: 40 ; CHECK: .size: 8 ; CHECK: .type_name: image2d_array_depth_t ; CHECK: .value_kind: image -; CHECK: - .address_space: global -; CHECK: .name: g +; CHECK: - .name: g ; CHECK: .offset: 48 ; CHECK: .size: 8 ; CHECK: .type_name: image2d_array_msaa_t ; CHECK: .value_kind: image -; CHECK: - .address_space: global -; CHECK: .name: h +; CHECK: - .name: h ; CHECK: .offset: 56 ; CHECK: .size: 8 ; CHECK: .type_name: image2d_array_msaa_depth_t ; CHECK: .value_kind: image -; CHECK: - .address_space: global -; CHECK: .name: i +; CHECK: - .name: i ; CHECK: .offset: 64 ; CHECK: .size: 8 ; CHECK: .type_name: image2d_depth_t ; CHECK: .value_kind: image -; CHECK: - .address_space: global -; CHECK: .name: j +; CHECK: - .name: j ; CHECK: .offset: 72 ; CHECK: .size: 8 ; CHECK: .type_name: image2d_msaa_t ; CHECK: .value_kind: image -; CHECK: - .address_space: global -; CHECK: .name: k +; CHECK: - .name: k ; CHECK: .offset: 80 ; CHECK: .size: 8 ; CHECK: .type_name: image2d_msaa_depth_t ; CHECK: .value_kind: image -; CHECK: - .address_space: global -; CHECK: .name: l +; CHECK: - .name: l ; CHECK: .offset: 88 ; CHECK: .size: 8 ; CHECK: .type_name: image3d_t