diff options
author | Arthur Eubanks <aeubanks@google.com> | 2022-06-15 09:44:43 -0700 |
---|---|---|
committer | Arthur Eubanks <aeubanks@google.com> | 2022-06-16 09:38:14 -0700 |
commit | a70b39abffb42eb85fd2dd7960ec9dc7ae38510c (patch) | |
tree | 9e8dedc24fa27ebd88c49643165986ff10ad6a38 /clang/lib/CodeGen/CGClass.cpp | |
parent | 046ebeb60504abfb053c24c1ee5ab6747cfa5a08 (diff) | |
download | llvm-a70b39abffb42eb85fd2dd7960ec9dc7ae38510c.zip llvm-a70b39abffb42eb85fd2dd7960ec9dc7ae38510c.tar.gz llvm-a70b39abffb42eb85fd2dd7960ec9dc7ae38510c.tar.bz2 |
[clang] Don't emit type test/assume for virtual classes that should never participate in WPD
Reviewed By: pcc
Differential Revision: https://reviews.llvm.org/D127876
Diffstat (limited to 'clang/lib/CodeGen/CGClass.cpp')
-rw-r--r-- | clang/lib/CodeGen/CGClass.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/clang/lib/CodeGen/CGClass.cpp b/clang/lib/CodeGen/CGClass.cpp index cb16019..153f299 100644 --- a/clang/lib/CodeGen/CGClass.cpp +++ b/clang/lib/CodeGen/CGClass.cpp @@ -2695,9 +2695,9 @@ void CodeGenFunction::EmitTypeMetadataCodeForVCall(const CXXRecordDecl *RD, if (SanOpts.has(SanitizerKind::CFIVCall)) EmitVTablePtrCheckForCall(RD, VTable, CodeGenFunction::CFITCK_VCall, Loc); else if (CGM.getCodeGenOpts().WholeProgramVTables && - // Don't insert type test assumes if we are forcing public std + // Don't insert type test assumes if we are forcing public // visibility. - !CGM.HasLTOVisibilityPublicStd(RD)) { + !CGM.AlwaysHasLTOVisibilityPublic(RD)) { llvm::Metadata *MD = CGM.CreateMetadataIdentifierForType(QualType(RD->getTypeForDecl(), 0)); llvm::Value *TypeId = |