diff options
author | Peter Collingbourne <peter@pcc.me.uk> | 2016-02-24 20:46:36 +0000 |
---|---|---|
committer | Peter Collingbourne <peter@pcc.me.uk> | 2016-02-24 20:46:36 +0000 |
commit | fb532b9a340958494a5346f2230d51653e8ed31e (patch) | |
tree | 8b440293a23d1fb94658086ac9ef8c5266a7e449 /clang/runtime | |
parent | 40afcb547e4302017bcb5c06ae2204084c3dc776 (diff) | |
download | llvm-fb532b9a340958494a5346f2230d51653e8ed31e.zip llvm-fb532b9a340958494a5346f2230d51653e8ed31e.tar.gz llvm-fb532b9a340958494a5346f2230d51653e8ed31e.tar.bz2 |
Add whole-program vtable optimization feature to Clang.
This patch introduces the -fwhole-program-vtables flag, which enables the
whole-program vtable optimization feature (D16795) in Clang.
Differential Revision: http://reviews.llvm.org/D16821
llvm-svn: 261767
Diffstat (limited to 'clang/runtime')
-rw-r--r-- | clang/runtime/CMakeLists.txt | 10 | ||||
-rw-r--r-- | clang/runtime/vtables_blacklist.txt | 8 |
2 files changed, 18 insertions, 0 deletions
diff --git a/clang/runtime/CMakeLists.txt b/clang/runtime/CMakeLists.txt index 4775b0d..3215d8f 100644 --- a/clang/runtime/CMakeLists.txt +++ b/clang/runtime/CMakeLists.txt @@ -134,3 +134,13 @@ if(LLVM_BUILD_EXTERNAL_COMPILER_RT AND EXISTS ${COMPILER_RT_SRC_ROOT}/) VERBATIM) endif() endif() + +set(src "${CMAKE_CURRENT_SOURCE_DIR}/vtables_blacklist.txt") +set(dst "${LLVM_LIBRARY_OUTPUT_INTDIR}/clang/${CLANG_VERSION}/vtables_blacklist.txt") +add_custom_command(OUTPUT ${dst} + DEPENDS ${src} + COMMAND ${CMAKE_COMMAND} -E copy_if_different ${src} ${dst} + COMMENT "Copying vtables blacklist") +add_custom_target(vtables_blacklist DEPENDS ${dst}) +add_dependencies(clang vtables_blacklist) +install(FILES ${src} DESTINATION lib${LLVM_LIBDIR_SUFFIX}/clang/${CLANG_VERSION}) diff --git a/clang/runtime/vtables_blacklist.txt b/clang/runtime/vtables_blacklist.txt new file mode 100644 index 0000000..f201642 --- /dev/null +++ b/clang/runtime/vtables_blacklist.txt @@ -0,0 +1,8 @@ +# Standard library types. +type:std::* + +# The stdext namespace contains Microsoft standard library extensions. +type:stdext::* + +# Types with a uuid attribute, i.e. COM types. +type:attr:uuid |