brintos

brintos / llvm-project-archived public Read only

0
0
Text · 935 B · 6bf2887 Raw
33 lines · plain
1// REQUIRES: x862// RUN: llvm-mc --triple=x86_64 -filetype=obj %s -o %t.o3// RUN: echo "SECTIONS { \4// RUN:         . = 0x80000000; \5// RUN:         .linkorder : { *(.linkorder.*) } \6// RUN:         .text : { *(.text) } \7// RUN:         .text.1 0x80000200 : AT(0x1000) { *(.text.1) } \8// RUN:         .text.2 0x80000100 : AT(0x2000) { *(.text.2) } \9// RUN: } " > %t.script10// RUN: ld.lld --script %t.script %t.o -o %t11// RUN: llvm-readobj -x .linkorder  %t | FileCheck %s12 13/// When a linker script does not have monotonically increasing addresses14/// the SHF_LINK_ORDER sections should still be in monotonically increasing15/// order.16 17// CHECK: Hex dump of section '.linkorder':18// CHECK-NEXT: 0x80000000 020119 20.section .text.1, "ax", %progbits21.global _start22_start:23nop24 25.section .text.2, "ax", %progbits26.byte 027 28.section .linkorder.1, "ao", %progbits, .text.129.byte 130 31.section .linkorder.2, "ao", %progbits, .text.232.byte 233