diff options
author | Daniel Dunbar <daniel@zuster.org> | 2009-05-03 14:22:14 +0000 |
---|---|---|
committer | Daniel Dunbar <daniel@zuster.org> | 2009-05-03 14:22:14 +0000 |
commit | 7c9f6c51be1c0bbfe59b64e92587d2e37ce73a7d (patch) | |
tree | 815541b3e13551122a5ab058d81dfeb6dc1ff36b /lib | |
parent | 25d583ec27cc2fe4d0dccaa5d41b6c3b645beda0 (diff) |
It turns out BuildAggrIvarLayout wasn't even using the shadow struct,
just computing it!
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@70779 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r-- | lib/CodeGen/CGObjCMac.cpp | 12 |
1 files changed, 1 insertions, 11 deletions
diff --git a/lib/CodeGen/CGObjCMac.cpp b/lib/CodeGen/CGObjCMac.cpp index 35fb54fae4..a5450ff1be 100644 --- a/lib/CodeGen/CGObjCMac.cpp +++ b/lib/CodeGen/CGObjCMac.cpp @@ -35,14 +35,6 @@ using namespace CodeGen; // don't belong in CGObjCRuntime either so we will live with it for // now. -static const llvm::StructType * -GetConcreteClassStruct(CodeGen::CodeGenModule &CGM, - const ObjCInterfaceDecl *OID) { - assert(!OID->isForwardDecl() && "Invalid interface decl!"); - const RecordDecl *RD = CGM.getContext().addRecordToClass(OID); - return cast<llvm::StructType>(CGM.getTypes().ConvertTagDeclType(RD)); -} - /// FindIvarInterface - Find the interface containing the ivar. /// /// FIXME: We shouldn't need to do this, the containing context should @@ -3117,9 +3109,7 @@ llvm::Constant *CGObjCCommonMac::BuildIvarLayout( SkipIvars.clear(); IvarsInfo.clear(); - const llvm::StructLayout *Layout = - CGM.getTargetData().getStructLayout(GetConcreteClassStruct(CGM, OI)); - BuildAggrIvarLayout(OI, Layout, 0, RecFields, 0, ForStrongLayout, hasUnion); + BuildAggrIvarLayout(OI, 0, 0, RecFields, 0, ForStrongLayout, hasUnion); if (IvarsInfo.empty()) return llvm::Constant::getNullValue(PtrTy); |