[cfe-commits] r69199 - in /cfe/trunk: lib/CodeGen/CGObjCMac.cpp test/CodeGenObjC/metadata-symbols-64.m
Daniel Dunbar
daniel at zuster.org
Wed Apr 15 12:04:47 PDT 2009
Author: ddunbar
Date: Wed Apr 15 14:04:46 2009
New Revision: 69199
URL: http://llvm.org/viewvc/llvm-project?rev=69199&view=rev
Log:
Fix alignment on obj_msgrefs to match llvm-gcc.
Modified:
cfe/trunk/lib/CodeGen/CGObjCMac.cpp
cfe/trunk/test/CodeGenObjC/metadata-symbols-64.m
Modified: cfe/trunk/lib/CodeGen/CGObjCMac.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/CodeGen/CGObjCMac.cpp?rev=69199&r1=69198&r2=69199&view=diff
==============================================================================
--- cfe/trunk/lib/CodeGen/CGObjCMac.cpp (original)
+++ cfe/trunk/lib/CodeGen/CGObjCMac.cpp Wed Apr 15 14:04:46 2009
@@ -4989,8 +4989,7 @@
Name,
&CGM.getModule());
GV->setVisibility(llvm::GlobalValue::HiddenVisibility);
- GV->setAlignment(
- CGM.getTargetData().getPrefTypeAlignment(ObjCTypes.MessageRefTy));
+ GV->setAlignment(16);
GV->setSection("__DATA, __objc_msgrefs, coalesced");
UsedGlobals.push_back(GV);
}
Modified: cfe/trunk/test/CodeGenObjC/metadata-symbols-64.m
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/CodeGenObjC/metadata-symbols-64.m?rev=69199&r1=69198&r2=69199&view=diff
==============================================================================
--- cfe/trunk/test/CodeGenObjC/metadata-symbols-64.m (original)
+++ cfe/trunk/test/CodeGenObjC/metadata-symbols-64.m Wed Apr 15 14:04:46 2009
@@ -35,6 +35,7 @@
// RUN: grep '@"\\01l_OBJC_LABEL_PROTOCOL_$_P" = weak hidden global .* section "__DATA, __objc_protolist, coalesced, no_dead_strip", align 8' %t &&
// RUN: grep '@"\\01l_OBJC_METACLASS_RO_$_A" = internal global .* section "__DATA, __objc_const", align 8' %t &&
// RUN: grep '@"\\01l_OBJC_PROTOCOL_$_P" = weak hidden global .* section "__DATA,__datacoal_nt,coalesced", align 8' %t &&
+// RUN: grep '@"\\01l_objc_msgSend_fixup_alloc" = weak hidden global .* section "__DATA, __objc_msgrefs, coalesced", align 16' %t &&
// RUN: grep '@_objc_empty_cache = external global' %t &&
// RUN: grep '@_objc_empty_vtable = external global' %t &&
More information about the cfe-commits
mailing list