1# REQUIRES: systemz 2# RUN: llvm-mc -filetype=obj -triple=s390x-unknown-linux %p/Inputs/systemz-init.s -o systemz-init.o 3# RUN: llvm-mc -filetype=obj -triple=s390x-unknown-linux %s -o %t.o 4# RUN: ld.lld -dynamic-linker /lib/ld64.so.1 %t.o systemz-init.o -o %t 5# RUN: llvm-objdump -d --no-show-raw-insn -j .init %t | FileCheck %s 6 7# glibc < 2.39 used to align .init and .fini code at a 4-byte boundary. 8# When that happens, the linker must not pad the code with invalid 9# instructions, e.g. null bytes. 10 .section .init,"ax",@progbits 11 brasl %r14, startup 12 13# CHECK: <.init>: 14# CHECK-NEXT: brasl %r14, 15# CHECK-NEXT: nopr %r7 16# CHECK-NEXT: lg %r4, 272(%r15) 17 18 .text 19 .globl startup 20 .p2align 4 21startup: 22 br %r14 23 24 .globl main 25 .p2align 4 26main: 27 br %r14 28