@ RUN: llvm-mc %s -triple=armv7-unknown-linux-gnueabi -filetype=obj -o - \
@ RUN: | llvm-readobj -S --sd --sr -r --symbols - | FileCheck %s
@ Check whether the section is switched back or not.
@ The assembler should emit the machine code of "func2" in .text section.
@ It is incorrect if the machine code is emitted in .ARM.exidx or .ARM.extab.
@ Besides, there should be two entries in .ARM.exidx section.
.syntax unified
.text
.globl func1
.align 2
.type func1,%function
.fnstart
func1:
bx lr
.fnend
.globl func2
.align 2
.type func2,%function
.fnstart
func2:
bx lr
.fnend
@-------------------------------------------------------------------------------
@ Check the .text section. There should be two "bx lr" instructions.
@-------------------------------------------------------------------------------
@ CHECK: Sections
@-------------------------------------------------------------------------------
@ The first word of each entry should be relocated to .text section.
@-------------------------------------------------------------------------------
@ CHECK: Relocations
@-------------------------------------------------------------------------------
@ Check the symbols "func1" and "func2". They should belong to .text section.
@-------------------------------------------------------------------------------
@ CHECK: Symbols