1 ; RUN: llc < %s -verify-machineinstrs | FileCheck %s
2 target datalayout = "E-m:e-i64:64-n32:64-S128"
3 target triple = "sparcv9"
6 ; This function spills two values: %p and the materialized large constant.
7 ; Both must use 8-byte spill and fill instructions.
8 ; CHECK: stx %{{..}}, [%fp+
9 ; CHECK: stx %{{..}}, [%fp+
12 define void @spill4(ptr nocapture %p) {
14 %val0 = load i64, ptr %p
15 %cmp0 = icmp ult i64 %val0, 385672958347594845
16 %cm80 = zext i1 %cmp0 to i64
17 store i64 %cm80, ptr %p, align 8
18 tail call void asm sideeffect "", "~{i0},~{i1},~{i2},~{i3},~{i4},~{i5},~{g2},~{g3},~{g4},~{g5},~{l0},~{l1},~{l2},~{l3},~{l4},~{l5},~{l6},~{l7},~{o0},~{o1},~{o2},~{o3},~{o4},~{o5},~{o7}"()
19 %arrayidx1 = getelementptr inbounds i64, ptr %p, i64 1
20 %val = load i64, ptr %arrayidx1
21 %cmp = icmp ult i64 %val, 385672958347594845
22 %cm8 = select i1 %cmp, i64 10, i64 20
23 store i64 %cm8, ptr %arrayidx1, align 8