[InstCombine] Signed saturation patterns
[llvm-core.git] / test / CodeGen / X86 / global-sections-comdat.ll
blob730050dda5f30ebaf969bbfd60b23a56531f98e6
1 ; RUN: llc < %s -mtriple=i386-unknown-linux | FileCheck %s -check-prefix=LINUX
2 ; RUN: llc < %s -mtriple=i386-unknown-linux -data-sections -function-sections | FileCheck %s -check-prefix=LINUX-SECTIONS
3 ; RUN: llc < %s -mtriple=i386-unknown-linux -data-sections -function-sections -unique-section-names=false | FileCheck %s -check-prefix=LINUX-SECTIONS-SHORT
5 $F1 = comdat any
6 define void @F1(i32 %y) comdat {
7 bb0:
8 switch i32 %y, label %bb5 [
9     i32 1, label %bb1
10     i32 2, label %bb2
11     i32 3, label %bb3
12     i32 4, label %bb4
13   ]
14 bb1:
15   ret void
16 bb2:
17   ret void
18 bb3:
19   ret void
20 bb4:
21   ret void
22 bb5:
23   ret void
26 ; LINUX: .section        .text.F1,"axG",@progbits,F1,comdat
27 ; LINUX: .size   F1,
28 ; LINUX-NEXT: .cfi_endproc
29 ; LINUX-NEXT: .section        .rodata.F1,"aG",@progbits,F1,comdat
31 ; LINUX-SECTIONS: .section        .text.F1,"axG",@progbits,F1,comdat
32 ; LINUX-SECTIONS: .size   F1,
33 ; LINUX-SECTIONS-NEXT: .cfi_endproc
34 ; LINUX-SECTIONS-NEXT: .section        .rodata.F1,"aG",@progbits,F1,comdat
36 ; LINUX-SECTIONS-SHORT: .section        .text,"axG",@progbits,F1,comdat
37 ; LINUX-SECTIONS-SHORT: .size   F1,
38 ; LINUX-SECTIONS-SHORT-NEXT: .cfi_endproc
39 ; LINUX-SECTIONS-SHORT-NEXT: .section        .rodata,"aG",@progbits,F1,comdat
41 $G16 = comdat any
42 @G16 = unnamed_addr constant i32 42, comdat
44 ; LINUX: .section       .rodata.cst4.G16,"aGM",@progbits,4,G16,comdat
45 ; LINUX-SECTIONS: .section      .rodata.cst4.G16,"aGM",@progbits,4,G16,comdat
46 ; LINUX-SECTIONS-SHORT: .section        .rodata.cst4,"aGM",@progbits,4,G16,comdat