[llvm] r364350 - [PowerPC][NFC]Add a test for MachinePipeliner bug

Jinsong Ji via llvm-commits llvm-commits at lists.llvm.org
Tue Jun 25 13:56:17 PDT 2019


Author: jsji
Date: Tue Jun 25 13:56:17 2019
New Revision: 364350

URL: http://llvm.org/viewvc/llvm-project?rev=364350&view=rev
Log:
[PowerPC][NFC]Add a test for MachinePipeliner bug

Added:
    llvm/trunk/test/CodeGen/PowerPC/sms-iterator.ll

Added: llvm/trunk/test/CodeGen/PowerPC/sms-iterator.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/PowerPC/sms-iterator.ll?rev=364350&view=auto
==============================================================================
--- llvm/trunk/test/CodeGen/PowerPC/sms-iterator.ll (added)
+++ llvm/trunk/test/CodeGen/PowerPC/sms-iterator.ll Tue Jun 25 13:56:17 2019
@@ -0,0 +1,36 @@
+; REQUIRES: asserts
+; RUN: llc < %s -mtriple=powerpc64le-unknown-linux-gnu -verify-machineinstrs\
+; RUN:       -mcpu=pwr9 --ppc-enable-pipeliner -debug-only=pipeliner 2>&1 \
+; RUN:       >/dev/null | FileCheck %s
+
+%0 = type { i32, [16 x double] }
+
+; CHECK: MII = 7 MAX_II = 17
+
+define dso_local fastcc void @_ZN3povL9polysolveEiPdS0_() unnamed_addr #0 {
+  br label %1
+
+1:                                                ; preds = %1, %0
+  br i1 undef, label %2, label %1
+
+2:                                                ; preds = %1
+  br i1 undef, label %14, label %3
+
+3:                                                ; preds = %3, %2
+  %4 = phi i64 [ %7, %3 ], [ undef, %2 ]
+  %5 = phi double [ %11, %3 ], [ undef, %2 ]
+  %6 = phi i64 [ %12, %3 ], [ undef, %2 ]
+  %7 = add nsw i64 %4, -1
+  %8 = fmul fast double %5, 1.000000e+07
+  %9 = getelementptr inbounds %0, %0* null, i64 1, i32 1, i64 %7
+  %10 = load double, double* %9, align 8
+  %11 = fadd fast double %10, %8
+  %12 = add i64 %6, -1
+  %13 = icmp eq i64 %12, 0
+  br i1 %13, label %14, label %3
+
+14:                                               ; preds = %3, %2
+  %15 = phi double [ undef, %2 ], [ %11, %3 ]
+  %16 = fmul fast double %15, undef
+  ret void
+}




More information about the llvm-commits mailing list