https://bugs.llvm.org/show_bug.cgi?id=49509

            Bug ID: 49509
           Summary: [PowerPC] Infinite loop in PeepholeCROps
           Product: libraries
           Version: trunk
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: Backend: PowerPC
          Assignee: unassignedb...@nondot.org
          Reporter: nikita....@gmail.com
                CC: llvm-bugs@lists.llvm.org, nemanja.i....@gmail.com

; RUN: llc -O2 < %s

target datalayout = "E-m:e-p:32:32-i64:64-n32"
target triple = "powerpc-unknown-linux-gnu"

define void @test() {
bb:
  br i1 undef, label %bb2, label %bb1

bb2:                                              ; preds = %bb
  %i = select i1 undef, i64 0, i64 72057594037927936
  store i64 %i, i64* undef, align 8
  ret void

bb1:                                              ; preds = %bb
  %i50 = load i8, i8* undef, align 8
  %i52 = load i128, i128* null, align 8
  %i62 = icmp eq i8 %i50, 0
  br i1 undef, label %bb66, label %bb64

bb64:                                             ; preds = %bb63
  ret void

bb66:                                             ; preds = %bb63
  %i67 = lshr i128 -1, 0
  %i68 = xor i128 %i52, -1
  %i69 = add i128 0, %i68
  %i70 = and i128 %i67, %i69
  %i71 = icmp eq i128 %i70, 0
  %i74 = select i1 %i62, i64 0, i64 72057594037927936
  %i75 = select i1 %i71, i64 144115188075855872, i64 %i74
  store i64 %i75, i64* undef, align 8
  ret void
}

This enters an infinite combine loop inside PPCDAGToDAGISel::PeepholeCROps().

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to