2014-06-28 02:19:56 +08:00
|
|
|
; RUN: llc -mtriple i386-pc-win32 < %s | FileCheck %s
|
|
|
|
|
|
|
|
$f1 = comdat any
|
2015-01-07 06:55:16 +08:00
|
|
|
@v1 = global i32 0, comdat($f1)
|
|
|
|
define void @f1() comdat($f1) {
|
2014-06-28 02:19:56 +08:00
|
|
|
ret void
|
|
|
|
}
|
|
|
|
|
|
|
|
$f2 = comdat exactmatch
|
2015-01-07 06:55:16 +08:00
|
|
|
@v2 = global i32 0, comdat($f2)
|
|
|
|
define void @f2() comdat($f2) {
|
2014-06-28 02:19:56 +08:00
|
|
|
ret void
|
|
|
|
}
|
|
|
|
|
|
|
|
$f3 = comdat largest
|
2015-01-07 06:55:16 +08:00
|
|
|
@v3 = global i32 0, comdat($f3)
|
|
|
|
define void @f3() comdat($f3) {
|
2014-06-28 02:19:56 +08:00
|
|
|
ret void
|
|
|
|
}
|
|
|
|
|
|
|
|
$f4 = comdat noduplicates
|
2015-01-07 06:55:16 +08:00
|
|
|
@v4 = global i32 0, comdat($f4)
|
|
|
|
define void @f4() comdat($f4) {
|
2014-06-28 02:19:56 +08:00
|
|
|
ret void
|
|
|
|
}
|
|
|
|
|
|
|
|
$f5 = comdat samesize
|
2015-01-07 06:55:16 +08:00
|
|
|
@v5 = global i32 0, comdat($f5)
|
|
|
|
define void @f5() comdat($f5) {
|
2014-06-28 02:19:56 +08:00
|
|
|
ret void
|
|
|
|
}
|
|
|
|
|
|
|
|
$f6 = comdat samesize
|
2015-01-07 06:55:16 +08:00
|
|
|
@v6 = global i32 0, comdat($f6)
|
|
|
|
@f6 = global i32 0, comdat($f6)
|
2014-06-28 02:19:56 +08:00
|
|
|
|
|
|
|
$"\01@f7@0" = comdat any
|
2015-01-07 06:55:16 +08:00
|
|
|
define x86_fastcallcc void @"\01@v7@0"() comdat($"\01@f7@0") {
|
2014-06-28 02:19:56 +08:00
|
|
|
ret void
|
|
|
|
}
|
2015-01-07 06:55:16 +08:00
|
|
|
define x86_fastcallcc void @"\01@f7@0"() comdat($"\01@f7@0") {
|
2014-06-28 02:19:56 +08:00
|
|
|
ret void
|
|
|
|
}
|
|
|
|
|
|
|
|
$f8 = comdat any
|
2015-01-07 06:55:16 +08:00
|
|
|
define x86_fastcallcc void @v8() comdat($f8) {
|
2014-06-28 02:19:56 +08:00
|
|
|
ret void
|
|
|
|
}
|
2015-01-07 06:55:16 +08:00
|
|
|
define x86_fastcallcc void @f8() comdat($f8) {
|
2014-06-28 02:19:56 +08:00
|
|
|
ret void
|
|
|
|
}
|
|
|
|
|
|
|
|
$vftable = comdat largest
|
|
|
|
|
2015-01-07 06:55:16 +08:00
|
|
|
@some_name = private unnamed_addr constant [2 x i8*] zeroinitializer, comdat($vftable)
|
2015-09-11 11:22:04 +08:00
|
|
|
@vftable = alias i8*, getelementptr([2 x i8*], [2 x i8*]* @some_name, i32 0, i32 1)
|
2014-06-28 02:19:56 +08:00
|
|
|
|
|
|
|
; CHECK: .section .text,"xr",discard,_f1
|
|
|
|
; CHECK: .globl _f1
|
|
|
|
; CHECK: .section .text,"xr",same_contents,_f2
|
|
|
|
; CHECK: .globl _f2
|
|
|
|
; CHECK: .section .text,"xr",largest,_f3
|
|
|
|
; CHECK: .globl _f3
|
|
|
|
; CHECK: .section .text,"xr",one_only,_f4
|
|
|
|
; CHECK: .globl _f4
|
|
|
|
; CHECK: .section .text,"xr",same_size,_f5
|
|
|
|
; CHECK: .globl _f5
|
|
|
|
; CHECK: .section .text,"xr",associative,@f7@0
|
|
|
|
; CHECK: .globl @v7@0
|
|
|
|
; CHECK: .section .text,"xr",discard,@f7@0
|
|
|
|
; CHECK: .globl @f7@0
|
|
|
|
; CHECK: .section .text,"xr",associative,@f8@0
|
|
|
|
; CHECK: .globl @v8@0
|
|
|
|
; CHECK: .section .text,"xr",discard,@f8@0
|
|
|
|
; CHECK: .globl @f8@0
|
2015-02-07 16:26:40 +08:00
|
|
|
; CHECK: .section .bss,"bw",associative,_f1
|
2014-06-28 02:19:56 +08:00
|
|
|
; CHECK: .globl _v1
|
2015-02-07 16:26:40 +08:00
|
|
|
; CHECK: .section .bss,"bw",associative,_f2
|
2014-06-28 02:19:56 +08:00
|
|
|
; CHECK: .globl _v2
|
2015-02-07 16:26:40 +08:00
|
|
|
; CHECK: .section .bss,"bw",associative,_f3
|
2014-06-28 02:19:56 +08:00
|
|
|
; CHECK: .globl _v3
|
2015-02-07 16:26:40 +08:00
|
|
|
; CHECK: .section .bss,"bw",associative,_f4
|
2014-06-28 02:19:56 +08:00
|
|
|
; CHECK: .globl _v4
|
2015-02-07 16:26:40 +08:00
|
|
|
; CHECK: .section .bss,"bw",associative,_f5
|
2014-06-28 02:19:56 +08:00
|
|
|
; CHECK: .globl _v5
|
2015-02-07 16:26:40 +08:00
|
|
|
; CHECK: .section .bss,"bw",associative,_f6
|
2014-06-28 02:19:56 +08:00
|
|
|
; CHECK: .globl _v6
|
2015-02-07 16:26:40 +08:00
|
|
|
; CHECK: .section .bss,"bw",same_size,_f6
|
2014-06-28 02:19:56 +08:00
|
|
|
; CHECK: .globl _f6
|
2015-02-07 16:26:40 +08:00
|
|
|
; CHECK: .section .rdata,"dr",largest,_vftable
|
2014-06-28 02:19:56 +08:00
|
|
|
; CHECK: .globl _vftable
|
2018-03-28 00:44:41 +08:00
|
|
|
; CHECK: .set _vftable, L_some_name+4
|