1; Test LOCHI/LOCGHI 2; 3; RUN: llc < %s -mtriple=s390x-linux-gnu -mcpu=z13 | FileCheck %s 4 5; CHECK-LABEL: bar1: 6; CHECK: lhi [[REG:%r[0-5]]], 42 7; CHECK: chi %r2, 0 8; CHECK: lochie [[REG]], 0 9define signext i32 @bar1(i32 signext %x) { 10 %cmp = icmp ne i32 %x, 0 11 %.x = select i1 %cmp, i32 42, i32 0 12 ret i32 %.x 13} 14 15; CHECK-LABEL: bar2: 16; CHECK: ltgr [[REG:%r[0-5]]], %r2 17; CHECK: lghi %r2, 42 18; CHECK: locghie %r2, 0 19define signext i64 @bar2(i64 signext %x) { 20 %cmp = icmp ne i64 %x, 0 21 %.x = select i1 %cmp, i64 42, i64 0 22 ret i64 %.x 23} 24