History log of /external/clang/test/CodeGenCXX/vtable-available-externally.cpp
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
976d91177a83101434c1985ea3b14f682f0f38c4 06-Feb-2011 Anders Carlsson <andersca@mac.com> Add another test that we can fully devirtualize now.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124988 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/test/CodeGenCXX/vtable-available-externally.cpp
bbfd5babab059af14eed20b63b2aabedaa6a6ac7 05-Feb-2011 Anders Carlsson <andersca@mac.com> Pass a 'ForVTable' flag to GetAddrOfThunk and pass it along to GetOrCreateLLVMFunction so that we
won't assert when building a thunk for an implicit virtual member function that is not marked used.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124967 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/test/CodeGenCXX/vtable-available-externally.cpp
1faa89f9c619e4b2411fab4af7e22ee7a2bd9009 05-Feb-2011 Anders Carlsson <andersca@mac.com> Re-land r124768, with a fix for PR9130.

We now emit everything except unused implicit virtual member functions when building the vtable.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124935 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/test/CodeGenCXX/vtable-available-externally.cpp
01de7a44cea9f77cbcda65faad8edc8b48a3b617 03-Feb-2011 Rafael Espindola <rafael.espindola@gmail.com> Revert 124768.
This reopens PR99114, but that one at least can be avoided with an #include.
PR9130 cannot.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124780 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/test/CodeGenCXX/vtable-available-externally.cpp
aedd9d5ad3cc776fd61457050bcd54cac4c5ea66 03-Feb-2011 Anders Carlsson <andersca@mac.com> Don't try to mark virtual members referenced for classes where the key function
is not defined in the current translation unit. Doing so lead to compile errors
such as PR9114.

Instead, when CodeGen is building the vtable, don't try to emit a definition
for functions that aren't marked used in the current translation unit.
Fixes PR9114.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124768 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/test/CodeGenCXX/vtable-available-externally.cpp
6d7f8473cd6e967b3676948894ce72472102f9cb 30-Jan-2011 Anders Carlsson <andersca@mac.com> When building with optimizations, emit vtables where the key is not in the
current translation unit as available_externally.

This helps devirtualize the second example in PR3100, comment 18:

struct S { S() {}; virtual void xyzzy(); };
inline void foo(S *s) { s->xyzzy(); }
void bar() { S s; foo(&s); }

This involved four major changes:

1. In DefineUsedVTables, always mark virtual member functions as referenced for
non-template classes and class template specializations.
2. In CodeGenVTables::ShouldEmitVTableInThisTU return true if optimizations are
enabled, even if the key function is not implemented in this translation
unit. We don't ever do this for code compiled with -fapple-kext, because we
don't ever want to devirtualize virtual member function calls in that case.
3. Give the correct linkage for vtables where the key function is not defined.
4. Update the linkage for RTTI structures when necessary.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124565 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/test/CodeGenCXX/vtable-available-externally.cpp