18 lines · cpp
1// RUN: %clang_cc1 -fopenmp -x c++ -std=c++11 -triple x86_64-unknown-unknown -fopenmp-targets=amdgcn-amd-amdhsa -emit-llvm-bc %s -o %t-ppc-host.bc2// RUN: %clang_cc1 -fopenmp -x c++ -std=c++11 -triple amdgcn-amd-amdhsa -fopenmp-targets=amdgcn-amd-amdhsa -emit-llvm %s -fopenmp-is-target-device "-debug-info-kind=constructor" -fopenmp-host-ir-file-path %t-ppc-host.bc -o - | FileCheck %s3 4// Check that we properly attach debug info to the __kmpc_global_thread_num call5// CHECK: call {{.*}} @__kmpc_global_thread_num{{.*}}!dbg6 7extern int bar();8void foo() {9#pragma omp target teams10 {11#pragma omp parallel12 {13 bar();14 }15 }16}17 18