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
82 lines
2.0 KiB
Smarty
Vendored
82 lines
2.0 KiB
Smarty
Vendored
/*
|
|
* Copyright 2018-2025 Yury Gribov
|
|
*
|
|
* The MIT License (MIT)
|
|
*
|
|
* Use of this source code is governed by MIT license that can be
|
|
* found in the LICENSE.txt file.
|
|
*/
|
|
|
|
#define lr x30
|
|
#define ip0 x16
|
|
|
|
.section .note.GNU-stack,"",@progbits
|
|
|
|
.data
|
|
|
|
.globl _${lib_suffix}_tramp_table
|
|
.hidden _${lib_suffix}_tramp_table
|
|
.align 8
|
|
_${lib_suffix}_tramp_table:
|
|
.zero $table_size
|
|
|
|
.text
|
|
|
|
.globl _${lib_suffix}_tramp_resolve
|
|
.hidden _${lib_suffix}_tramp_resolve
|
|
|
|
.globl _${lib_suffix}_save_regs_and_resolve
|
|
.hidden _${lib_suffix}_save_regs_and_resolve
|
|
.type _${lib_suffix}_save_regs_and_resolve, %function
|
|
_${lib_suffix}_save_regs_and_resolve:
|
|
.cfi_startproc
|
|
|
|
// Slow path which calls dlsym, taken only on first call.
|
|
// Registers are saved according to "Procedure Call Standard for the Arm® 64-bit Architecture".
|
|
// For DWARF directives, read https://www.imperialviolet.org/2017/01/18/cfi.html.
|
|
|
|
// Stack is aligned at 16 bytes
|
|
|
|
#define PUSH_PAIR(reg1, reg2) stp reg1, reg2, [sp, #-16]!; .cfi_adjust_cfa_offset 16; .cfi_rel_offset reg1, 0; .cfi_rel_offset reg2, 8
|
|
#define POP_PAIR(reg1, reg2) ldp reg1, reg2, [sp], #16; .cfi_adjust_cfa_offset -16; .cfi_restore reg2; .cfi_restore reg1
|
|
|
|
#define PUSH_WIDE_PAIR(reg1, reg2) stp reg1, reg2, [sp, #-32]!; .cfi_adjust_cfa_offset 32; .cfi_rel_offset reg1, 0; .cfi_rel_offset reg2, 16
|
|
#define POP_WIDE_PAIR(reg1, reg2) ldp reg1, reg2, [sp], #32; .cfi_adjust_cfa_offset -32; .cfi_restore reg2; .cfi_restore reg1
|
|
|
|
// Save only arguments (and lr)
|
|
PUSH_PAIR(x0, x1)
|
|
PUSH_PAIR(x2, x3)
|
|
PUSH_PAIR(x4, x5)
|
|
PUSH_PAIR(x6, x7)
|
|
PUSH_PAIR(x8, lr)
|
|
|
|
ldr x0, [sp, #80] // 16*5
|
|
|
|
PUSH_WIDE_PAIR(q0, q1)
|
|
PUSH_WIDE_PAIR(q2, q3)
|
|
PUSH_WIDE_PAIR(q4, q5)
|
|
PUSH_WIDE_PAIR(q6, q7)
|
|
|
|
// Stack is aligned at 16 bytes
|
|
|
|
bl _${lib_suffix}_tramp_resolve
|
|
mov ip0, x0
|
|
|
|
// TODO: pop pc?
|
|
|
|
POP_WIDE_PAIR(q6, q7)
|
|
POP_WIDE_PAIR(q4, q5)
|
|
POP_WIDE_PAIR(q2, q3)
|
|
POP_WIDE_PAIR(q0, q1)
|
|
|
|
POP_PAIR(x8, lr)
|
|
POP_PAIR(x6, x7)
|
|
POP_PAIR(x4, x5)
|
|
POP_PAIR(x2, x3)
|
|
POP_PAIR(x0, x1)
|
|
|
|
br lr
|
|
|
|
.cfi_endproc
|
|
|