2015-09-30 00:40:13 +08:00
|
|
|
# RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-linux %s -o %t1
|
2015-11-18 14:11:01 +08:00
|
|
|
# RUN: not ld.lld %t1 -o %t2
|
2015-11-20 10:32:35 +08:00
|
|
|
# RUN: ld.lld %t1 -o %t2 -e entry
|
2015-12-12 01:42:38 +08:00
|
|
|
# RUN: llvm-readobj -file-headers %t2 | FileCheck -check-prefix=SYM %s
|
2015-12-12 01:46:46 +08:00
|
|
|
# RUN: ld.lld %t1 -shared -o %t2 -e entry
|
|
|
|
# RUN: llvm-readobj -file-headers %t2 | FileCheck -check-prefix=DSO %s
|
2015-11-18 14:11:01 +08:00
|
|
|
# RUN: ld.lld %t1 -o %t2 -e 4096
|
2015-10-15 06:20:57 +08:00
|
|
|
# RUN: llvm-readobj -file-headers %t2 | FileCheck -check-prefix=DEC %s
|
2015-11-18 14:11:01 +08:00
|
|
|
# RUN: ld.lld %t1 -o %t2 -e 0xcafe
|
2015-10-15 06:20:57 +08:00
|
|
|
# RUN: llvm-readobj -file-headers %t2 | FileCheck -check-prefix=HEX %s
|
2015-11-18 14:11:01 +08:00
|
|
|
# RUN: ld.lld %t1 -o %t2 -e 0777
|
2015-10-15 06:20:57 +08:00
|
|
|
# RUN: llvm-readobj -file-headers %t2 | FileCheck -check-prefix=OCT %s
|
|
|
|
|
2015-12-12 01:42:38 +08:00
|
|
|
# SYM: Entry: 0x11000
|
2015-12-12 01:46:46 +08:00
|
|
|
# DSO: Entry: 0x1000
|
2015-10-15 06:20:57 +08:00
|
|
|
# DEC: Entry: 0x1000
|
|
|
|
# HEX: Entry: 0xCAFE
|
|
|
|
# OCT: Entry: 0x1FF
|
|
|
|
|
2015-11-20 10:32:35 +08:00
|
|
|
.globl entry
|
|
|
|
entry:
|