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 | 3434d492b3d897efd0fb1063aa61e5869c50d7e0 (patch) | |
tree | 7abce191c249b88a9aab0290c6d0120152b089d4 /clang/lib/CodeGen | |
parent | 94f46dc056b017e4d9daf170450ef6ffe0d9ad8c (diff) | |
download | bcm5719-llvm-3434d492b3d897efd0fb1063aa61e5869c50d7e0.tar.gz bcm5719-llvm-3434d492b3d897efd0fb1063aa61e5869c50d7e0.zip |
It turns out BuildAggrIvarLayout wasn't even using the shadow struct,
just computing it!
llvm-svn: 70779
Diffstat (limited to 'clang/lib/CodeGen')
-rw-r--r-- | clang/lib/CodeGen/CGObjCMac.cpp | 12 |
1 files changed, 1 insertions, 11 deletions
diff --git a/clang/lib/CodeGen/CGObjCMac.cpp b/clang/lib/CodeGen/CGObjCMac.cpp index 35fb54fae43..a5450ff1be5 100644 --- a/clang/lib/CodeGen/CGObjCMac.cpp +++ b/clang/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); |