Debian Codegraph @

llvm/test/CodeGen/PowerPC/ppc32-i64-to-float-conv.ll

raw
1 ; RUN: llc -verify-machineinstrs < %s -mcpu=pwr4 -mattr=-altivec \
2 ; RUN: -mtriple=powerpc-ibm-aix-xcoff 2>&1 | FileCheck %s
3
4 ; RUN: llc -verify-machineinstrs < %s -mcpu=pwr4 -mattr=-altivec \
5 ; RUN: -mtriple=powerpc-unknown-linux-gnu 2>&1 | FileCheck %s
6
7 ; When we convert an `i64` to `f32` on 32-bit PPC target, a `setcc` will be
8 ; generated. And this testcase verifies that the operand expansion of `setcc`
9 ; will not crash.
10
11 %struct.A = type { float }
12
13 @ll = external local_unnamed_addr global i64
14 @a = external local_unnamed_addr global %struct.A
15
16 define void @foo() local_unnamed_addr {
17 entry:
18 %0 = load i64, ptr @ll
19 %conv = sitofp i64 %0 to float
20 store float %conv, ptr @a
21 ret void
22 }
23
24 ; CHECK-NOT: Unexpected setcc expansion!