[clang][modules] Don't prevent translation of FW_Private includes when explicitly...
[llvm-project.git] / clang / test / CodeGenCXX / inline-template-hint.cpp
blob3e64b1f74932485f360f4de8a773685251da6c4b
1 // RUN: %clang_cc1 %s -std=c++11 -triple=x86_64-linux -O2 \
2 // RUN: -finline-functions -emit-llvm -disable-llvm-passes -o - \
3 // RUN: | FileCheck -allow-deprecated-dag-overlap %s \
4 // RUN: --check-prefix=CHECK --check-prefix=SUITABLE
5 // RUN: %clang_cc1 %s -std=c++11 -triple=x86_64-linux -O2 \
6 // RUN: -finline-hint-functions -emit-llvm -disable-llvm-passes -o - \
7 // RUN: | FileCheck -allow-deprecated-dag-overlap %s \
8 // RUN: --check-prefix=CHECK --check-prefix=HINTED
9 // RUN: %clang_cc1 %s -std=c++11 -triple=x86_64-linux -O2 \
10 // RUN: -fno-inline -emit-llvm -disable-llvm-passes -o - \
11 // RUN: | FileCheck -allow-deprecated-dag-overlap %s \
12 // RUN: --check-prefix=CHECK --check-prefix=NOINLINE
14 struct A {
15 inline void int_run(int);
17 template <class T>
18 inline void template_run(T);
21 // CHECK: @_ZN1A7int_runEi({{.*}}) [[ATTR:#[0-9]+]]
22 void A::int_run(int) {}
23 // CHECK: @_ZN1A12template_runIiEEvT_({{.*}}) [[ATTR]]
24 template <typename T>
25 void A::template_run(T) {}
27 void bar() {
28 A().int_run(1);
29 A().template_run(1);
32 // SUITABLE: attributes [[ATTR]] = { {{.*}}inlinehint{{.*}} }
33 // HINTED: attributes [[ATTR]] = { {{.*}}inlinehint{{.*}} }
34 // NOINLINE: attributes [[ATTR]] = { {{.*}}noinline{{.*}} }