1# REQUIRES: x86 2 3# RUN: split-file %s %t 4 5# RUN: llvm-mc -filetype=obj -triple=x86_64-apple-darwin %t/basic.s -o %t.basic.o 6# RUN: %lld %t.basic.o -o %t.basic 7# RUN: llvm-objdump --syms %t.basic > %t.objdump 8# RUN: llvm-objdump --macho --function-starts %t.basic >> %t.objdump 9# RUN: FileCheck %s --check-prefix=BASIC < %t.objdump 10 11# BASIC: SYMBOL TABLE: 12# BASIC-NEXT: [[#%x,MAIN:]] g F __TEXT,__text _main 13# BASIC-NEXT: [[#%x,F1:]] g F __TEXT,__text _f1 14# BASIC-NEXT: [[#%x,F2:]] g F __TEXT,__text _f2 15# BASIC: [[#MAIN]] 16# BASIC: [[#F1]] 17# BASIC: [[#F2]] 18 19# RUN: llvm-mc -filetype=obj -triple=x86_64-apple-darwin %t/alias.s -o %t.alias.o 20# RUN: %lld %t.alias.o -o %t.alias 21# RUN: llvm-objdump --syms %t.alias > %t.objdump 22# RUN: llvm-objdump --macho --function-starts %t.alias >> %t.objdump 23# RUN: FileCheck %s --check-prefix=ALIAS < %t.objdump 24 25# ALIAS: SYMBOL TABLE: 26# ALIAS-NEXT: [[#%x,F2:]] l F __TEXT,__text _f2 27# ALIAS-NEXT: [[#%x,MAIN:]] g F __TEXT,__text _main 28# ALIAS-NEXT: [[#%x,F1:]] g F __TEXT,__text _f1 29# ALIAS: [[#MAIN]] 30# ALIAS: [[#F1]] 31 32#--- basic.s 33.section __TEXT,__text,regular,pure_instructions 34.globl _f1 35.globl _f2 36.globl _main 37_f1: 38 retq 39_f2: 40 retq 41_main: 42 retq 43 44#--- alias.s 45.section __TEXT,__text,regular,pure_instructions 46.globl _f1 47.equiv _f2, _f1 48.globl _main 49_f1: 50 retq 51_main: 52 retq 53