llvm/llvm/test/CodeGen/RISCV/GlobalISel/legalizer/legalize-implicit-def-rv64.mir

# NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py
# RUN: llc -mtriple=riscv64 -run-pass=legalizer %s -o - \
# RUN: | FileCheck %s
---
name:            implicit_def_i8
body:             |
  bb.0.entry:
    ; CHECK-LABEL: name: implicit_def_i8
    ; CHECK: [[DEF:%[0-9]+]]:_(s64) = G_IMPLICIT_DEF
    ; CHECK-NEXT: $x10 = COPY [[DEF]](s64)
    ; CHECK-NEXT: PseudoRET implicit $x10
    %0:_(s8) = G_IMPLICIT_DEF
    %1:_(s64) = G_ANYEXT %0(s8)
    $x10 = COPY %1(s64)
    PseudoRET implicit $x10

...
---
name:            implicit_def_i15
body:             |
  bb.0.entry:
    ; CHECK-LABEL: name: implicit_def_i15
    ; CHECK: [[DEF:%[0-9]+]]:_(s64) = G_IMPLICIT_DEF
    ; CHECK-NEXT: $x10 = COPY [[DEF]](s64)
    ; CHECK-NEXT: PseudoRET implicit $x10
    %0:_(s15) = G_IMPLICIT_DEF
    %1:_(s64) = G_ANYEXT %0(s15)
    $x10 = COPY %1(s64)
    PseudoRET implicit $x10

...
---
name:            implicit_def_i16
body:             |
  bb.0.entry:
    ; CHECK-LABEL: name: implicit_def_i16
    ; CHECK: [[DEF:%[0-9]+]]:_(s64) = G_IMPLICIT_DEF
    ; CHECK-NEXT: $x10 = COPY [[DEF]](s64)
    ; CHECK-NEXT: PseudoRET implicit $x10
    %0:_(s16) = G_IMPLICIT_DEF
    %1:_(s64) = G_ANYEXT %0(s16)
    $x10 = COPY %1(s64)
    PseudoRET implicit $x10

...
---
name:            implicit_def_i32
body:             |
  bb.0.entry:
    ; CHECK-LABEL: name: implicit_def_i32
    ; CHECK: [[DEF:%[0-9]+]]:_(s64) = G_IMPLICIT_DEF
    ; CHECK-NEXT: $x10 = COPY [[DEF]](s64)
    ; CHECK-NEXT: PseudoRET implicit $x10
    %0:_(s32) = G_IMPLICIT_DEF
    %1:_(s64) = G_ANYEXT %0(s32)
    $x10 = COPY %1(s64)
    PseudoRET implicit $x10

...
---
name:            implicit_def_i64
body:             |
  bb.0.entry:
    ; CHECK-LABEL: name: implicit_def_i64
    ; CHECK: [[DEF:%[0-9]+]]:_(s64) = G_IMPLICIT_DEF
    ; CHECK-NEXT: $x10 = COPY [[DEF]](s64)
    ; CHECK-NEXT: PseudoRET implicit $x10
    %0:_(s64) = G_IMPLICIT_DEF
    $x10 = COPY %0(s64)
    PseudoRET implicit $x10

...
---
name:            implicit_def_i72
body:             |
  bb.0.entry:
    ; CHECK-LABEL: name: implicit_def_i72
    ; CHECK: [[DEF:%[0-9]+]]:_(s64) = G_IMPLICIT_DEF
    ; CHECK-NEXT: $x10 = COPY [[DEF]](s64)
    ; CHECK-NEXT: $x11 = COPY [[DEF]](s64)
    ; CHECK-NEXT: PseudoRET implicit $x10, implicit $x11
    %0:_(s72) = G_IMPLICIT_DEF
    %1:_(s128) = G_ANYEXT %0(s72)
    %2:_(s64), %3:_(s64) = G_UNMERGE_VALUES %1(s128)
    $x10 = COPY %2(s64)
    $x11 = COPY %3(s64)
    PseudoRET implicit $x10, implicit $x11

...
---
name:            implicit_def_i128
body:             |
  bb.0.entry:
    ; CHECK-LABEL: name: implicit_def_i128
    ; CHECK: [[DEF:%[0-9]+]]:_(s64) = G_IMPLICIT_DEF
    ; CHECK-NEXT: $x10 = COPY [[DEF]](s64)
    ; CHECK-NEXT: $x11 = COPY [[DEF]](s64)
    ; CHECK-NEXT: PseudoRET implicit $x10, implicit $x11
    %0:_(s128) = G_IMPLICIT_DEF
    %1:_(s64), %2:_(s64) = G_UNMERGE_VALUES %0(s128)
    $x10 = COPY %1(s64)
    $x11 = COPY %2(s64)
    PseudoRET implicit $x10, implicit $x11

...
---
name:            implicit_def_i192
body:             |
  bb.0.entry:
    ; CHECK-LABEL: name: implicit_def_i192
    ; CHECK: [[DEF:%[0-9]+]]:_(s64) = G_IMPLICIT_DEF
    ; CHECK-NEXT: $x10 = COPY [[DEF]](s64)
    ; CHECK-NEXT: $x11 = COPY [[DEF]](s64)
    ; CHECK-NEXT: $x12 = COPY [[DEF]](s64)
    ; CHECK-NEXT: PseudoRET implicit $x10, implicit $x11, implicit $x12
    %0:_(s192) = G_IMPLICIT_DEF
    %1:_(s64), %2:_(s64), %3:_(s64) = G_UNMERGE_VALUES %0(s192)
    $x10 = COPY %1(s64)
    $x11 = COPY %2(s64)
    $x12 = COPY %3(s64)
    PseudoRET implicit $x10, implicit $x11, implicit $x12

...