diff options
| author | Chris Lattner <sabre@nondot.org> | 2009-08-04 16:13:09 +0000 |
|---|---|---|
| committer | Chris Lattner <sabre@nondot.org> | 2009-08-04 16:13:09 +0000 |
| commit | 81bbf443fe473ad3f03e5e8ec8752fd3da2995a6 (patch) | |
| tree | abcbaecc050fb311bfad70e966b2c4190aaaa8e2 /llvm/test/CodeGen/X86 | |
| parent | bbabd39cced9f72061ec3ce151636a9ad07844f3 (diff) | |
| download | bcm5719-llvm-81bbf443fe473ad3f03e5e8ec8752fd3da2995a6.tar.gz bcm5719-llvm-81bbf443fe473ad3f03e5e8ec8752fd3da2995a6.zip | |
Add support emiting for 2/4 byte mergable strings to the ".rodata.str*"
section on ELF targets.
llvm-svn: 78066
Diffstat (limited to 'llvm/test/CodeGen/X86')
| -rw-r--r-- | llvm/test/CodeGen/X86/global-sections.ll | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/llvm/test/CodeGen/X86/global-sections.ll b/llvm/test/CodeGen/X86/global-sections.ll index a674a3ee97b..4f4c4bcf1c7 100644 --- a/llvm/test/CodeGen/X86/global-sections.ll +++ b/llvm/test/CodeGen/X86/global-sections.ll @@ -85,3 +85,39 @@ ; DARWIN:_G6: ; DARWIN: .ascii "\001" + +@G7 = constant [10 x i8] c"abcdefghi\00" + +; DARWIN: .cstring +; DARWIN: .globl _G7 +; DARWIN: _G7: +; DARWIN: .asciz "abcdefghi" + +; LINUX: .section .rodata.str1.1,"aMS",@progbits,1 +; LINUX: .globl G7 +; LINUX: G7: +; LINUX: .asciz "abcdefghi" + + +@G8 = constant [4 x i16] [ i16 1, i16 2, i16 3, i16 0 ] + +; DARWIN: .const +; DARWIN: .globl _G8 +; DARWIN: _G8: + +; LINUX: .section .rodata.str2.2,"aMS",@progbits,2 +; LINUX: .globl G8 +; LINUX:G8: + +@G9 = constant [4 x i32] [ i32 1, i32 2, i32 3, i32 0 ] + +; ARWIN: .const [[ already in const section]] +; DARWIN: .globl _G9 +; DARWIN: _G9: + +; LINUX: .section .rodata.str4.4,"aMS",@progbits,4 +; LINUX: .globl G9 +; LINUX:G9 + + + |

