DHowett-MSFT added inline comments.
================ Comment at: lib/CodeGen/CGObjCGNU.cpp:439 + ArrayRef<llvm::Constant *> IvarOffsets, + ArrayRef<llvm::Constant *> IvarAlign, + ArrayRef<Qualifiers::ObjCLifetime> IvarOwnership); ---------------- While we're here, is there value in storing the ivar size in layout as well, so that the runtime doesn't need to calculate it from the distance to the next ivar/end of the instance? ================ Comment at: lib/CodeGen/CGObjCGNU.cpp:1402 + Stop->setVisibility(llvm::GlobalValue::HiddenVisibility); + return { Start, Stop }; + } ---------------- This should be readily expandable for PE/COFF, but we'll need to change some of the section names to fit better. Is it worth abstracting the names of the sections across the target format somehow? (pe/coff will need to emit COMDAT symbols pointing into lexicographically sortable section names that the linker can fold away) ================ Comment at: lib/CodeGen/CGObjCGNU.cpp:1446 + /*isConstant*/true, llvm::GlobalValue::LinkOnceAnyLinkage, + LoadFunction, ".objc_ctor"); + // Check that this hasn't been renamed. This shouldn't happen, because ---------------- Is there a way to ensure that objc_load happens before other static initializers across the entire set of linker inputs? Repository: rC Clang https://reviews.llvm.org/D46052 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits