• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1; RUN: llc -mtriple i386-pc-win32 < %s | FileCheck %s
2
3$f1 = comdat any
4@v1 = global i32 0, comdat($f1)
5define void @f1() comdat($f1) {
6  ret void
7}
8
9$f2 = comdat exactmatch
10@v2 = global i32 0, comdat($f2)
11define void @f2() comdat($f2) {
12  ret void
13}
14
15$f3 = comdat largest
16@v3 = global i32 0, comdat($f3)
17define void @f3() comdat($f3) {
18  ret void
19}
20
21$f4 = comdat noduplicates
22@v4 = global i32 0, comdat($f4)
23define void @f4() comdat($f4) {
24  ret void
25}
26
27$f5 = comdat samesize
28@v5 = global i32 0, comdat($f5)
29define void @f5() comdat($f5) {
30  ret void
31}
32
33$f6 = comdat samesize
34@v6 = global i32 0, comdat($f6)
35@f6 = global i32 0, comdat($f6)
36
37$"\01@f7@0" = comdat any
38define x86_fastcallcc void @"\01@v7@0"() comdat($"\01@f7@0") {
39  ret void
40}
41define x86_fastcallcc void @"\01@f7@0"() comdat($"\01@f7@0") {
42  ret void
43}
44
45$f8 = comdat any
46define x86_fastcallcc void @v8() comdat($f8) {
47  ret void
48}
49define x86_fastcallcc void @f8() comdat($f8) {
50  ret void
51}
52
53$vftable = comdat largest
54
55@some_name = private unnamed_addr constant [2 x i8*] zeroinitializer, comdat($vftable)
56@vftable = alias i8*, getelementptr([2 x i8*], [2 x i8*]* @some_name, i32 0, i32 1)
57
58; CHECK: .section        .text,"xr",discard,_f1
59; CHECK: .globl  _f1
60; CHECK: .section        .text,"xr",same_contents,_f2
61; CHECK: .globl  _f2
62; CHECK: .section        .text,"xr",largest,_f3
63; CHECK: .globl  _f3
64; CHECK: .section        .text,"xr",one_only,_f4
65; CHECK: .globl  _f4
66; CHECK: .section        .text,"xr",same_size,_f5
67; CHECK: .globl  _f5
68; CHECK: .section        .text,"xr",associative,@f7@0
69; CHECK: .globl  @v7@0
70; CHECK: .section        .text,"xr",discard,@f7@0
71; CHECK: .globl  @f7@0
72; CHECK: .section        .text,"xr",associative,@f8@0
73; CHECK: .globl  @v8@0
74; CHECK: .section        .text,"xr",discard,@f8@0
75; CHECK: .globl  @f8@0
76; CHECK: .section        .bss,"bw",associative,_f1
77; CHECK: .globl  _v1
78; CHECK: .section        .bss,"bw",associative,_f2
79; CHECK: .globl  _v2
80; CHECK: .section        .bss,"bw",associative,_f3
81; CHECK: .globl  _v3
82; CHECK: .section        .bss,"bw",associative,_f4
83; CHECK: .globl  _v4
84; CHECK: .section        .bss,"bw",associative,_f5
85; CHECK: .globl  _v5
86; CHECK: .section        .bss,"bw",associative,_f6
87; CHECK: .globl  _v6
88; CHECK: .section        .bss,"bw",same_size,_f6
89; CHECK: .globl  _f6
90; CHECK: .section        .rdata,"dr",largest,_vftable
91; CHECK: .globl  _vftable
92; CHECK: .set _vftable, L_some_name+4
93