diff options
author | Peter Collingbourne <peter@pcc.me.uk> | 2015-07-15 12:15:56 +0000 |
---|---|---|
committer | Peter Collingbourne <peter@pcc.me.uk> | 2015-07-15 12:15:56 +0000 |
commit | 6fccf95aadba3c5aec1f41723ceae6168d64ac80 (patch) | |
tree | e95a8dc2c6a71a3d05197d3b6720f78b57073b70 /clang/lib/CodeGen/CGClass.cpp | |
parent | 3bed68cfc7c7f336e4ae1f48798ceb3e60e6c888 (diff) | |
download | llvm-6fccf95aadba3c5aec1f41723ceae6168d64ac80.zip llvm-6fccf95aadba3c5aec1f41723ceae6168d64ac80.tar.gz llvm-6fccf95aadba3c5aec1f41723ceae6168d64ac80.tar.bz2 |
CodeGen: Improve CFI type blacklisting mechanism.
We now use the sanitizer special case list to decide which types to blacklist.
We also support a special blacklist entry for types with a uuid attribute,
which are generally COM types whose virtual tables are defined externally.
Differential Revision: http://reviews.llvm.org/D11096
llvm-svn: 242286
Diffstat (limited to 'clang/lib/CodeGen/CGClass.cpp')
-rw-r--r-- | clang/lib/CodeGen/CGClass.cpp | 9 |
1 files changed, 0 insertions, 9 deletions
diff --git a/clang/lib/CodeGen/CGClass.cpp b/clang/lib/CodeGen/CGClass.cpp index c49f182..9c18b86 100644 --- a/clang/lib/CodeGen/CGClass.cpp +++ b/clang/lib/CodeGen/CGClass.cpp @@ -2190,15 +2190,6 @@ void CodeGenFunction::EmitVTablePtrCheckForCast(QualType T, if (!ClassDecl->isCompleteDefinition() || !ClassDecl->isDynamicClass()) return; - SmallString<64> MangledName; - llvm::raw_svector_ostream Out(MangledName); - CGM.getCXXABI().getMangleContext().mangleCXXRTTI(T.getUnqualifiedType(), - Out); - - // Blacklist based on the mangled type. - if (CGM.getContext().getSanitizerBlacklist().isBlacklistedType(Out.str())) - return; - if (!SanOpts.has(SanitizerKind::CFICastStrict)) ClassDecl = LeastDerivedClassWithSameLayout(ClassDecl); |