1# REQUIRES: x86 2 3# RUN: llvm-mc -triple=i686-windows-gnu %s -filetype=obj -o %t.obj 4# RUN: lld-link -lldmingw -lldmap:%t.map -out:%t.exe -opt:ref -entry:main %t.obj -verbose 2>&1 | FileCheck %s 5# RUN: FileCheck %s --check-prefix=MAP --input-file=%t.map 6 7# CHECK: Discarded _unused 8 9# MAP: In Symbol 10# MAP: gc-dwarf-eh.s.tmp.obj:(.text) 11# MAP: {{ ___gxx_personality_v0$}} 12 13 .def _main; .scl 2; .type 32; .endef 14 .section .text,"xr",one_only,_main 15 .globl _main 16_main: 17 .cfi_startproc 18 .cfi_personality 0, ___gxx_personality_v0 19 xorl %eax, %eax 20 ret 21 .cfi_endproc 22 23 .def ___gxx_personality_v0; .scl 2; .type 32; .endef 24 .section .text,"xr",one_only,___gxx_personality_v0 25 .globl ___gxx_personality_v0 26___gxx_personality_v0: 27 ret 28 29 .def _unused; .scl 2; .type 32; .endef 30 .section .text,"xr",one_only,_unused 31 .globl _unused 32_unused: 33 .cfi_startproc 34 .cfi_personality 0, ___gxx_personality_v0 35 ret 36 .cfi_endproc 37