Page MenuHomePhabricator

update docs of memcpy/memmove/memset re: alignment and len=0
ClosedPublic

Authored by RalfJung on Feb 1 2019, 10:08 AM.

Details

Summary

Fix https://bugs.llvm.org/show_bug.cgi?id=38583: Describe how memcpy/memmove/memset behave when len=0. Also fix some fallout from when the alignment parameter was replaced by an attribute.

Diff Detail

Repository
rL LLVM

Event Timeline

RalfJung created this revision.Feb 1 2019, 10:08 AM
Herald added a project: Restricted Project. · View Herald TranscriptFeb 1 2019, 10:08 AM
smeenai edited reviewers, added: efriedma; removed: eli.friedman.Feb 25 2019, 8:38 AM
kristina accepted this revision.Feb 25 2019, 9:31 AM
kristina added subscribers: llvm-commits, kristina.

Please make sure you have llvm-commits added as a subscriber when creating patches in the future (I'm not sure why Herald sometimes doesn't do it). The patch that changed this was rL322965, and I fixed one of the related regressions, and was meaning to update the docs but never did, so LGTM and I'm happy signing off on this.

This revision is now accepted and ready to land.Feb 25 2019, 9:31 AM

@RalfJung Do you need someone to commit this? I can do it if you'd like.

Please make sure you have llvm-commits added as a subscriber when creating patches in the future

Thanks, I'll try to remember. It might be worth clarifying at https://llvm.org/docs/Phabricator.html#phabricator-request-review-web that "adding a reviewer" and "subscribing someone" is *not* the same thing. As someone who has not used Phabricator ever before, I figured these would just be different terms for the same thing; I had no idea there are separate lists of "reviewers" and "subscribers" (llvm-commits is, after all, mentioned in the bullet point that is all about adding reviewers).

was meaning to update the docs but never did

Notice that this does not just fix the fallout from that patch. The remarks about what happens when "len" is 0 are new, and based on the feedback I received at https://bugs.llvm.org/show_bug.cgi?id=38583.

I also just found a typo in my patch, so now I will have to figure out how to update a patch here.

RalfJung updated this revision to Diff 188333.Feb 26 2019, 3:25 AM

Fix typo.

I fixed the typo.

Do you need someone to commit this? I can do it if you'd like.

I guess I do? Not sure what the usual process is. I don't have any commit rights myself.

This revision was automatically updated to reflect the committed changes.