brintos

brintos / llvm-project-archived public Read only

0
0
Text · 6.3 KiB · fafcab8 Raw
134 lines · plain
1; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-gnu -mcpu=pwr7 < %s | FileCheck %s2target datalayout = "E-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-f128:128:128-v128:128:128-n32:64"3target triple = "powerpc64-unknown-linux-gnu"4 5; Function Attrs: nounwind6define void @foo(ptr noalias nocapture %x, ptr noalias nocapture readonly %y) #0 {7entry:8  br label %vector.body9 10vector.body:                                      ; preds = %vector.body, %entry11; CHECK-LABEL: @foo12; CHECK: lvsl13; CHECK: blr14  %index = phi i64 [ 0, %entry ], [ %index.next.15, %vector.body ]15  %0 = getelementptr inbounds float, ptr %y, i64 %index16  %wide.load = load <4 x float>, ptr %0, align 417  %1 = call <4 x float> @llvm_cos_v4f32(<4 x float> %wide.load)18  %2 = getelementptr inbounds float, ptr %x, i64 %index19  store <4 x float> %1, ptr %2, align 420  %index.next = add i64 %index, 421  %3 = getelementptr inbounds float, ptr %y, i64 %index.next22  %wide.load.1 = load <4 x float>, ptr %3, align 423  %4 = call <4 x float> @llvm_cos_v4f32(<4 x float> %wide.load.1)24  %5 = getelementptr inbounds float, ptr %x, i64 %index.next25  store <4 x float> %4, ptr %5, align 426  %index.next.1 = add i64 %index.next, 427  %6 = getelementptr inbounds float, ptr %y, i64 %index.next.128  %wide.load.2 = load <4 x float>, ptr %6, align 429  %7 = call <4 x float> @llvm_cos_v4f32(<4 x float> %wide.load.2)30  %8 = getelementptr inbounds float, ptr %x, i64 %index.next.131  store <4 x float> %7, ptr %8, align 432  %index.next.2 = add i64 %index.next.1, 433  %9 = getelementptr inbounds float, ptr %y, i64 %index.next.234  %wide.load.3 = load <4 x float>, ptr %9, align 435  %10 = call <4 x float> @llvm_cos_v4f32(<4 x float> %wide.load.3)36  %11 = getelementptr inbounds float, ptr %x, i64 %index.next.237  store <4 x float> %10, ptr %11, align 438  %index.next.3 = add i64 %index.next.2, 439  %12 = getelementptr inbounds float, ptr %y, i64 %index.next.340  %wide.load.4 = load <4 x float>, ptr %12, align 441  %13 = call <4 x float> @llvm_cos_v4f32(<4 x float> %wide.load.4)42  %14 = getelementptr inbounds float, ptr %x, i64 %index.next.343  store <4 x float> %13, ptr %14, align 444  %index.next.4 = add i64 %index.next.3, 445  %15 = getelementptr inbounds float, ptr %y, i64 %index.next.446  %wide.load.5 = load <4 x float>, ptr %15, align 447  %16 = call <4 x float> @llvm_cos_v4f32(<4 x float> %wide.load.5)48  %17 = getelementptr inbounds float, ptr %x, i64 %index.next.449  store <4 x float> %16, ptr %17, align 450  %index.next.5 = add i64 %index.next.4, 451  %18 = getelementptr inbounds float, ptr %y, i64 %index.next.552  %wide.load.6 = load <4 x float>, ptr %18, align 453  %19 = call <4 x float> @llvm_cos_v4f32(<4 x float> %wide.load.6)54  %20 = getelementptr inbounds float, ptr %x, i64 %index.next.555  store <4 x float> %19, ptr %20, align 456  %index.next.6 = add i64 %index.next.5, 457  %21 = getelementptr inbounds float, ptr %y, i64 %index.next.658  %wide.load.7 = load <4 x float>, ptr %21, align 459  %22 = call <4 x float> @llvm_cos_v4f32(<4 x float> %wide.load.7)60  %23 = getelementptr inbounds float, ptr %x, i64 %index.next.661  store <4 x float> %22, ptr %23, align 462  %index.next.7 = add i64 %index.next.6, 463  %24 = getelementptr inbounds float, ptr %y, i64 %index.next.764  %wide.load.8 = load <4 x float>, ptr %24, align 465  %25 = call <4 x float> @llvm_cos_v4f32(<4 x float> %wide.load.8)66  %26 = getelementptr inbounds float, ptr %x, i64 %index.next.767  store <4 x float> %25, ptr %26, align 468  %index.next.8 = add i64 %index.next.7, 469  %27 = getelementptr inbounds float, ptr %y, i64 %index.next.870  %wide.load.9 = load <4 x float>, ptr %27, align 471  %28 = call <4 x float> @llvm_cos_v4f32(<4 x float> %wide.load.9)72  %29 = getelementptr inbounds float, ptr %x, i64 %index.next.873  store <4 x float> %28, ptr %29, align 474  %index.next.9 = add i64 %index.next.8, 475  %30 = getelementptr inbounds float, ptr %y, i64 %index.next.976  %wide.load.10 = load <4 x float>, ptr %30, align 477  %31 = call <4 x float> @llvm_cos_v4f32(<4 x float> %wide.load.10)78  %32 = getelementptr inbounds float, ptr %x, i64 %index.next.979  store <4 x float> %31, ptr %32, align 480  %index.next.10 = add i64 %index.next.9, 481  %33 = getelementptr inbounds float, ptr %y, i64 %index.next.1082  %wide.load.11 = load <4 x float>, ptr %33, align 483  %34 = call <4 x float> @llvm_cos_v4f32(<4 x float> %wide.load.11)84  %35 = getelementptr inbounds float, ptr %x, i64 %index.next.1085  store <4 x float> %34, ptr %35, align 486  %index.next.11 = add i64 %index.next.10, 487  %36 = getelementptr inbounds float, ptr %y, i64 %index.next.1188  %wide.load.12 = load <4 x float>, ptr %36, align 489  %37 = call <4 x float> @llvm_cos_v4f32(<4 x float> %wide.load.12)90  %38 = getelementptr inbounds float, ptr %x, i64 %index.next.1191  store <4 x float> %37, ptr %38, align 492  %index.next.12 = add i64 %index.next.11, 493  %39 = getelementptr inbounds float, ptr %y, i64 %index.next.1294  %wide.load.13 = load <4 x float>, ptr %39, align 495  %40 = call <4 x float> @llvm_cos_v4f32(<4 x float> %wide.load.13)96  %41 = getelementptr inbounds float, ptr %x, i64 %index.next.1297  store <4 x float> %40, ptr %41, align 498  %index.next.13 = add i64 %index.next.12, 499  %42 = getelementptr inbounds float, ptr %y, i64 %index.next.13100  %wide.load.14 = load <4 x float>, ptr %42, align 4101  %43 = call <4 x float> @llvm_cos_v4f32(<4 x float> %wide.load.14)102  %44 = getelementptr inbounds float, ptr %x, i64 %index.next.13103  store <4 x float> %43, ptr %44, align 4104  %index.next.14 = add i64 %index.next.13, 4105  %45 = getelementptr inbounds float, ptr %y, i64 %index.next.14106  %wide.load.15 = load <4 x float>, ptr %45, align 4107  %46 = call <4 x float> @llvm_cos_v4f32(<4 x float> %wide.load.15)108  %47 = getelementptr inbounds float, ptr %x, i64 %index.next.14109  store <4 x float> %46, ptr %47, align 4110  %index.next.15 = add i64 %index.next.14, 4111  %48 = icmp eq i64 %index.next.15, 2048112  br i1 %48, label %for.end, label %vector.body113 114for.end:                                          ; preds = %vector.body115  ret void116}117 118; Function Attrs: nounwind readonly119declare <4 x float> @llvm_cos_v4f32(<4 x float>) #1120 121define <2 x double> @bar(ptr %x) {122entry:123  %r = load <2 x double>, ptr %x, align 8124 125; CHECK-LABEL: @bar126; CHECK-NOT: lvsl127; CHECK: blr128 129  ret <2 x double> %r130}131 132attributes #0 = { nounwind }133attributes #1 = { nounwind readonly }134