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
238 lines
7.5 KiB
YAML
238 lines
7.5 KiB
YAML
# NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py
|
|
# RUN: llc -run-pass=aarch64-prelegalizer-combiner -verify-machineinstrs -mtriple aarch64-unknown-unknown %s -o - | FileCheck %s
|
|
|
|
---
|
|
name: binop_with_neg_or
|
|
tracksRegLiveness: true
|
|
body: |
|
|
bb.0:
|
|
liveins: $x0, $x1, $x2, $x3
|
|
|
|
; CHECK-LABEL: name: binop_with_neg_or
|
|
; CHECK: liveins: $x0, $x1, $x2, $x3
|
|
; CHECK-NEXT: {{ $}}
|
|
; CHECK-NEXT: %a:_(s64) = COPY $x0
|
|
; CHECK-NEXT: %b:_(s64) = COPY $x1
|
|
; CHECK-NEXT: %c:_(s64) = COPY $x2
|
|
; CHECK-NEXT: %mone:_(s64) = G_CONSTANT i64 -1
|
|
; CHECK-NEXT: [[SUB:%[0-9]+]]:_(s64) = G_SUB %b, %c
|
|
; CHECK-NEXT: [[XOR:%[0-9]+]]:_(s64) = G_XOR [[SUB]], %mone
|
|
; CHECK-NEXT: %dst:_(s64) = G_OR %a, [[XOR]]
|
|
; CHECK-NEXT: $x0 = COPY %dst(s64)
|
|
; CHECK-NEXT: RET_ReallyLR implicit $x0
|
|
%a:_(s64) = COPY $x0
|
|
%b:_(s64) = COPY $x1
|
|
%c:_(s64) = COPY $x2
|
|
%mone:_(s64) = G_CONSTANT i64 -1
|
|
%neg_y:_(s64) = G_XOR %mone, %b
|
|
%add:_(s64) = G_ADD %neg_y, %c
|
|
%dst:_(s64) = G_OR %a, %add
|
|
$x0 = COPY %dst
|
|
RET_ReallyLR implicit $x0
|
|
...
|
|
---
|
|
name: binop_with_neg_or_commuted
|
|
tracksRegLiveness: true
|
|
body: |
|
|
bb.0:
|
|
liveins: $x0, $x1, $x2, $x3
|
|
|
|
; CHECK-LABEL: name: binop_with_neg_or_commuted
|
|
; CHECK: liveins: $x0, $x1, $x2, $x3
|
|
; CHECK-NEXT: {{ $}}
|
|
; CHECK-NEXT: %a:_(s64) = COPY $x0
|
|
; CHECK-NEXT: %b:_(s64) = COPY $x1
|
|
; CHECK-NEXT: %c:_(s64) = COPY $x2
|
|
; CHECK-NEXT: %mone:_(s64) = G_CONSTANT i64 -1
|
|
; CHECK-NEXT: [[SUB:%[0-9]+]]:_(s64) = G_SUB %b, %c
|
|
; CHECK-NEXT: [[XOR:%[0-9]+]]:_(s64) = G_XOR [[SUB]], %mone
|
|
; CHECK-NEXT: %dst:_(s64) = G_OR %a, [[XOR]]
|
|
; CHECK-NEXT: $x0 = COPY %dst(s64)
|
|
; CHECK-NEXT: RET_ReallyLR implicit $x0
|
|
%a:_(s64) = COPY $x0
|
|
%b:_(s64) = COPY $x1
|
|
%c:_(s64) = COPY $x2
|
|
%mone:_(s64) = G_CONSTANT i64 -1
|
|
%neg_y:_(s64) = G_XOR %mone, %b
|
|
%add:_(s64) = G_ADD %neg_y, %c
|
|
%dst:_(s64) = G_OR %add, %a
|
|
$x0 = COPY %dst
|
|
RET_ReallyLR implicit $x0
|
|
...
|
|
---
|
|
name: binop_with_neg_xor
|
|
tracksRegLiveness: true
|
|
body: |
|
|
bb.0:
|
|
liveins: $x0, $x1, $x2, $x3
|
|
|
|
; CHECK-LABEL: name: binop_with_neg_xor
|
|
; CHECK: liveins: $x0, $x1, $x2, $x3
|
|
; CHECK-NEXT: {{ $}}
|
|
; CHECK-NEXT: %a:_(s64) = COPY $x0
|
|
; CHECK-NEXT: %b:_(s64) = COPY $x1
|
|
; CHECK-NEXT: %c:_(s64) = COPY $x2
|
|
; CHECK-NEXT: %mone:_(s64) = G_CONSTANT i64 -1
|
|
; CHECK-NEXT: [[SUB:%[0-9]+]]:_(s64) = G_SUB %b, %c
|
|
; CHECK-NEXT: [[XOR:%[0-9]+]]:_(s64) = G_XOR [[SUB]], %mone
|
|
; CHECK-NEXT: %dst:_(s64) = G_XOR %a, [[XOR]]
|
|
; CHECK-NEXT: $x0 = COPY %dst(s64)
|
|
; CHECK-NEXT: RET_ReallyLR implicit $x0
|
|
%a:_(s64) = COPY $x0
|
|
%b:_(s64) = COPY $x1
|
|
%c:_(s64) = COPY $x2
|
|
%mone:_(s64) = G_CONSTANT i64 -1
|
|
%neg_y:_(s64) = G_XOR %mone, %b
|
|
%add:_(s64) = G_ADD %neg_y, %c
|
|
%dst:_(s64) = G_XOR %a, %add
|
|
$x0 = COPY %dst
|
|
RET_ReallyLR implicit $x0
|
|
...
|
|
---
|
|
name: binop_with_neg_xor_commuted
|
|
tracksRegLiveness: true
|
|
body: |
|
|
bb.0:
|
|
liveins: $x0, $x1, $x2, $x3
|
|
|
|
; CHECK-LABEL: name: binop_with_neg_xor_commuted
|
|
; CHECK: liveins: $x0, $x1, $x2, $x3
|
|
; CHECK-NEXT: {{ $}}
|
|
; CHECK-NEXT: %a:_(s64) = COPY $x0
|
|
; CHECK-NEXT: %b:_(s64) = COPY $x1
|
|
; CHECK-NEXT: %c:_(s64) = COPY $x2
|
|
; CHECK-NEXT: %mone:_(s64) = G_CONSTANT i64 -1
|
|
; CHECK-NEXT: [[SUB:%[0-9]+]]:_(s64) = G_SUB %b, %c
|
|
; CHECK-NEXT: [[XOR:%[0-9]+]]:_(s64) = G_XOR [[SUB]], %mone
|
|
; CHECK-NEXT: %dst:_(s64) = G_XOR %a, [[XOR]]
|
|
; CHECK-NEXT: $x0 = COPY %dst(s64)
|
|
; CHECK-NEXT: RET_ReallyLR implicit $x0
|
|
%a:_(s64) = COPY $x0
|
|
%b:_(s64) = COPY $x1
|
|
%c:_(s64) = COPY $x2
|
|
%mone:_(s64) = G_CONSTANT i64 -1
|
|
%neg_y:_(s64) = G_XOR %mone, %b
|
|
%add:_(s64) = G_ADD %c, %neg_y
|
|
%dst:_(s64) = G_XOR %add, %a
|
|
$x0 = COPY %dst
|
|
RET_ReallyLR implicit $x0
|
|
...
|
|
---
|
|
name: binop_with_neg_and
|
|
tracksRegLiveness: true
|
|
body: |
|
|
bb.0:
|
|
liveins: $x0, $x1, $x2, $x3
|
|
|
|
; CHECK-LABEL: name: binop_with_neg_and
|
|
; CHECK: liveins: $x0, $x1, $x2, $x3
|
|
; CHECK-NEXT: {{ $}}
|
|
; CHECK-NEXT: %a:_(s64) = COPY $x0
|
|
; CHECK-NEXT: %b:_(s64) = COPY $x1
|
|
; CHECK-NEXT: %c:_(s64) = COPY $x2
|
|
; CHECK-NEXT: %mone:_(s64) = G_CONSTANT i64 -1
|
|
; CHECK-NEXT: [[SUB:%[0-9]+]]:_(s64) = G_SUB %b, %c
|
|
; CHECK-NEXT: [[XOR:%[0-9]+]]:_(s64) = G_XOR [[SUB]], %mone
|
|
; CHECK-NEXT: %dst:_(s64) = G_AND %a, [[XOR]]
|
|
; CHECK-NEXT: $x0 = COPY %dst(s64)
|
|
; CHECK-NEXT: RET_ReallyLR implicit $x0
|
|
%a:_(s64) = COPY $x0
|
|
%b:_(s64) = COPY $x1
|
|
%c:_(s64) = COPY $x2
|
|
%mone:_(s64) = G_CONSTANT i64 -1
|
|
%neg_y:_(s64) = G_XOR %mone, %b
|
|
%add:_(s64) = G_ADD %neg_y, %c
|
|
%dst:_(s64) = G_AND %a, %add
|
|
$x0 = COPY %dst
|
|
RET_ReallyLR implicit $x0
|
|
...
|
|
---
|
|
name: binop_with_neg_and_commuted_and
|
|
tracksRegLiveness: true
|
|
body: |
|
|
bb.0:
|
|
liveins: $x0, $x1, $x2, $x3
|
|
|
|
; CHECK-LABEL: name: binop_with_neg_and_commuted_and
|
|
; CHECK: liveins: $x0, $x1, $x2, $x3
|
|
; CHECK-NEXT: {{ $}}
|
|
; CHECK-NEXT: %a:_(s64) = COPY $x0
|
|
; CHECK-NEXT: %b:_(s64) = COPY $x1
|
|
; CHECK-NEXT: %c:_(s64) = COPY $x2
|
|
; CHECK-NEXT: %mone:_(s64) = G_CONSTANT i64 -1
|
|
; CHECK-NEXT: [[SUB:%[0-9]+]]:_(s64) = G_SUB %b, %c
|
|
; CHECK-NEXT: [[XOR:%[0-9]+]]:_(s64) = G_XOR [[SUB]], %mone
|
|
; CHECK-NEXT: %dst:_(s64) = G_AND %a, [[XOR]]
|
|
; CHECK-NEXT: $x0 = COPY %dst(s64)
|
|
; CHECK-NEXT: RET_ReallyLR implicit $x0
|
|
%a:_(s64) = COPY $x0
|
|
%b:_(s64) = COPY $x1
|
|
%c:_(s64) = COPY $x2
|
|
%mone:_(s64) = G_CONSTANT i64 -1
|
|
%neg_y:_(s64) = G_XOR %mone, %b
|
|
%add:_(s64) = G_ADD %c, %neg_y
|
|
%dst:_(s64) = G_AND %add, %a
|
|
$x0 = COPY %dst
|
|
RET_ReallyLR implicit $x0
|
|
...
|
|
---
|
|
name: binop_with_neg_and_commuted_add
|
|
tracksRegLiveness: true
|
|
body: |
|
|
bb.0:
|
|
liveins: $x0, $x1, $x2, $x3
|
|
|
|
; CHECK-LABEL: name: binop_with_neg_and_commuted_add
|
|
; CHECK: liveins: $x0, $x1, $x2, $x3
|
|
; CHECK-NEXT: {{ $}}
|
|
; CHECK-NEXT: %a:_(s64) = COPY $x0
|
|
; CHECK-NEXT: %b:_(s64) = COPY $x1
|
|
; CHECK-NEXT: %c:_(s64) = COPY $x2
|
|
; CHECK-NEXT: %mone:_(s64) = G_CONSTANT i64 -1
|
|
; CHECK-NEXT: [[SUB:%[0-9]+]]:_(s64) = G_SUB %b, %c
|
|
; CHECK-NEXT: [[XOR:%[0-9]+]]:_(s64) = G_XOR [[SUB]], %mone
|
|
; CHECK-NEXT: %dst:_(s64) = G_AND %a, [[XOR]]
|
|
; CHECK-NEXT: $x0 = COPY %dst(s64)
|
|
; CHECK-NEXT: RET_ReallyLR implicit $x0
|
|
%a:_(s64) = COPY $x0
|
|
%b:_(s64) = COPY $x1
|
|
%c:_(s64) = COPY $x2
|
|
%mone:_(s64) = G_CONSTANT i64 -1
|
|
%neg_y:_(s64) = G_XOR %mone, %b
|
|
%add:_(s64) = G_ADD %c, %neg_y
|
|
%dst:_(s64) = G_AND %a, %add
|
|
$x0 = COPY %dst
|
|
RET_ReallyLR implicit $x0
|
|
...
|
|
---
|
|
name: binop_with_neg_and_one_use
|
|
tracksRegLiveness: true
|
|
body: |
|
|
bb.0:
|
|
liveins: $x0, $x1, $x2, $x3
|
|
|
|
; CHECK-LABEL: name: binop_with_neg_and_one_use
|
|
; CHECK: liveins: $x0, $x1, $x2, $x3
|
|
; CHECK-NEXT: {{ $}}
|
|
; CHECK-NEXT: %a:_(s64) = COPY $x0
|
|
; CHECK-NEXT: %b:_(s64) = COPY $x1
|
|
; CHECK-NEXT: %c:_(s64) = COPY $x2
|
|
; CHECK-NEXT: %mone:_(s64) = G_CONSTANT i64 -1
|
|
; CHECK-NEXT: %neg_y:_(s64) = G_XOR %b, %mone
|
|
; CHECK-NEXT: %add:_(s64) = G_ADD %neg_y, %c
|
|
; CHECK-NEXT: %dst:_(s64) = G_AND %a, %add
|
|
; CHECK-NEXT: %and2:_(s64) = G_AND %neg_y, %dst
|
|
; CHECK-NEXT: $x0 = COPY %and2(s64)
|
|
; CHECK-NEXT: RET_ReallyLR implicit $x0
|
|
%a:_(s64) = COPY $x0
|
|
%b:_(s64) = COPY $x1
|
|
%c:_(s64) = COPY $x2
|
|
%mone:_(s64) = G_CONSTANT i64 -1
|
|
%neg_y:_(s64) = G_XOR %mone, %b
|
|
%add:_(s64) = G_ADD %neg_y, %c
|
|
%dst:_(s64) = G_AND %a, %add
|
|
%and2:_(s64) = G_AND %neg_y, %dst
|
|
$x0 = COPY %and2
|
|
RET_ReallyLR implicit $x0
|
|
...
|