brintos

brintos / llvm-project-archived public Read only

0
0
Text · 1.2 KiB · 6c605df Raw
45 lines · plain
1# REQUIRES: x862# RUN: llvm-mc -triple x86_64-pc-win32 %s -filetype=obj -o %t.obj3# RUN: lld-link %t.obj -guard:cf -dll -out:%t.dll -noentry4# RUN: llvm-readobj --coff-load-config %t.dll | FileCheck %s --check-prefix=CHECK5 6# There should be a single entry in the table for the exported symbol.7#8# CHECK: GuardFidTable [9# CHECK-NEXT: 0x18000100010# CHECK-NEXT: ]11 12        .def    func_export; .scl    2; .type   32; .endef13        .globl func_export14        .section       .text,"xr",one_only,func_export15        .p2align 416func_export:17        movl $1, %eax18        .globl label_export19label_export:20        movl $2, %eax21        ret22 23        .data24        .globl data_export25data_export:26        .long 4227 28        .section .drectve,"dr"29        .ascii " /EXPORT:func_export"30        .ascii " /EXPORT:label_export"31        .ascii " /EXPORT:data_export"32 33 34# Load configuration directory entry (winnt.h _IMAGE_LOAD_CONFIG_DIRECTORY64).35# The linker will define the __guard_* symbols.36        .section .rdata,"dr"37.globl _load_config_used38_load_config_used:39        .long 25640        .fill 124, 1, 041        .quad __guard_fids_table42        .quad __guard_fids_count43        .long __guard_flags44        .fill 128, 1, 045