From 952eddef9aff85b1e92626e89baaf7a360e2ac85 Mon Sep 17 00:00:00 2001 From: dim Date: Sun, 22 Dec 2013 00:07:40 +0000 Subject: Vendor import of clang release_34 branch r197841 (effectively, 3.4 RC3): https://llvm.org/svn/llvm-project/cfe/branches/release_34@197841 --- test/CodeGenCXX/vtable-available-externally.cpp | 26 ++++--------------------- 1 file changed, 4 insertions(+), 22 deletions(-) (limited to 'test/CodeGenCXX/vtable-available-externally.cpp') diff --git a/test/CodeGenCXX/vtable-available-externally.cpp b/test/CodeGenCXX/vtable-available-externally.cpp index 693b36a..282bd2a 100644 --- a/test/CodeGenCXX/vtable-available-externally.cpp +++ b/test/CodeGenCXX/vtable-available-externally.cpp @@ -1,19 +1,11 @@ -// RUN: %clang_cc1 %s -I%S -triple=x86_64-apple-darwin10 -emit-llvm -O3 -o %t +// RUN: %clang_cc1 %s -I%S -triple=x86_64-apple-darwin10 -emit-llvm -o %t // RUN: FileCheck --check-prefix=CHECK-TEST1 %s < %t // RUN: FileCheck --check-prefix=CHECK-TEST2 %s < %t // RUN: FileCheck --check-prefix=CHECK-TEST5 %s < %t -// RUN: FileCheck --check-prefix=CHECK-TEST7 %s < %t #include -// Test1::A's key function (f) is not defined in this translation -// unit, but in order to devirtualize calls, we emit the v-table with -// available_externally linkage. -// -// There's no real reason to do this to the RTTI, though. - -// CHECK-TEST1: @_ZTVN5Test11AE = available_externally -// CHECK-TEST1: @_ZTIN5Test11AE = external constant i8* +// CHECK-TEST1: @_ZTVN5Test11AE = external unnamed_addr constant namespace Test1 { struct A { @@ -28,7 +20,7 @@ void f(A* a) { a->f(); }; -// CHECK: define void @_ZN5Test11gEv +// CHECK-LABEL: define void @_ZN5Test11gEv // CHECK: call void @_ZN5Test11A1fEv void g() { A a; @@ -106,7 +98,7 @@ void f() { } // PR9130, test that we emit a definition of A::f. -// CHECK-TEST5: define linkonce_odr void @_ZN5Test51A1fEv +// CHECK-TEST5-LABEL: define linkonce_odr void @_ZN5Test51A1fEv namespace Test5 { struct A { @@ -159,14 +151,4 @@ struct c11 : c10, c1{ struct c28 : virtual c11{ void f6 (); }; - -// CHECK-TEST7: define void @_ZN5Test79check_c28Ev -// CHECK-TEST7: call void @_ZN5Test73c282f6Ev -// CHECK-TEST7: ret void -void check_c28 () { - c28 obj; - c11 *ptr = &obj; - ptr->f6 (); -} - } -- cgit v1.1