diff options
author | Pete Cooper <peter_cooper@apple.com> | 2015-11-18 22:18:45 +0000 |
---|---|---|
committer | Pete Cooper <peter_cooper@apple.com> | 2015-11-18 22:18:45 +0000 |
commit | 7bfd5cb7be04b6963aa7a587bb82b723f686c6b4 (patch) | |
tree | e507353f19f6e410b37fe94325a34557b6e3cb8a /clang/test/OpenMP/atomic_write_codegen.c | |
parent | 72bc23ef02bad3873d3572b2be529404a461d449 (diff) | |
download | bcm5719-llvm-7bfd5cb7be04b6963aa7a587bb82b723f686c6b4.tar.gz bcm5719-llvm-7bfd5cb7be04b6963aa7a587bb82b723f686c6b4.zip |
Change memcpy/memset/memmove to have dest and source alignments.
This is a follow on from a similar LLVM commit: r253511.
Note, this was reviewed (and more details are in) http://lists.llvm.org/pipermail/llvm-commits/Week-of-Mon-20151109/312083.html
These intrinsics currently have an explicit alignment argument which is
required to be a constant integer. It represents the alignment of the
source and dest, and so must be the minimum of those.
This change allows source and dest to each have their own alignments
by using the alignment attribute on their arguments. The alignment
argument itself is removed.
The only code change to clang is hidden in CGBuilder.h which now passes
both dest and source alignment to IRBuilder, instead of taking the minimum of
dest and source alignments.
Reviewed by Hal Finkel.
llvm-svn: 253512
Diffstat (limited to 'clang/test/OpenMP/atomic_write_codegen.c')
-rw-r--r-- | clang/test/OpenMP/atomic_write_codegen.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/clang/test/OpenMP/atomic_write_codegen.c b/clang/test/OpenMP/atomic_write_codegen.c index 66172af07e8..e100ccbe3d1 100644 --- a/clang/test/OpenMP/atomic_write_codegen.c +++ b/clang/test/OpenMP/atomic_write_codegen.c @@ -134,7 +134,7 @@ int main() { dx = dv; // CHECK: [[LD:%.+]] = load x86_fp80, x86_fp80* // CHECK: [[BITCAST:%.+]] = bitcast x86_fp80* [[LDTEMP:%.*]] to i8* -// CHECK: call void @llvm.memset.p0i8.i64(i8* [[BITCAST]], i8 0, i64 16, i32 16, i1 false) +// CHECK: call void @llvm.memset.p0i8.i64(i8* align 16 [[BITCAST]], i8 0, i64 16, i1 false) // CHECK: store x86_fp80 [[LD]], x86_fp80* [[LDTEMP]] // CHECK: [[BITCAST:%.+]] = bitcast x86_fp80* [[LDTEMP:%.*]] to i128* // CHECK: [[LD:%.+]] = load i128, i128* [[BITCAST]] @@ -223,7 +223,7 @@ int main() { // CHECK: load i64, i64* // CHECK: [[VAL:%.+]] = uitofp i64 %{{.+}} to x86_fp80 // CHECK: [[BITCAST:%.+]] = bitcast x86_fp80* [[TEMP:%.+]] to i8* -// CHECK: call void @llvm.memset.p0i8.i64(i8* [[BITCAST]], i8 0, i64 16, i32 16, i1 false) +// CHECK: call void @llvm.memset.p0i8.i64(i8* align 16 [[BITCAST]], i8 0, i64 16, i1 false) // CHECK: store x86_fp80 [[VAL]], x86_fp80* [[TEMP]] // CHECK: [[BITCAST:%.+]] = bitcast x86_fp80* [[TEMP]] to i128* // CHECK: [[VAL:%.+]] = load i128, i128* [[BITCAST]] |