1 ; RUN: opt < %s -S -ipsccp | FileCheck %s
3 target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"
4 target triple = "x86_64-unknown-linux-gnu"
8 %conv = sext i32 undef to i64
9 %div = sdiv i64 8, %conv
10 %call2 = call i64 @fn1(i64 %div)
14 ; CHECK-DAG: define i64 @fn2(
15 ; CHECK: %[[CALL:.*]] = call i64 @fn1(i64 undef)
17 define internal i64 @fn1(i64 %p1) {
19 %tobool = icmp ne i64 %p1, 0
20 %cond = select i1 %tobool, i64 %p1, i64 %p1
24 ; CHECK-DAG: define internal i64 @fn1(
25 ; CHECK: %[[SEL:.*]] = select i1 undef, i64 undef, i64 undef
26 ; CHECK: ret i64 %[[SEL]]