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
47 lines
1.3 KiB
ArmAsm
47 lines
1.3 KiB
ArmAsm
// Check that we are able to rewrite binaries when we fail to identify a
|
|
// suitable location to put new code and user supplies a custom one via
|
|
// --custom-allocation-vma. This happens more obviously if the binary has
|
|
// segments mapped to very high addresses.
|
|
|
|
// In this example, my.reserved.section is mapped to a segment to be loaded
|
|
// at address 0x10000000000, while regular text should be at 0x200000. We
|
|
// pick a vma in the middle at 0x700000 to carve space for BOLT to put data,
|
|
// since BOLT's usual route of allocating after the last segment will put
|
|
// code far away and that will blow up relocations from main.
|
|
|
|
// RUN: split-file %s %t
|
|
// RUN: llvm-mc -filetype=obj -triple x86_64-unknown-unknown %t/main.s -o %t.o
|
|
// RUN: %clang %cflags -no-pie %t.o -o %t.exe -Wl,-T %t/main.ls
|
|
// RUN: llvm-bolt %t.exe -o %t.bolt --custom-allocation-vma=0x700000
|
|
|
|
//--- main.s
|
|
.type reserved_space,@object
|
|
.section .my.reserved.section,"awx",@nobits
|
|
.globl reserved_space
|
|
.p2align 4, 0x0
|
|
reserved_space:
|
|
.zero 0x80000000
|
|
.size reserved_space, 0x80000000
|
|
|
|
.text
|
|
.globl main
|
|
.globl _start
|
|
.type main, %function
|
|
_start:
|
|
main:
|
|
.cfi_startproc
|
|
nop
|
|
nop
|
|
nop
|
|
retq
|
|
.cfi_endproc
|
|
.size main, .-main
|
|
|
|
//--- main.ls
|
|
SECTIONS
|
|
{
|
|
.my.reserved.section 1<<40 : {
|
|
*(.my.reserved.section);
|
|
}
|
|
} INSERT BEFORE .comment;
|