summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2010-04-13 00:36:43 +0000
committerChris Lattner <sabre@nondot.org>2010-04-13 00:36:43 +0000
commit43ac721e3b35341e7cf59d5982ad702ca8d27433 (patch)
tree434695966d6d1bef31e8a9b35301f07b4cc96154 /test
parent18d57661f3b5a30526e63a4de429db1d362fd6ab (diff)
downloadllvm-43ac721e3b35341e7cf59d5982ad702ca8d27433.tar.gz
llvm-43ac721e3b35341e7cf59d5982ad702ca8d27433.tar.bz2
llvm-43ac721e3b35341e7cf59d5982ad702ca8d27433.tar.xz
add llvm codegen support for -ffunction-sections and -fdata-sections,
patch by Sylvere Teissier! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@101106 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test')
-rw-r--r--test/CodeGen/X86/global-sections.ll10
1 files changed, 10 insertions, 0 deletions
diff --git a/test/CodeGen/X86/global-sections.ll b/test/CodeGen/X86/global-sections.ll
index d79c56bc46..732d764dbd 100644
--- a/test/CodeGen/X86/global-sections.ll
+++ b/test/CodeGen/X86/global-sections.ll
@@ -1,5 +1,6 @@
; RUN: llc < %s -mtriple=i386-unknown-linux-gnu | FileCheck %s -check-prefix=LINUX
; RUN: llc < %s -mtriple=i386-apple-darwin9.7 | FileCheck %s -check-prefix=DARWIN
+; RUN: llc < %s -mtriple=i386-unknown-linux-gnu -fdata-sections | FileCheck %s -check-prefix=LINUX-SECTIONS
; int G1;
@@ -32,6 +33,12 @@
; DARWIN: _G3:
; DARWIN: .long _G1
+; LINUX: .section .rodata,"a",@progbits
+; LINUX: .globl G3
+
+; LINUX-SECTIONS: .section .rodata.G3,"a",@progbits
+; LINUX-SECTIONS: .globl G3
+
; _Complex long long const G4 = 34;
@G4 = constant {i64,i64} { i64 34, i64 0 }
@@ -97,6 +104,9 @@
; LINUX: G7:
; LINUX: .asciz "abcdefghi"
+; LINUX-SECTIONS: .section .rodata.G7,"aMS",@progbits,1
+; LINUX-SECTIONS: .globl G7
+
@G8 = constant [4 x i16] [ i16 1, i16 2, i16 3, i16 0 ]