mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-02-03 02:43:51 +00:00
339fbe1bce
The manual says that Thumb2 add/sub instructions are only allowed to modify sp if the first source is also sp. This is slightly different from the usual rGPR restriction since it's context-sensitive, so implement it in C++. llvm-svn: 358987
21 lines
726 B
ArmAsm
21 lines
726 B
ArmAsm
@ RUN: not llvm-mc -triple thumbv7-apple-ios %s -o - 2>&1 | FileCheck %s
|
|
|
|
@ CHECK: error: source register must be sp if destination is sp
|
|
@ CHECK: error: source register must be sp if destination is sp
|
|
@ CHECK: error: source register must be sp if destination is sp
|
|
@ CHECK: error: source register must be sp if destination is sp
|
|
add sp, r5, #1
|
|
addw sp, r7, #4
|
|
add sp, r3, r2
|
|
add sp, r3, r5, lsl #3
|
|
|
|
|
|
@ CHECK: error: source register must be sp if destination is sp
|
|
@ CHECK: error: source register must be sp if destination is sp
|
|
@ CHECK: error: source register must be sp if destination is sp
|
|
@ CHECK: error: source register must be sp if destination is sp
|
|
sub sp, r5, #1
|
|
subw sp, r7, #4
|
|
sub sp, r3, r2
|
|
sub sp, r3, r5, lsl #3
|