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

92 lines
3.8 KiB
LLVM

; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
; RUN: llc --mtriple=loongarch64 --mattr=+f,+d < %s | FileCheck %s --check-prefix=LA64
; Check the GHC call convention works (la64)
@base = external dso_local global i64 ; assigned to register: s0
@sp = external dso_local global i64 ; assigned to register: s1
@hp = external dso_local global i64 ; assigned to register: s2
@r1 = external dso_local global i64 ; assigned to register: s3
@r2 = external dso_local global i64 ; assigned to register: s4
@r3 = external dso_local global i64 ; assigned to register: s5
@r4 = external dso_local global i64 ; assigned to register: s6
@r5 = external dso_local global i64 ; assigned to register: s7
@splim = external dso_local global i64 ; assigned to register: s8
@f1 = external dso_local global float ; assigned to register: fs0
@f2 = external dso_local global float ; assigned to register: fs1
@f3 = external dso_local global float ; assigned to register: fs2
@f4 = external dso_local global float ; assigned to register: fs3
@d1 = external dso_local global double ; assigned to register: fs4
@d2 = external dso_local global double ; assigned to register: fs5
@d3 = external dso_local global double ; assigned to register: fs6
@d4 = external dso_local global double ; assigned to register: fs7
define ghccc void @foo() nounwind {
; LA64-LABEL: foo:
; LA64: # %bb.0: # %entry
; LA64-NEXT: pcalau12i $a0, %pc_hi20(d4)
; LA64-NEXT: fld.d $fs7, $a0, %pc_lo12(d4)
; LA64-NEXT: pcalau12i $a0, %pc_hi20(d3)
; LA64-NEXT: fld.d $fs6, $a0, %pc_lo12(d3)
; LA64-NEXT: pcalau12i $a0, %pc_hi20(d2)
; LA64-NEXT: fld.d $fs5, $a0, %pc_lo12(d2)
; LA64-NEXT: pcalau12i $a0, %pc_hi20(d1)
; LA64-NEXT: fld.d $fs4, $a0, %pc_lo12(d1)
; LA64-NEXT: pcalau12i $a0, %pc_hi20(f4)
; LA64-NEXT: fld.s $fs3, $a0, %pc_lo12(f4)
; LA64-NEXT: pcalau12i $a0, %pc_hi20(f3)
; LA64-NEXT: fld.s $fs2, $a0, %pc_lo12(f3)
; LA64-NEXT: pcalau12i $a0, %pc_hi20(f2)
; LA64-NEXT: fld.s $fs1, $a0, %pc_lo12(f2)
; LA64-NEXT: pcalau12i $a0, %pc_hi20(f1)
; LA64-NEXT: fld.s $fs0, $a0, %pc_lo12(f1)
; LA64-NEXT: pcalau12i $a0, %pc_hi20(splim)
; LA64-NEXT: ld.d $s8, $a0, %pc_lo12(splim)
; LA64-NEXT: pcalau12i $a0, %pc_hi20(r5)
; LA64-NEXT: ld.d $s7, $a0, %pc_lo12(r5)
; LA64-NEXT: pcalau12i $a0, %pc_hi20(r4)
; LA64-NEXT: ld.d $s6, $a0, %pc_lo12(r4)
; LA64-NEXT: pcalau12i $a0, %pc_hi20(r3)
; LA64-NEXT: ld.d $s5, $a0, %pc_lo12(r3)
; LA64-NEXT: pcalau12i $a0, %pc_hi20(r2)
; LA64-NEXT: ld.d $s4, $a0, %pc_lo12(r2)
; LA64-NEXT: pcalau12i $a0, %pc_hi20(r1)
; LA64-NEXT: ld.d $s3, $a0, %pc_lo12(r1)
; LA64-NEXT: pcalau12i $a0, %pc_hi20(hp)
; LA64-NEXT: ld.d $s2, $a0, %pc_lo12(hp)
; LA64-NEXT: pcalau12i $a0, %pc_hi20(sp)
; LA64-NEXT: ld.d $s1, $a0, %pc_lo12(sp)
; LA64-NEXT: pcalau12i $a0, %pc_hi20(base)
; LA64-NEXT: ld.d $s0, $a0, %pc_lo12(base)
; LA64-NEXT: pcaddu18i $t8, %call36(bar)
; LA64-NEXT: jr $t8
entry:
%0 = load double, ptr @d4
%1 = load double, ptr @d3
%2 = load double, ptr @d2
%3 = load double, ptr @d1
%4 = load float, ptr @f4
%5 = load float, ptr @f3
%6 = load float, ptr @f2
%7 = load float, ptr @f1
%8 = load i64, ptr @splim
%9 = load i64, ptr @r5
%10 = load i64, ptr @r4
%11 = load i64, ptr @r3
%12 = load i64, ptr @r2
%13 = load i64, ptr @r1
%14 = load i64, ptr @hp
%15 = load i64, ptr @sp
%16 = load i64, ptr @base
tail call ghccc void @bar(i64 %16, i64 %15, i64 %14, i64 %13, i64 %12,
i64 %11, i64 %10, i64 %9, i64 %8, float %7, float %6,
float %5, float %4, double %3, double %2, double %1, double %0) nounwind
ret void
}
declare ghccc void @bar(i64, i64, i64, i64, i64, i64, i64, i64, i64,
float, float, float, float,
double, double, double, double)