brintos

brintos / llvm-project-archived public Read only

0
0
Text · 2.8 KiB · 68f1fcd Raw
65 lines · plain
1; NOTE: Assertions have been autogenerated by utils/update_test_checks.py2; RUN: opt < %s -S -mtriple=aarch64 -passes=slp-vectorizer | FileCheck %s3 4%struct.buf = type { [8 x i8] }5 6define i8 @reduce_xor(ptr %a, ptr %b) {7; CHECK-LABEL: @reduce_xor(8; CHECK-NEXT:  entry:9; CHECK-NEXT:    [[TMP1:%.*]] = load <8 x i8>, ptr [[A:%.*]], align 110; CHECK-NEXT:    [[TMP3:%.*]] = load <8 x i8>, ptr [[B:%.*]], align 111; CHECK-NEXT:    [[TMP4:%.*]] = and <8 x i8> [[TMP3]], [[TMP1]]12; CHECK-NEXT:    [[TMP5:%.*]] = call i8 @llvm.vector.reduce.xor.v8i8(<8 x i8> [[TMP4]])13; CHECK-NEXT:    [[OP_RDX:%.*]] = xor i8 [[TMP5]], 114; CHECK-NEXT:    ret i8 [[OP_RDX]]15;16entry:17  %0 = load i8, ptr %a, align 118  %1 = load i8, ptr %b, align 119  %and12 = and i8 %1, %020  %arrayidx.1 = getelementptr inbounds %struct.buf, ptr %a, i64 0, i32 0, i64 121  %2 = load i8, ptr %arrayidx.1, align 122  %arrayidx3.1 = getelementptr inbounds %struct.buf, ptr %b, i64 0, i32 0, i64 123  %3 = load i8, ptr %arrayidx3.1, align 124  %and12.1 = and i8 %3, %225  %4 = xor i8 %and12, %and12.126  %arrayidx.2 = getelementptr inbounds %struct.buf, ptr %a, i64 0, i32 0, i64 227  %5 = load i8, ptr %arrayidx.2, align 128  %arrayidx3.2 = getelementptr inbounds %struct.buf, ptr %b, i64 0, i32 0, i64 229  %6 = load i8, ptr %arrayidx3.2, align 130  %and12.2 = and i8 %6, %531  %7 = xor i8 %4, %and12.232  %arrayidx.3 = getelementptr inbounds %struct.buf, ptr %a, i64 0, i32 0, i64 333  %8 = load i8, ptr %arrayidx.3, align 134  %arrayidx3.3 = getelementptr inbounds %struct.buf, ptr %b, i64 0, i32 0, i64 335  %9 = load i8, ptr %arrayidx3.3, align 136  %and12.3 = and i8 %9, %837  %10 = xor i8 %7, %and12.338  %arrayidx.4 = getelementptr inbounds %struct.buf, ptr %a, i64 0, i32 0, i64 439  %11 = load i8, ptr %arrayidx.4, align 140  %arrayidx3.4 = getelementptr inbounds %struct.buf, ptr %b, i64 0, i32 0, i64 441  %12 = load i8, ptr %arrayidx3.4, align 142  %and12.4 = and i8 %12, %1143  %13 = xor i8 %10, %and12.444  %arrayidx.5 = getelementptr inbounds %struct.buf, ptr %a, i64 0, i32 0, i64 545  %14 = load i8, ptr %arrayidx.5, align 146  %arrayidx3.5 = getelementptr inbounds %struct.buf, ptr %b, i64 0, i32 0, i64 547  %15 = load i8, ptr %arrayidx3.5, align 148  %and12.5 = and i8 %15, %1449  %16 = xor i8 %13, %and12.550  %arrayidx.6 = getelementptr inbounds %struct.buf, ptr %a, i64 0, i32 0, i64 651  %17 = load i8, ptr %arrayidx.6, align 152  %arrayidx3.6 = getelementptr inbounds %struct.buf, ptr %b, i64 0, i32 0, i64 653  %18 = load i8, ptr %arrayidx3.6, align 154  %and12.6 = and i8 %18, %1755  %19 = xor i8 %16, %and12.656  %arrayidx.7 = getelementptr inbounds %struct.buf, ptr %a, i64 0, i32 0, i64 757  %20 = load i8, ptr %arrayidx.7, align 158  %arrayidx3.7 = getelementptr inbounds %struct.buf, ptr %b, i64 0, i32 0, i64 759  %21 = load i8, ptr %arrayidx3.7, align 160  %and12.7 = and i8 %21, %2061  %22 = xor i8 %19, %and12.762  %xor13.7 = xor i8 %22, 163  ret i8 %xor13.764}65