Recognize that ARM1176JZ[F]-S support TrustZone
[oota-llvm.git] / test / MC / ARM / arm-trustzone.s
1 @ RUN: not llvm-mc -triple=armv7-apple-darwin -mcpu=cortex-a8 -show-encoding -mattr=-trustzone < %s | FileCheck %s -check-prefix=NOTZ
2 @ RUN: llvm-mc -triple=armv7-apple-darwin -mcpu=cortex-a8 -show-encoding -mattr=trustzone < %s | FileCheck %s -check-prefix=TZ
3 @ RUN: llvm-mc -triple=armv6kz -mcpu=arm1176jz-s -show-encoding < %s | FileCheck %s -check-prefix=TZ
4
5   .syntax unified
6   .globl _func
7
8 @ Check that the assembler processes SMC instructions when TrustZone support is 
9 @ active and that it rejects them when this feature is not enabled
10
11 _func:
12 @ CHECK: _func
13
14
15 @------------------------------------------------------------------------------
16 @ SMC
17 @------------------------------------------------------------------------------
18         smi #0xf                        @ SMI is old (ARMv6KZ) name for SMC
19         smceq #0
20
21 @ NOTZ-NOT: smc         #15
22 @ NOTZ-NOT: smceq       #0
23 @ TZ: smc       #15                     @ encoding: [0x7f,0x00,0x60,0xe1]
24 @ TZ: smceq     #0                      @ encoding: [0x70,0x00,0x60,0x01]
25