Expand IRBuilder interface for atomic memcpy to require pointer alignments. (NFC)
authorDaniel Neilson <dneilson@azul.com>
Fri, 10 Nov 2017 19:38:12 +0000 (19:38 +0000)
committerDaniel Neilson <dneilson@azul.com>
Fri, 10 Nov 2017 19:38:12 +0000 (19:38 +0000)
commit6e4aa1e48138182685431c76184dfc36e620aea2
tree613f8dbbdb29e69bfaa89e665a87397d95809ee2
parentbfd6c1c016c0fcb49144b0c16e6dd0a4387d52b9
Expand IRBuilder interface for atomic memcpy to require pointer alignments. (NFC)

Summary:
 The specification of the @llvm.memcpy.element.unordered.atomic intrinsic requires
that the pointer arguments have alignments of at least the element size. The existing
IRBuilder interface to create a call to this intrinsic does not allow for providing
the alignment of these pointer args. Having an interface that makes it easy to
construct invalid intrinsic calls doesn't seem sensible, so this patch simply
adds the requirement that one provide the argument alignments when using IRBuilder
to create atomic memcpy calls.

llvm-svn: 317918
llvm/include/llvm/IR/IRBuilder.h
llvm/lib/IR/IRBuilder.cpp
llvm/lib/Transforms/Scalar/LoopIdiomRecognize.cpp