llvm/llvm/test/CodeGen/PowerPC/peephole-combineRLWINM-liveness.mir

# RUN: llc -mtriple=powerpc-ibm-aix -verify-machineinstrs -run-pass=ppc-mi-peepholes -o - %s | FileCheck %s
# RUN: llc -mtriple=powerpc64-ibm-aix -verify-machineinstrs -run-pass=ppc-mi-peepholes -o - %s | FileCheck %s
# RUN: llc -mtriple=powerpc64-linux-gnu -verify-machineinstrs -run-pass=ppc-mi-peepholes -o - %s | FileCheck %s
---

name: testFoldRLWINM
tracksRegLiveness: true

body: |
  bb.0.entry:
    liveins: $r3
    %0:gprc = COPY $r3
    B %bb.1
  bb.1:
    B %bb.2
  bb.2:
    %1:gprc = RLWINM killed %0:gprc, 1, 0, 30
    %2:gprc = RLWINM killed %1:gprc, 31, 0, 0
    BLR8 implicit $lr8, implicit $rm

...

# CHECK-LABEL: testFoldRLWINM
# CHECK:       bb.0.entry:
# CHECK:         dead %0:gprc = COPY killed $r3
# CHECK:       bb.2:
# CHECK:         dead %2:gprc = LI 0