Home | History | Annotate | Download | only in ARM
      1 @ RUN: not llvm-mc -triple=armv7-unknown-linux-gnueabi < %s 2> %t
      2 @ RUN: FileCheck < %t %s
      3 
      4 @ Check the diagnostics for .vsave directive
      5 
      6 @ .vsave directive should always come after .fnstart directive
      7 @ and before .handlerdata directive.
      8 
      9 	.syntax unified
     10 	.text
     11 
     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
     25 
     26 
     27 
     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
     42