1 ; NOTE: Assertions have been autogenerated by utils/update_test_checks.py UTC_ARGS: --version 4
2 ; RUN: opt -S -passes=loop-reduce -mtriple=x86_64-unknown-linux-gnu < %s | FileCheck %s
4 ; Make sure this does not assert.
6 ; CHECK-LABEL: define void @test() {
8 ; CHECK-NEXT: br label [[FOR_BODY:%.*]]
10 ; CHECK-NEXT: br label [[FOR_BODY]]
16 %0 = phi i64 [ %dec, %for.body ], [ 0, %entry ]
17 %h.18 = phi i32 [ 1, %for.body ], [ 0, %entry ]
20 %1 = trunc i64 %rem to i32
21 %tobool3.not = icmp eq i32 %h.18, %1