]> granicus.if.org Git - clang/commit
Change memcpy/memove/memset to have dest and source alignment attributes.
authorDaniel Neilson <dneilson@azul.com>
Sun, 28 Jan 2018 17:27:45 +0000 (17:27 +0000)
committerDaniel Neilson <dneilson@azul.com>
Sun, 28 Jan 2018 17:27:45 +0000 (17:27 +0000)
commit09aa26c22dcad5968beaafbe44d017a6780e13c5
treed5a55f0cfccc754ea5745d4f27d96a66e6bbca5c
parent72313cafabe80337ea65eb3115017509e0f655fd
Change memcpy/memove/memset to have dest and source alignment attributes.

Summary:
  This change is step three in the series of changes to remove alignment argument from
memcpy/memmove/memset in favour of alignment attributes. Steps:

Step 1) Remove alignment parameter and create alignment parameter attributes for
memcpy/memmove/memset. ( rL322965, rC322964, rL322963 )
Step 2) Expand the IRBuilder API to allow creation of memcpy/memmove with differing
source and dest alignments. ( rL323597 )
Step 3) Update Clang to use the new IRBuilder API.
Step 4) Update Polly to use the new IRBuilder API.
Step 5) Update LLVM passes that create memcpy/memmove calls to use the new IRBuilder API,
and those that use use MemIntrinsicInst::[get|set]Alignment() to use getDestAlignment()
and getSourceAlignment() instead.
Step 6) Remove the single-alignment IRBuilder API for memcpy/memmove, and the
MemIntrinsicInst::[get|set]Alignment() methods.

Reference
   http://lists.llvm.org/pipermail/llvm-dev/2015-August/089384.html
   http://lists.llvm.org/pipermail/llvm-commits/Week-of-Mon-20151109/312083.html

Reviewers: rjmccall

Subscribers: jyknight, nemanjai, nhaehnle, javed.absar, sbc100, aheejin, kbarton, fedor.sergeev, cfe-commits

Differential Revision: https://reviews.llvm.org/D41677

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@323617 91177308-0d34-0410-b5e6-96231b3b80d8
20 files changed:
lib/CodeGen/CGBuilder.h
test/CodeGen/arm-arguments.c
test/CodeGen/arm64-be-bitfield.c
test/CodeGen/block-byref-aggr.c
test/CodeGen/builtin-memfns.c
test/CodeGen/c11atomics-ios.c
test/CodeGen/c11atomics.c
test/CodeGen/packed-nest-unpacked.c
test/CodeGen/ppc64-align-struct.c
test/CodeGen/ppc64-soft-float.c
test/CodeGen/ppc64le-aggregates.c
test/CodeGen/riscv32-abi.c
test/CodeGen/riscv64-abi.c
test/CodeGen/x86_32-arguments-realign.c
test/CodeGen/x86_64-arguments.c
test/CodeGenCXX/alignment.cpp
test/CodeGenCXX/assign-construct-memcpy.cpp
test/CodeGenCXX/copy-constructor-elim.cpp
test/CodeGenCXX/eh.cpp
test/OpenMP/parallel_reduction_codegen.cpp