rnk added a subscriber: rnk. ================ Comment at: lib/CodeGen/CGDebugInfo.cpp:608 @@ -608,2 +607,3 @@ uint64_t Size = CGM.getContext().getTypeSize(Ty); + uint64_t Align = 0; ---------------- IMO this is what we should be doing everywhere, rather than manually checking AlignedAttr: TypeInfo TI = CGM.getContext().getTypeInfo(Ty); uint64_t Size = TI.Width; uint64_t Align = TI.AlignIsRequired ? TI.Align : 0;
This saves a hash lookup, and handles some corner cases. AlignIsRequired is already supposed to capture whether the alignment was changed. https://reviews.llvm.org/D24426 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits