1; REQUIRES: x86
2; RUN: llvm-as -o %t.obj %s
3; RUN: lld-link /dll /out:%t.dll %t.obj
4; RUN: llvm-objdump -d %t.dll | FileCheck %s
5
6; Checks that code for foo is emitted, as required by the /INCLUDE directive.
7; CHECK: xorl %eax, %eax
8; CHECK-NEXT: retq
9
10target datalayout = "e-m:w-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
11target triple = "x86_64-pc-windows-msvc"
12
13define void @_DllMainCRTStartup() {
14  ret void
15}
16
17define i32 @foo() {
18  ret i32 0
19}
20
21!llvm.linker.options = !{!0}
22!0 = !{!"/INCLUDE:foo"}
23