Home | History | Annotate | Download | only in Inputs
      1 // To generate the test file:
      2 // clang cross-cu-inlining.c -DA_C -g -emit-llvm -S -o a.ll
      3 // clang cross-cu-inlining.c -DB_C -g -emit-llvm -S -o b.ll
      4 // llvm-link a.ll b.ll -o ab.bc
      5 // opt -inline ab.bc -o cross-cu-inlining.bc
      6 // clang -c cross-cu-inlining.bc -o cross-cu-inlining.o
      7 #ifdef A_C
      8 int i;
      9 int func(int);
     10 int main() {
     11   return func(i);
     12 }
     13 #endif
     14 #ifdef B_C
     15 int __attribute__((always_inline)) func(int x) {
     16   return x * 2;
     17 }
     18 #endif
     19