1# REQUIRES: x86 2# RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-linux %s -o %t 3# RUN: echo "SECTIONS { .rw : { *(.rw) } .text : { *(.text) } }" > %t.script 4# RUN: ld.lld -o %t1 --script %t.script %t 5# RUN: llvm-objdump --private-headers %t1 | FileCheck %s 6 7## We expect 2 PT_LOAD segments 8# CHECK: Program Header: 9# CHECK-NEXT: LOAD 10# CHECK-NEXT: filesz {{0x[0-9a-f]+}} memsz {{0x[0-9a-f]+}} flags rw- 11# CHECK-NEXT: LOAD 12# CHECK-NEXT: filesz {{0x[0-9a-f]+}} memsz {{0x[0-9a-f]+}} flags r-x 13# CHECK-NEXT: STACK 14# CHECK-NEXT: filesz 15 16.globl _start 17_start: 18 jmp _start 19 20.section .rw, "aw" 21 .quad 0 22