Files
derek.holloway 7502bf64a4
CodeQL / Analyze (actions) (push) Canceled after 0s
CodeQL / Analyze (python) (push) Canceled after 0s
pre-commit / pre-commit (push) Canceled after 0s
Multi-Arch CI / setup (push) Canceled after 0s
Publish build_manylinux_x86_64 images / publish_build_manylinux_x86_64 (push) Canceled after 0s
Setup (Multi-Arch) / setup (push) Canceled after 0s
Multi-Arch CI / Linux::${{ fromJSON(needs.setup.outputs.linux_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubi10 image / publish_no_rocm_image_ubi10 (push) Canceled after 0s
Multi-Arch CI / Windows::${{ fromJSON(needs.setup.outputs.windows_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Multi-Arch CI / Manifest Diff (push) Canceled after 0s
TheRock Manifest Diff Report / Generate Manifest Diff Report (push) Canceled after 0s
Multi-Arch CI / CI Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_ocl_rt images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_rocgdb images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Unit Tests / Unit Tests :: ubuntu-24.04 (push) Canceled after 0s
Unit Tests / Unit Tests :: windows-2022 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_media (push) Canceled after 0s
Unit Tests / Unit Tests Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_openmpi (push) Canceled after 0s
Flatten subprojects into a single base monorepo
2026-09-02 16:34:47 -07:00

298 lines
8.5 KiB
YAML

# NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py
# RUN: llc -O3 -verify-machineinstrs -mtriple=powerpc64le-unknown-unknown \
# RUN: -mcpu=pwr9 -simplify-mir -run-pass=machine-cp %s -o - | FileCheck %s
# Normal case
---
name: test0
alignment: 4
tracksRegLiveness: true
body: |
bb.0.entry:
; CHECK-LABEL: name: test0
; CHECK: $x3 = LI8 1024
; CHECK: BLR8 implicit $lr8, implicit undef $rm, implicit $x3
renamable $x4 = LI8 1024
$x3 = COPY renamable killed $x4
BLR8 implicit $lr8, implicit undef $rm, implicit $x3
...
# Not in terminal BBs
---
name: test1
alignment: 4
tracksRegLiveness: true
body: |
; CHECK-LABEL: name: test1
; CHECK: bb.0.entry:
; CHECK: renamable $x4 = LI8 42
; CHECK: B %bb.1
; CHECK: bb.1:
; CHECK: liveins: $x4
; CHECK: $x3 = COPY killed renamable $x4
; CHECK: BLR8 implicit $lr8, implicit undef $rm, implicit $x3
bb.0.entry:
successors: %bb.1
renamable $x5 = LI8 42
renamable $x4 = COPY renamable killed $x5
B %bb.1
bb.1:
liveins: $x4
$x3 = COPY renamable killed $x4
BLR8 implicit $lr8, implicit undef $rm, implicit $x3
...
# Use reserved register
---
name: test2
alignment: 4
tracksRegLiveness: true
body: |
bb.0.entry:
; CHECK-LABEL: name: test2
; CHECK: renamable $x4 = LI8 1024
; CHECK: $x13 = COPY killed renamable $x4
; CHECK: BLR8 implicit $lr8, implicit undef $rm, implicit undef $x3
renamable $x4 = LI8 1024
$x13 = COPY renamable killed $x4
BLR8 implicit $lr8, implicit undef $rm, implicit undef $x3
...
# Intermediate read of copy's src
---
name: test3
alignment: 4
tracksRegLiveness: true
body: |
bb.0.entry:
; CHECK-LABEL: name: test3
; CHECK: renamable $x4 = LI8 0
; CHECK: renamable $x5 = ADDI8 $x4, 1
; CHECK: $x3 = COPY killed renamable $x4
; CHECK: BLR8 implicit $lr8, implicit undef $rm, implicit $x3
renamable $x4 = LI8 0
renamable $x5 = ADDI8 $x4, 1
$x3 = COPY renamable killed $x4
BLR8 implicit $lr8, implicit undef $rm, implicit $x3
...
# Intermediate read of copy's def
---
name: test4
alignment: 4
tracksRegLiveness: true
body: |
bb.0.entry:
liveins: $x3
; CHECK-LABEL: name: test4
; CHECK: liveins: $x3
; CHECK: renamable $x4 = LI8 0
; CHECK: renamable $x5 = ADDI8 $x3, 1
; CHECK: $x3 = COPY killed renamable $x4
; CHECK: BLR8 implicit $lr8, implicit undef $rm, implicit $x3
renamable $x4 = LI8 0
renamable $x5 = ADDI8 $x3, 1
$x3 = COPY renamable killed $x4
BLR8 implicit $lr8, implicit undef $rm, implicit $x3
...
# Intermiediate clobber of copy's def
---
name: test5
alignment: 4
tracksRegLiveness: true
body: |
bb.0.entry:
liveins: $x3, $x5
; CHECK-LABEL: name: test5
; CHECK: liveins: $x3, $x5
; CHECK: renamable $x4 = LI8 0
; CHECK: renamable $x3 = ADDI8 $x5, 1
; CHECK: $x3 = COPY killed renamable $x4
; CHECK: BLR8 implicit $lr8, implicit undef $rm, implicit $x3
renamable $x4 = LI8 0
renamable $x3 = ADDI8 $x5, 1
$x3 = COPY renamable killed $x4
BLR8 implicit $lr8, implicit undef $rm, implicit $x3
...
---
name: iterative_deletion
alignment: 4
tracksRegLiveness: true
body: |
bb.0.entry:
liveins: $x5
; CHECK-LABEL: name: iterative_deletion
; CHECK: liveins: $x5
; CHECK: renamable $x4 = ADDI8 killed renamable $x5, 1
; CHECK: $x3 = COPY $x4
; CHECK: BLR8 implicit $lr8, implicit undef $rm, implicit $x3
renamable $x6 = ADDI8 renamable killed $x5, 1
renamable $x4 = COPY renamable killed $x6
renamable $x7 = COPY renamable killed $x4
$x3 = COPY renamable killed $x7
BLR8 implicit $lr8, implicit undef $rm, implicit $x3
...
---
name: Enter
alignment: 4
tracksRegLiveness: true
body: |
bb.0.entry:
liveins: $x4, $x7
; CHECK-LABEL: name: Enter
; CHECK: liveins: $x4, $x7
; CHECK: renamable $x5 = COPY killed renamable $x7
; CHECK: renamable $x7 = ADDI8 killed renamable $x4, 1
; CHECK: $x3 = ADD8 killed renamable $x5, killed renamable $x7
; CHECK: BLR8 implicit $lr8, implicit undef $rm, implicit $x3
renamable $x5 = COPY killed renamable $x7
renamable $x6 = ADDI8 killed renamable $x4, 1
renamable $x7 = COPY killed renamable $x6
$x3 = ADD8 renamable killed $x5, renamable killed $x7
BLR8 implicit $lr8, implicit undef $rm, implicit $x3
...
---
name: foo
alignment: 4
tracksRegLiveness: true
body: |
bb.0.entry:
liveins: $x4, $x7
; CHECK-LABEL: name: foo
; CHECK: liveins: $x4, $x7
; CHECK: renamable $x5 = COPY killed renamable $x7
; CHECK: renamable $x7 = ADDI8 renamable $x4, 1
; CHECK: renamable $x6 = ADDI8 killed $x4, 2
; CHECK: $x3 = ADD8 killed renamable $x5, killed renamable $x6
; CHECK: $x3 = ADD8 $x3, killed renamable $x7
; CHECK: BLR8 implicit $lr8, implicit undef $rm, implicit $x3
renamable $x5 = COPY killed renamable $x7
renamable $x6 = ADDI8 renamable $x4, 1
renamable $x7 = COPY killed renamable $x6
renamable $x8 = ADDI8 killed $x4, 2
renamable $x6 = COPY killed renamable $x8
$x3 = ADD8 renamable killed $x5, renamable killed $x6
$x3 = ADD8 $x3, renamable killed $x7
BLR8 implicit $lr8, implicit undef $rm, implicit $x3
...
---
name: bar
alignment: 4
tracksRegLiveness: true
body: |
bb.0.entry:
liveins: $x4, $x7
; CHECK-LABEL: name: bar
; CHECK: liveins: $x4, $x7
; CHECK: renamable $x5 = COPY killed renamable $x7
; CHECK: renamable $x7 = ADDI8 renamable $x4, 1
; CHECK: renamable $x8 = COPY killed renamable $x7
; CHECK: renamable $x7 = ADDI8 renamable $x5, 2
; CHECK: $x3 = ADD8 killed renamable $x5, killed renamable $x7
; CHECK: $x3 = ADD8 $x3, killed renamable $x8
; CHECK: BLR8 implicit $lr8, implicit undef $rm, implicit $x3
renamable $x5 = COPY killed renamable $x7
renamable $x6 = ADDI8 renamable $x4, 1
renamable $x7 = COPY killed renamable $x6
renamable $x8 = COPY killed renamable $x7
renamable $x6 = ADDI8 renamable $x5, 2
renamable $x7 = COPY killed renamable $x6
$x3 = ADD8 renamable killed $x5, renamable killed $x7
$x3 = ADD8 $x3, renamable killed $x8
BLR8 implicit $lr8, implicit undef $rm, implicit $x3
...
---
name: bogus
alignment: 4
tracksRegLiveness: true
body: |
bb.0.entry:
liveins: $x7
; CHECK-LABEL: name: bogus
; CHECK: liveins: $x7
; CHECK: renamable $x5 = COPY renamable $x7
; CHECK: renamable $x4 = ADDI8 $x7, 1
; CHECK: renamable $x6 = ADDI8 renamable $x5, 2
; CHECK: $x3 = ADD8 killed renamable $x4, killed renamable $x5
; CHECK: $x3 = ADD8 $x3, killed renamable $x6
; CHECK: BLR8 implicit $lr8, implicit undef $rm, implicit $x3
renamable $x5 = COPY killed renamable $x7
renamable $x6 = ADDI8 renamable $x5, 1
renamable $x4 = COPY killed renamable $x6
renamable $x7 = COPY killed renamable $x4
renamable $x6 = ADDI8 renamable $x5, 2
renamable $x4 = COPY killed renamable $x7
$x3 = ADD8 renamable killed $x4, renamable killed $x5
$x3 = ADD8 $x3, renamable killed $x6
BLR8 implicit $lr8, implicit undef $rm, implicit $x3
...
---
name: foobar
alignment: 4
tracksRegLiveness: true
body: |
bb.0.entry:
liveins: $x7
; CHECK-LABEL: name: foobar
; CHECK: liveins: $x7
; CHECK: renamable $x4 = ADDI8 $x7, 1
; CHECK: renamable $x8 = COPY killed renamable $x4
; CHECK: renamable $x4 = ADDI8 $x7, 2
; CHECK: $x3 = ADD8 killed renamable $x4, $x7
; CHECK: $x3 = ADD8 $x3, killed renamable $x8
; CHECK: BLR8 implicit $lr8, implicit undef $rm, implicit $x3
renamable $x5 = COPY killed renamable $x7
renamable $x6 = ADDI8 renamable $x5, 1
renamable $x4 = COPY killed renamable $x6
renamable $x8 = COPY killed renamable $x4
renamable $x6 = ADDI8 renamable $x5, 2
renamable $x4 = COPY killed renamable $x6
$x3 = ADD8 renamable killed $x4, renamable killed $x5
$x3 = ADD8 $x3, renamable killed $x8
BLR8 implicit $lr8, implicit undef $rm, implicit $x3
...
---
name: cross_call
alignment: 4
tracksRegLiveness: true
body: |
bb.0.entry:
liveins: $x2, $x3, $x20
; CHECK-LABEL: name: cross_call
; CHECK: liveins: $x2, $x3, $x20
; CHECK: renamable $x20 = LI8 1024
; CHECK: BL8_NOP @foo, csr_ppc64_altivec, implicit-def $lr8, implicit $rm, implicit $x3, implicit-def $x3, implicit $x2
; CHECK: $x3 = COPY killed renamable $x20
; CHECK: BLR8 implicit $lr8, implicit undef $rm, implicit $x3
renamable $x20 = LI8 1024
BL8_NOP @foo, csr_ppc64_altivec, implicit-def $lr8, implicit $rm, implicit $x3, implicit-def $x3, implicit $x2
$x3 = COPY renamable killed $x20
BLR8 implicit $lr8, implicit undef $rm, implicit $x3
...