Unify the ObjC entrypoint caches.

llvm-svn: 250918
This commit is contained in:
John McCall
2015-10-21 18:06:43 +00:00
parent 039f2bbd02
commit b04ecb753a
5 changed files with 47 additions and 49 deletions

View File

@@ -87,8 +87,8 @@ CodeGenModule::CodeGenModule(ASTContext &C, const HeaderSearchOptions &HSO,
VMContext(M.getContext()), TBAA(nullptr), TheTargetCodeGenInfo(nullptr),
Types(*this), VTables(*this), ObjCRuntime(nullptr),
OpenCLRuntime(nullptr), OpenMPRuntime(nullptr), CUDARuntime(nullptr),
DebugInfo(nullptr), ARCData(nullptr),
NoObjCARCExceptionsMetadata(nullptr), RRData(nullptr), PGOReader(nullptr),
DebugInfo(nullptr), ObjCData(nullptr),
NoObjCARCExceptionsMetadata(nullptr), PGOReader(nullptr),
CFConstantStringClassRef(nullptr), ConstantStringClassRef(nullptr),
NSConstantStringType(nullptr), NSConcreteGlobalBlock(nullptr),
NSConcreteStackBlock(nullptr), BlockObjectAssign(nullptr),
@@ -142,9 +142,8 @@ CodeGenModule::CodeGenModule(ASTContext &C, const HeaderSearchOptions &HSO,
Block.GlobalUniqueCount = 0;
if (C.getLangOpts().ObjCAutoRefCount)
ARCData = new ARCEntrypoints();
RRData = new RREntrypoints();
if (C.getLangOpts().ObjC1)
ObjCData = new ObjCEntrypoints();
if (!CodeGenOpts.InstrProfileInput.empty()) {
auto ReaderOrErr =
@@ -172,8 +171,7 @@ CodeGenModule::~CodeGenModule() {
delete TheTargetCodeGenInfo;
delete TBAA;
delete DebugInfo;
delete ARCData;
delete RRData;
delete ObjCData;
}
void CodeGenModule::createObjCRuntime() {