diff options
Diffstat (limited to 'llvm/test')
-rw-r--r-- | llvm/test/CodeGen/X86/global-sections-comdat.ll | 1 | ||||
-rw-r--r-- | llvm/test/MC/ELF/section-unique-err1.s | 5 | ||||
-rw-r--r-- | llvm/test/MC/ELF/section-unique-err2.s | 5 | ||||
-rw-r--r-- | llvm/test/MC/ELF/section-unique-err3.s | 5 | ||||
-rw-r--r-- | llvm/test/MC/ELF/section-unique.s | 8 |
5 files changed, 19 insertions, 5 deletions
diff --git a/llvm/test/CodeGen/X86/global-sections-comdat.ll b/llvm/test/CodeGen/X86/global-sections-comdat.ll index 46188e7153b..730050dda5f 100644 --- a/llvm/test/CodeGen/X86/global-sections-comdat.ll +++ b/llvm/test/CodeGen/X86/global-sections-comdat.ll @@ -36,7 +36,6 @@ bb5: ; LINUX-SECTIONS-SHORT: .section .text,"axG",@progbits,F1,comdat ; LINUX-SECTIONS-SHORT: .size F1, ; LINUX-SECTIONS-SHORT-NEXT: .cfi_endproc -; LINUX-SECTIONS-SHORT-NEXT: .Lsec_end0: ; LINUX-SECTIONS-SHORT-NEXT: .section .rodata,"aG",@progbits,F1,comdat $G16 = comdat any diff --git a/llvm/test/MC/ELF/section-unique-err1.s b/llvm/test/MC/ELF/section-unique-err1.s new file mode 100644 index 00000000000..0b4985ba1d6 --- /dev/null +++ b/llvm/test/MC/ELF/section-unique-err1.s @@ -0,0 +1,5 @@ +// RUN: not llvm-mc -triple x86_64-pc-linux-gnu %s -o - 2>&1 | FileCheck %s + +// CHECK: error: expected absolute expression + + .section .text,"ax",@progbits,unique "abc" diff --git a/llvm/test/MC/ELF/section-unique-err2.s b/llvm/test/MC/ELF/section-unique-err2.s new file mode 100644 index 00000000000..b2ac4f8aecf --- /dev/null +++ b/llvm/test/MC/ELF/section-unique-err2.s @@ -0,0 +1,5 @@ +// RUN: not llvm-mc -triple x86_64-pc-linux-gnu %s -o - 2>&1 | FileCheck %s + +// CHECK: error: unique id must be positive + + .section .text,"ax",@progbits,unique -1 diff --git a/llvm/test/MC/ELF/section-unique-err3.s b/llvm/test/MC/ELF/section-unique-err3.s new file mode 100644 index 00000000000..67e962bfac7 --- /dev/null +++ b/llvm/test/MC/ELF/section-unique-err3.s @@ -0,0 +1,5 @@ +// RUN: not llvm-mc -triple x86_64-pc-linux-gnu %s -o - 2>&1 | FileCheck %s + +// CHECK: error: unique id is too large + + .section .text,"ax",@progbits,unique 4294967295 diff --git a/llvm/test/MC/ELF/section-unique.s b/llvm/test/MC/ELF/section-unique.s index b482af3d101..ffd11d944c5 100644 --- a/llvm/test/MC/ELF/section-unique.s +++ b/llvm/test/MC/ELF/section-unique.s @@ -1,22 +1,22 @@ // RUN: llvm-mc -triple x86_64-pc-linux-gnu %s -o - | FileCheck %s // RUN: llvm-mc -triple x86_64-pc-linux-gnu %s -filetype=obj -o - | llvm-readobj -t | FileCheck %s --check-prefix=OBJ - .section .text,"ax",@progbits,unique + .section .text,"ax",@progbits,unique 4294967293 .globl f f: nop - .section .text,"ax",@progbits,unique + .section .text,"ax",@progbits,unique 4294967294 .globl g g: nop // test that f and g are in different sections. -// CHECK: .section .text,"ax",@progbits,unique +// CHECK: .section .text,"ax",@progbits,unique 4294967293 // CHECK: f: -// CHECK: .section .text,"ax",@progbits,unique +// CHECK: .section .text,"ax",@progbits,unique 4294967294 // CHECK: g: // OBJ: Symbol { |