[llvm-readobj] - Simplify stack-sizes.test test case.
[llvm-complete.git] / test / MC / ARM / eh-directive-vsave-diagnostics.s
blob1108625d6e0ca2d742304a770f8ba4f794da3826
1 @ RUN: not llvm-mc -triple=armv7-unknown-linux-gnueabi < %s 2> %t
2 @ RUN: FileCheck < %t %s
4 @ Check the diagnostics for .vsave directive
6 @ .vsave directive should always come after .fnstart directive
7 @ and before .handlerdata directive.
9 .syntax unified
10 .text
12 @-------------------------------------------------------------------------------
13 @ TEST1: .vsave before .fnstart
14 @-------------------------------------------------------------------------------
15 .globl func1
16 .align 2
17 .type func1,%function
18 .vsave {d0, d1, d2, d3}
19 @ CHECK: error: .fnstart must precede .save or .vsave directives
20 @ CHECK: .vsave {d0, d1, d2, d3}
21 @ CHECK: ^
22 .fnstart
23 func1:
24 .fnend
28 @-------------------------------------------------------------------------------
29 @ TEST2: .vsave after .handlerdata
30 @-------------------------------------------------------------------------------
31 .globl func2
32 .align 2
33 .type func2,%function
34 .fnstart
35 func2:
36 .handlerdata
37 .vsave {d0, d1, d2, d3}
38 @ CHECK: error: .save or .vsave must precede .handlerdata directive
39 @ CHECK: .vsave {d0, d1, d2, d3}
40 @ CHECK: ^
41 .fnend