1# NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py
2# RUN: llc --mtriple=amdgcn--amdhsa -mcpu=fiji -run-pass=si-shrink-instructions %s -o - | FileCheck %s
3
4# Make sure flags are preserved when shrinking instructions
5---
6
7name:            shrink_fadd_f32_flags
8tracksRegLiveness: true
9body:             |
10  bb.0:
11    liveins: $vgpr0, $vgpr1
12
13    ; CHECK-LABEL: name: shrink_fadd_f32_flags
14    ; CHECK: liveins: $vgpr0, $vgpr1
15    ; CHECK: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
16    ; CHECK: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr0
17    ; CHECK: %2:vgpr_32 = nnan nofpexcept V_ADD_F32_e32 [[COPY]], [[COPY1]], implicit $mode, implicit $exec
18    ; CHECK: S_NOP 0
19    %0:vgpr_32 = COPY $vgpr0
20    %1:vgpr_32 = COPY $vgpr0
21    %2:vgpr_32 = nofpexcept nnan V_ADD_F32_e64 0, %0, 0, %1, 0, 0, implicit $mode, implicit $exec
22    S_NOP 0
23
24...
25