11# RUN: llc -simplify-mir -mtriple=amdgcn -mcpu=gfx900 -run-pass=si-shrink-instructions -verify-machineinstrs %s -o - | FileCheck -check-prefix=GCN %s
2+ # RUN: llc -simplify-mir -mtriple=amdgcn -mcpu=gfx900 -passes=si-shrink-instructions -verify-machineinstrs %s -o - | FileCheck -check-prefix=GCN %s
23
34# GCN-LABEL: name: swap_phys_condensed
45# GCN: bb.0:
56# GCN-NEXT: liveins:
67# GCN-NEXT: {{^[ ]*$}}
8+ # GCN-NEXT: $vgpr2 = V_MOV_B32_e32 $vgpr0, implicit $exec
79# GCN-NEXT: $vgpr0, $vgpr1 = V_SWAP_B32 $vgpr1, $vgpr0, implicit $exec
810# GCN-NEXT: S_SETPC_B64_return
911---
@@ -22,6 +24,7 @@ body: |
2224# GCN: bb.0:
2325# GCN-NEXT: liveins:
2426# GCN-NEXT: {{^[ ]*$}}
27+ # GCN-NEXT: $vgpr2 = V_MOV_B32_e32 $vgpr0, implicit $exec
2528# GCN-NEXT: $vgpr3 = V_MOV_B32_e32 killed $vgpr4, implicit $exec
2629# GCN-NEXT: $vgpr0, $vgpr1 = V_SWAP_B32 $vgpr1, $vgpr0, implicit $exec
2730# GCN-NEXT: $vgpr5 = V_MOV_B32_e32 killed $vgpr6, implicit $exec
@@ -44,6 +47,7 @@ body: |
4447# GCN: bb.0:
4548# GCN-NEXT: liveins:
4649# GCN-NEXT: {{^[ ]*$}}
50+ # GCN-NEXT: $vgpr2 = V_MOV_B32_e32 $vgpr0, implicit $exec
4751# GCN-NEXT: $vgpr0, $vgpr1 = V_SWAP_B32 $vgpr1, $vgpr0, implicit $exec
4852# GCN-NEXT: S_SETPC_B64_return
4953---
@@ -62,6 +66,7 @@ body: |
6266# GCN: bb.0:
6367# GCN-NEXT: liveins:
6468# GCN-NEXT: {{^[ ]*$}}
69+ # GCN-NEXT: $vgpr2 = V_MOV_B32_e32 $vgpr0, implicit $exec
6570# GCN-NEXT: $vgpr0, $vgpr1 = V_SWAP_B32 $vgpr1, $vgpr0, implicit $exec
6671# GCN-NEXT: S_SETPC_B64_return
6772---
@@ -80,6 +85,7 @@ body: |
8085# GCN: bb.0:
8186# GCN-NEXT: liveins:
8287# GCN-NEXT: {{^[ ]*$}}
88+ # GCN-NEXT: $vgpr4_vgpr5 = COPY $vgpr0_vgpr1
8389# GCN-NEXT: $vgpr0, $vgpr2 = V_SWAP_B32 $vgpr2, $vgpr0, implicit $exec
8490# GCN-NEXT: $vgpr1, $vgpr3 = V_SWAP_B32 $vgpr3, $vgpr1, implicit $exec
8591---
@@ -930,7 +936,8 @@ body: |
930936 ...
931937
932938# GCN-LABEL: implicit_ops_mov_t_swap_b32
933- # GCN: $vgpr0, $vgpr1 = V_SWAP_B32 $vgpr1, $vgpr0, implicit $exec
939+ # GCN: $vgpr3 = V_MOV_B32_e32 $vgpr0, implicit $exec, implicit $vgpr2, implicit killed $vgpr1_vgpr2, implicit-def $vgpr1
940+ # GCN-NEXT: $vgpr0, $vgpr1 = V_SWAP_B32 $vgpr1, $vgpr0, implicit $exec
934941
935942---
936943name : implicit_ops_mov_t_swap_b32
0 commit comments