CodeQL / Analyze (actions) (push) Canceled after 0s
CodeQL / Analyze (python) (push) Canceled after 0s
pre-commit / pre-commit (push) Canceled after 0s
Multi-Arch CI / setup (push) Canceled after 0s
Publish build_manylinux_x86_64 images / publish_build_manylinux_x86_64 (push) Canceled after 0s
Setup (Multi-Arch) / setup (push) Canceled after 0s
Multi-Arch CI / Linux::${{ fromJSON(needs.setup.outputs.linux_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubi10 image / publish_no_rocm_image_ubi10 (push) Canceled after 0s
Multi-Arch CI / Windows::${{ fromJSON(needs.setup.outputs.windows_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Multi-Arch CI / Manifest Diff (push) Canceled after 0s
TheRock Manifest Diff Report / Generate Manifest Diff Report (push) Canceled after 0s
Multi-Arch CI / CI Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_ocl_rt images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_rocgdb images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Unit Tests / Unit Tests :: ubuntu-24.04 (push) Canceled after 0s
Unit Tests / Unit Tests :: windows-2022 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_media (push) Canceled after 0s
Unit Tests / Unit Tests Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_openmpi (push) Canceled after 0s
69 lines
2.6 KiB
C
69 lines
2.6 KiB
C
// Test OpenMP module attributes in CIR output.
|
|
|
|
// Host, x86_64, no target triples
|
|
// RUN: %clang_cc1 -triple x86_64-unknown-linux-gnu -fopenmp -fclangir -emit-cir %s -o - \
|
|
// RUN: | FileCheck %s --check-prefix=HOST
|
|
|
|
// HOST: module {{.*}} attributes {
|
|
// HOST-SAME: omp.is_gpu = false
|
|
// HOST-SAME: omp.is_target_device = false
|
|
|
|
// Host with target triples
|
|
// RUN: %clang_cc1 -triple x86_64-unknown-linux-gnu -fopenmp -fclangir -emit-cir \
|
|
// RUN: -fopenmp-targets=amdgcn-amd-amdhsa,nvptx64-nvidia-cuda %s -o - \
|
|
// RUN: | FileCheck %s --check-prefix=HOST-TRIPLES
|
|
|
|
// HOST-TRIPLES: module {{.*}} attributes {
|
|
// HOST-TRIPLES-SAME: omp.is_gpu = false
|
|
// HOST-TRIPLES-SAME: omp.is_target_device = false
|
|
// HOST-TRIPLES-SAME: omp.target_triples = ["amdgcn-amd-amdhsa", "nvptx64-nvidia-cuda"]
|
|
|
|
// Device, AMDGPU
|
|
// RUN: %clang_cc1 -triple amdgcn-amd-amdhsa -fopenmp -fclangir -emit-cir \
|
|
// RUN: -fopenmp-is-target-device %s -o - \
|
|
// RUN: | FileCheck %s --check-prefix=AMDGPU-DEVICE
|
|
|
|
// AMDGPU-DEVICE: module {{.*}} attributes {
|
|
// AMDGPU-DEVICE-SAME: omp.is_gpu = true
|
|
// AMDGPU-DEVICE-SAME: omp.is_target_device = true
|
|
|
|
// Device, NVPTX
|
|
// RUN: %clang_cc1 -triple nvptx64-nvidia-cuda -fopenmp -fclangir -emit-cir \
|
|
// RUN: -fopenmp-is-target-device %s -o - \
|
|
// RUN: | FileCheck %s --check-prefix=NVPTX-DEVICE
|
|
|
|
// NVPTX-DEVICE: module {{.*}} attributes {
|
|
// NVPTX-DEVICE-SAME: omp.is_gpu = true
|
|
// NVPTX-DEVICE-SAME: omp.is_target_device = true
|
|
|
|
// Device, CPU
|
|
// RUN: %clang_cc1 -fopenmp -fclangir -emit-cir \
|
|
// RUN: -fopenmp-is-target-device %s -o - \
|
|
// RUN: | FileCheck %s --check-prefix=CPU-DEVICE
|
|
|
|
// CPU-DEVICE: module {{.*}} attributes {
|
|
// CPU-DEVICE-SAME: omp.is_gpu = false
|
|
// CPU-DEVICE-SAME: omp.is_target_device = true
|
|
|
|
// Device with omp.flags
|
|
// RUN: %clang_cc1 -triple amdgcn-amd-amdhsa -fopenmp -fclangir -emit-cir \
|
|
// RUN: -fopenmp-is-target-device \
|
|
// RUN: -fopenmp-assume-no-thread-state \
|
|
// RUN: -fopenmp-assume-no-nested-parallelism %s -o - \
|
|
// RUN: | FileCheck %s --check-prefix=DEVICE-FLAGS
|
|
|
|
// DEVICE-FLAGS: module {{.*}} attributes {
|
|
// DEVICE-FLAGS-SAME: omp.flags = #omp.flags<assume_no_thread_state = true, assume_no_nested_parallelism = true
|
|
// DEVICE-FLAGS-SAME: omp.is_gpu = true
|
|
// DEVICE-FLAGS-SAME: omp.is_target_device = true
|
|
|
|
// Force USM (host)
|
|
// RUN: %clang_cc1 -triple x86_64-unknown-linux-gnu -fopenmp -fclangir -emit-cir \
|
|
// RUN: -fopenmp-force-usm %s -o - \
|
|
// RUN: | FileCheck %s --check-prefix=USM
|
|
|
|
// USM: module {{.*}} attributes {
|
|
// USM-SAME: omp.requires = #omp<clause_requires unified_shared_memory>
|
|
|
|
void omp_function(void) {}
|