1 ; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
2 ; RUN: opt < %s -passes=slp-vectorizer -S -mtriple=x86_64--- | FileCheck %s
4 define void @test(ptr noalias %a, ptr %b) {
6 ; CHECK-NEXT: [[PA1:%.*]] = getelementptr inbounds i64, ptr [[A:%.*]], i32 64
7 ; CHECK-NEXT: [[A1:%.*]] = load i64, ptr [[PA1]], align 8
8 ; CHECK-NEXT: [[PB1:%.*]] = getelementptr inbounds i64, ptr [[B:%.*]], i32 64
9 ; CHECK-NEXT: [[B1:%.*]] = load i64, ptr [[PB1]], align 8
10 ; CHECK-NEXT: [[TMP1:%.*]] = load <2 x i32>, ptr [[A]], align 4
11 ; CHECK-NEXT: [[TMP2:%.*]] = load <2 x i32>, ptr [[B]], align 4
12 ; CHECK-NEXT: [[C1:%.*]] = icmp eq i64 [[B1]], [[A1]]
13 ; CHECK-NEXT: [[TMP3:%.*]] = icmp eq <2 x i32> [[TMP1]], [[TMP2]]
14 ; CHECK-NEXT: ret void
16 %pa1 = getelementptr inbounds i64, ptr %a, i32 64
17 %pa2 = getelementptr inbounds i32, ptr %a, i32 1
18 %a0 = load i32, ptr %a, align 4
19 %a1 = load i64, ptr %pa1, align 8
20 %a2 = load i32, ptr %pa2, align 4
21 %pb1 = getelementptr inbounds i64, ptr %b, i32 64
22 %pb2 = getelementptr inbounds i32, ptr %b, i32 1
23 %b0 = load i32, ptr %b, align 4
24 %b1 = load i64, ptr %pb1, align 8
25 %b2 = load i32, ptr %pb2, align 4
26 %c0 = icmp eq i32 %a0, %b0
27 %c1 = icmp eq i64 %b1, %a1
28 %c2 = icmp eq i32 %b2, %a2