2 # RUN: llvm-mc -triple i686-windows-msvc %s -filetype=obj -o %t.obj
3 # RUN: lld-link %t.obj -safeseh -out:%t.exe -entry:main
4 # RUN: llvm-readobj --file-headers %t.exe | FileCheck %s
6 # This object lacks a _load_config_used global, so we set
7 # IMAGE_DLL_CHARACTERISTICS_NO_SEH even though there is an exception handler.
8 # This is a more secure default. If someone wants to use a CRT without a load
9 # config and they want to use 32-bit SEH, they will need to provide a
10 # safeseh-compatible load config.
12 # CHECK-LABEL: Characteristics [
13 # CHECK: IMAGE_DLL_CHARACTERISTICS_NO_SEH
16 # CHECK-LABEL: DataDirectory {
17 # CHECK: LoadConfigTableRVA: 0x0
18 # CHECK: LoadConfigTableSize: 0x0
21 # CHECK-NOT: LoadConfig
32 .def _main; .scl 2; .type 32; .endef
40 .def _my_handler; .scl 3; .type 32; .endef