blob: d6ef6650243eba24994a287f22d0f3f525e7ca35 [file] [log] [blame]
Teresa Johnsonb637cb02017-03-31 22:35:47 +00001// Test to ensure -emit-llvm and -emit-llvm-bc work when invoking the
2// ThinLTO backend path.
3// RUN: %clang -O2 %s -flto=thin -c -o %t.o
4// RUN: llvm-lto -thinlto -o %t %t.o
5// RUN: %clang_cc1 -O2 -x ir %t.o -fthinlto-index=%t.thinlto.bc -emit-llvm -o - | FileCheck %s
6// RUN: %clang_cc1 -O2 -x ir %t.o -fthinlto-index=%t.thinlto.bc -emit-llvm-bc -o - | llvm-dis -o - | FileCheck %s
7
Hans Wennborg8f1559c2017-08-30 23:26:38 +00008// CHECK: define{{.*}} void @foo()
Teresa Johnsonb637cb02017-03-31 22:35:47 +00009void foo() {
10}