[memprof] Remove an unused using directive (#117004)
[llvm-project.git] / lld / test / COFF / comdat-drectve.s
blob6f96a8709fc77039c012eb958a48f86ffe1733e4
1 # REQUIRES: x86
3 # RUN: llvm-mc -triple=x86_64-windows-gnu %s -filetype=obj -o %t.obj
5 # RUN: lld-link %t.obj -out:%t.exe -debug:symtab -subsystem:console
6 # RUN: llvm-readobj --coff-exports %t.exe | FileCheck %s
8 # CHECK: Name: exportedFunc
10 ## This assembly snippet has been reduced from what Clang generates from
11 ## this C snippet, with -fsanitize=address. Normally, the .drectve
12 ## section would be a regular section - but when compiled with
13 ## -fsanitize=address, it becomes a comdat section.
15 # void exportedFunc(void) {}
16 # void mainCRTStartup(void) {}
17 # static __attribute__((section(".drectve"), used)) const char export_chkstk[] =
18 # "-export:exportedFunc";
20 .text
21 .globl exportedFunc
22 exportedFunc:
23 retq
25 .globl mainCRTStartup
26 mainCRTStartup:
27 retq
29 .section .drectve,"dr",one_only,export_chkstk
30 export_chkstk:
31 .asciz "-export:exportedFunc"