[PATCH] D99791: [CGCall] Annotate pointer argument with alignment

2021-04-07 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri updated this revision to Diff 335894. lebedev.ri added a comment. Herald added subscribers: jansvoboda11, dexonsmith, dang. Add an option to toggle this optimization. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D99791/new/ https://revie

[PATCH] D99791: [CGCall] Annotate pointer argument with alignment

2021-04-06 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. In D99791#2672528 , @lebedev.ri wrote: > @rjmccall thank you for taking a look! > > In D99791#2670333 , @rjmccall wrote: > >> The last major conversation we had about this was this RFC I se

[PATCH] D99791: [CGCall] Annotate pointer argument with alignment

2021-04-06 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri planned changes to this revision. lebedev.ri added a comment. @rjmccall thank you for taking a look! In D99791#2670333 , @rjmccall wrote: > The last major conversation we had about this was this RFC I sent out about > five years ago: > > htt

[PATCH] D99791: [CGCall] Annotate pointer argument with alignment

2021-04-05 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. The last major conversation we had about this was this RFC I sent out about five years ago: https://lists.llvm.org/pipermail/llvm-dev/2016-January/094012.html In that RFC, I specifically argued that we should not do this, and that it should only be considered undefi

[PATCH] D99791: [CGCall] Annotate pointer argument with alignment

2021-04-03 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. @efriedma thank you for taking a look! I agree that D99790 is basically guaranteed safe, and this "probably" isn't. In D99791#2667047 , @efriedma wrote: > This feels scary: the C standard tech

[PATCH] D99791: [CGCall] Annotate pointer argument with alignment

2021-04-02 Thread Eli Friedman via Phabricator via cfe-commits
efriedma added a comment. This feels scary: the C standard technically allows this, but we haven't done it in the past, and it could break otherwise functioning code. (We've only assumed alignment about pointers that are dereferenced/dereferenceable.) For D99790

[PATCH] D99791: [CGCall] Annotate pointer argument with alignment

2021-04-02 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri created this revision. lebedev.ri added reviewers: efriedma, rjmccall, rsmith, erichkeane, aaron.ballman, nikic. lebedev.ri added a project: LLVM. lebedev.ri requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Same idea as D99790