source: icGREP/icgrep-devel/llvm-3.8.0.src/test/Analysis/TypeBasedAliasAnalysis/intrinsics.ll @ 5027

Last change on this file since 5027 was 5027, checked in by cameron, 3 years ago

Upgrade to llvm 3.8

File size: 1.4 KB
Line 
1; RUN: opt -tbaa -basicaa -gvn -S < %s | FileCheck %s
2
3target datalayout = "e-p:32:32:32-i1:8:32-i8:8:32-i16:16:32-i32:32:32-i64:32:32-f32:32:32-f64:32:32-v64:32:64-v128:32:128-a0:0:32-n32"
4
5; TBAA should prove that these calls don't interfere, since they are
6; IntrArgReadMem and have TBAA metadata.
7
8; CHECK:      define <8 x i16> @test0(i8* %p, i8* %q, <8 x i16> %y) {
9; CHECK-NEXT: entry:
10; CHECK-NEXT:   %a = call <8 x i16> @llvm.arm.neon.vld1.v8i16.p0i8(i8* %p, i32 16) [[NUW:#[0-9]+]]
11; CHECK-NEXT:   call void @llvm.arm.neon.vst1.p0i8.v8i16(i8* %q, <8 x i16> %y, i32 16)
12; CHECK-NEXT:   %c = add <8 x i16> %a, %a
13define <8 x i16> @test0(i8* %p, i8* %q, <8 x i16> %y) {
14entry:
15  %a = call <8 x i16> @llvm.arm.neon.vld1.v8i16.p0i8(i8* %p, i32 16) nounwind, !tbaa !2
16  call void @llvm.arm.neon.vst1.p0i8.v8i16(i8* %q, <8 x i16> %y, i32 16), !tbaa !1
17  %b = call <8 x i16> @llvm.arm.neon.vld1.v8i16.p0i8(i8* %p, i32 16) nounwind, !tbaa !2
18  %c = add <8 x i16> %a, %b
19  ret <8 x i16> %c
20}
21
22declare <8 x i16> @llvm.arm.neon.vld1.v8i16.p0i8(i8*, i32) nounwind readonly
23declare void @llvm.arm.neon.vst1.p0i8.v8i16(i8*, <8 x i16>, i32) nounwind
24
25; CHECK: attributes #0 = { argmemonly nounwind readonly }
26; CHECK: attributes #1 = { argmemonly nounwind }
27; CHECK: attributes [[NUW]] = { nounwind }
28
29!0 = !{!"tbaa root", null}
30!1 = !{!3, !3, i64 0}
31!2 = !{!4, !4, i64 0}
32!3 = !{!"A", !0}
33!4 = !{!"B", !0}
Note: See TracBrowser for help on using the repository browser.