[PATCH] D80166: [CGCall] Annotate reference parameters with "align" attribute.

2020-05-19 Thread John McCall via Phabricator via cfe-commits
rjmccall accepted this revision. rjmccall added a comment. This revision is now accepted and ready to land. LGTM. Comment at: clang/lib/CodeGen/CGCall.cpp:2258 Attrs.addDereferenceableAttr(info.first.getQuantity()); -Attrs.addAttribute(llvm::Attribute::getWithA

[PATCH] D80166: [CGCall] Annotate reference parameters with "align" attribute.

2020-05-19 Thread Eli Friedman via Phabricator via cfe-commits
efriedma marked 2 inline comments as done. efriedma added inline comments. Comment at: clang/lib/CodeGen/CGCall.cpp:2116 +if (PTy->isObjectType()) { + if (unsigned Alignment = getContext().getTypeAlignIfKnown(PTy)) +RetAttrs.addAlignmentAttr( rjm

[PATCH] D80166: [CGCall] Annotate reference parameters with "align" attribute.

2020-05-19 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. Herald added a subscriber: sstefan1. Hmm. It looks like we did reserve space for this in the great pointer-alignment-assumption detente ("RFC: Enforcing pointer type alignment in Clang" from early 2016, which I'm aware was never really a consensus position, but which