18c2ecf20Sopenharmony_ci// SPDX-License-Identifier: GPL-2.0-only 28c2ecf20Sopenharmony_ci/* 38c2ecf20Sopenharmony_ci * arch/arm/kernel/kprobes-test-arm.c 48c2ecf20Sopenharmony_ci * 58c2ecf20Sopenharmony_ci * Copyright (C) 2011 Jon Medhurst <tixy@yxit.co.uk>. 68c2ecf20Sopenharmony_ci */ 78c2ecf20Sopenharmony_ci 88c2ecf20Sopenharmony_ci#include <linux/kernel.h> 98c2ecf20Sopenharmony_ci#include <linux/module.h> 108c2ecf20Sopenharmony_ci#include <asm/system_info.h> 118c2ecf20Sopenharmony_ci#include <asm/opcodes.h> 128c2ecf20Sopenharmony_ci#include <asm/probes.h> 138c2ecf20Sopenharmony_ci 148c2ecf20Sopenharmony_ci#include "test-core.h" 158c2ecf20Sopenharmony_ci 168c2ecf20Sopenharmony_ci 178c2ecf20Sopenharmony_ci#define TEST_ISA "32" 188c2ecf20Sopenharmony_ci 198c2ecf20Sopenharmony_ci#define TEST_ARM_TO_THUMB_INTERWORK_R(code1, reg, val, code2) \ 208c2ecf20Sopenharmony_ci TESTCASE_START(code1 #reg code2) \ 218c2ecf20Sopenharmony_ci TEST_ARG_REG(reg, val) \ 228c2ecf20Sopenharmony_ci TEST_ARG_REG(14, 99f) \ 238c2ecf20Sopenharmony_ci TEST_ARG_END("") \ 248c2ecf20Sopenharmony_ci "50: nop \n\t" \ 258c2ecf20Sopenharmony_ci "1: "code1 #reg code2" \n\t" \ 268c2ecf20Sopenharmony_ci " bx lr \n\t" \ 278c2ecf20Sopenharmony_ci ".thumb \n\t" \ 288c2ecf20Sopenharmony_ci "3: adr lr, 2f \n\t" \ 298c2ecf20Sopenharmony_ci " bx lr \n\t" \ 308c2ecf20Sopenharmony_ci ".arm \n\t" \ 318c2ecf20Sopenharmony_ci "2: nop \n\t" \ 328c2ecf20Sopenharmony_ci TESTCASE_END 338c2ecf20Sopenharmony_ci 348c2ecf20Sopenharmony_ci#define TEST_ARM_TO_THUMB_INTERWORK_P(code1, reg, val, code2) \ 358c2ecf20Sopenharmony_ci TESTCASE_START(code1 #reg code2) \ 368c2ecf20Sopenharmony_ci TEST_ARG_PTR(reg, val) \ 378c2ecf20Sopenharmony_ci TEST_ARG_REG(14, 99f) \ 388c2ecf20Sopenharmony_ci TEST_ARG_MEM(15, 3f+1) \ 398c2ecf20Sopenharmony_ci TEST_ARG_END("") \ 408c2ecf20Sopenharmony_ci "50: nop \n\t" \ 418c2ecf20Sopenharmony_ci "1: "code1 #reg code2" \n\t" \ 428c2ecf20Sopenharmony_ci " bx lr \n\t" \ 438c2ecf20Sopenharmony_ci ".thumb \n\t" \ 448c2ecf20Sopenharmony_ci "3: adr lr, 2f \n\t" \ 458c2ecf20Sopenharmony_ci " bx lr \n\t" \ 468c2ecf20Sopenharmony_ci ".arm \n\t" \ 478c2ecf20Sopenharmony_ci "2: nop \n\t" \ 488c2ecf20Sopenharmony_ci TESTCASE_END 498c2ecf20Sopenharmony_ci 508c2ecf20Sopenharmony_ci 518c2ecf20Sopenharmony_civoid kprobe_arm_test_cases(void) 528c2ecf20Sopenharmony_ci{ 538c2ecf20Sopenharmony_ci kprobe_test_flags = 0; 548c2ecf20Sopenharmony_ci 558c2ecf20Sopenharmony_ci TEST_GROUP("Data-processing (register), (register-shifted register), (immediate)") 568c2ecf20Sopenharmony_ci 578c2ecf20Sopenharmony_ci#define _DATA_PROCESSING_DNM(op,s,val) \ 588c2ecf20Sopenharmony_ci TEST_RR( op "eq" s " r0, r",1, VAL1,", r",2, val, "") \ 598c2ecf20Sopenharmony_ci TEST_RR( op "ne" s " r1, r",1, VAL1,", r",2, val, ", lsl #3") \ 608c2ecf20Sopenharmony_ci TEST_RR( op "cs" s " r2, r",3, VAL1,", r",2, val, ", lsr #4") \ 618c2ecf20Sopenharmony_ci TEST_RR( op "cc" s " r3, r",3, VAL1,", r",2, val, ", asr #5") \ 628c2ecf20Sopenharmony_ci TEST_RR( op "mi" s " r4, r",5, VAL1,", r",2, N(val),", asr #6") \ 638c2ecf20Sopenharmony_ci TEST_RR( op "pl" s " r5, r",5, VAL1,", r",2, val, ", ror #7") \ 648c2ecf20Sopenharmony_ci TEST_RR( op "vs" s " r6, r",7, VAL1,", r",2, val, ", rrx") \ 658c2ecf20Sopenharmony_ci TEST_R( op "vc" s " r6, r",7, VAL1,", pc, lsl #3") \ 668c2ecf20Sopenharmony_ci TEST_R( op "vc" s " r6, r",7, VAL1,", sp, lsr #4") \ 678c2ecf20Sopenharmony_ci TEST_R( op "vc" s " r6, pc, r",7, VAL1,", asr #5") \ 688c2ecf20Sopenharmony_ci TEST_R( op "vc" s " r6, sp, r",7, VAL1,", ror #6") \ 698c2ecf20Sopenharmony_ci TEST_RRR( op "hi" s " r8, r",9, VAL1,", r",14,val, ", lsl r",0, 3,"")\ 708c2ecf20Sopenharmony_ci TEST_RRR( op "ls" s " r9, r",9, VAL1,", r",14,val, ", lsr r",7, 4,"")\ 718c2ecf20Sopenharmony_ci TEST_RRR( op "ge" s " r10, r",11,VAL1,", r",14,val, ", asr r",7, 5,"")\ 728c2ecf20Sopenharmony_ci TEST_RRR( op "lt" s " r11, r",11,VAL1,", r",14,N(val),", asr r",7, 6,"")\ 738c2ecf20Sopenharmony_ci TEST_RR( op "gt" s " r12, r13" ", r",14,val, ", ror r",14,7,"")\ 748c2ecf20Sopenharmony_ci TEST_RR( op "le" s " r14, r",0, val, ", r13" ", lsl r",14,8,"")\ 758c2ecf20Sopenharmony_ci TEST_R( op "eq" s " r0, r",11,VAL1,", #0xf5") \ 768c2ecf20Sopenharmony_ci TEST_R( op "ne" s " r11, r",0, VAL1,", #0xf5000000") \ 778c2ecf20Sopenharmony_ci TEST_R( op s " r7, r",8, VAL2,", #0x000af000") \ 788c2ecf20Sopenharmony_ci TEST( op s " r4, pc" ", #0x00005a00") 798c2ecf20Sopenharmony_ci 808c2ecf20Sopenharmony_ci#define DATA_PROCESSING_DNM(op,val) \ 818c2ecf20Sopenharmony_ci _DATA_PROCESSING_DNM(op,"",val) \ 828c2ecf20Sopenharmony_ci _DATA_PROCESSING_DNM(op,"s",val) 838c2ecf20Sopenharmony_ci 848c2ecf20Sopenharmony_ci#define DATA_PROCESSING_NM(op,val) \ 858c2ecf20Sopenharmony_ci TEST_RR( op "ne r",1, VAL1,", r",2, val, "") \ 868c2ecf20Sopenharmony_ci TEST_RR( op "eq r",1, VAL1,", r",2, val, ", lsl #3") \ 878c2ecf20Sopenharmony_ci TEST_RR( op "cc r",3, VAL1,", r",2, val, ", lsr #4") \ 888c2ecf20Sopenharmony_ci TEST_RR( op "cs r",3, VAL1,", r",2, val, ", asr #5") \ 898c2ecf20Sopenharmony_ci TEST_RR( op "pl r",5, VAL1,", r",2, N(val),", asr #6") \ 908c2ecf20Sopenharmony_ci TEST_RR( op "mi r",5, VAL1,", r",2, val, ", ror #7") \ 918c2ecf20Sopenharmony_ci TEST_RR( op "vc r",7, VAL1,", r",2, val, ", rrx") \ 928c2ecf20Sopenharmony_ci TEST_R ( op "vs r",7, VAL1,", pc, lsl #3") \ 938c2ecf20Sopenharmony_ci TEST_R ( op "vs r",7, VAL1,", sp, lsr #4") \ 948c2ecf20Sopenharmony_ci TEST_R( op "vs pc, r",7, VAL1,", asr #5") \ 958c2ecf20Sopenharmony_ci TEST_R( op "vs sp, r",7, VAL1,", ror #6") \ 968c2ecf20Sopenharmony_ci TEST_RRR( op "ls r",9, VAL1,", r",14,val, ", lsl r",0, 3,"") \ 978c2ecf20Sopenharmony_ci TEST_RRR( op "hi r",9, VAL1,", r",14,val, ", lsr r",7, 4,"") \ 988c2ecf20Sopenharmony_ci TEST_RRR( op "lt r",11,VAL1,", r",14,val, ", asr r",7, 5,"") \ 998c2ecf20Sopenharmony_ci TEST_RRR( op "ge r",11,VAL1,", r",14,N(val),", asr r",7, 6,"") \ 1008c2ecf20Sopenharmony_ci TEST_RR( op "le r13" ", r",14,val, ", ror r",14,7,"") \ 1018c2ecf20Sopenharmony_ci TEST_RR( op "gt r",0, val, ", r13" ", lsl r",14,8,"") \ 1028c2ecf20Sopenharmony_ci TEST_R( op "eq r",11,VAL1,", #0xf5") \ 1038c2ecf20Sopenharmony_ci TEST_R( op "ne r",0, VAL1,", #0xf5000000") \ 1048c2ecf20Sopenharmony_ci TEST_R( op " r",8, VAL2,", #0x000af000") 1058c2ecf20Sopenharmony_ci 1068c2ecf20Sopenharmony_ci#define _DATA_PROCESSING_DM(op,s,val) \ 1078c2ecf20Sopenharmony_ci TEST_R( op "eq" s " r0, r",1, val, "") \ 1088c2ecf20Sopenharmony_ci TEST_R( op "ne" s " r1, r",1, val, ", lsl #3") \ 1098c2ecf20Sopenharmony_ci TEST_R( op "cs" s " r2, r",3, val, ", lsr #4") \ 1108c2ecf20Sopenharmony_ci TEST_R( op "cc" s " r3, r",3, val, ", asr #5") \ 1118c2ecf20Sopenharmony_ci TEST_R( op "mi" s " r4, r",5, N(val),", asr #6") \ 1128c2ecf20Sopenharmony_ci TEST_R( op "pl" s " r5, r",5, val, ", ror #7") \ 1138c2ecf20Sopenharmony_ci TEST_R( op "vs" s " r6, r",10,val, ", rrx") \ 1148c2ecf20Sopenharmony_ci TEST( op "vs" s " r7, pc, lsl #3") \ 1158c2ecf20Sopenharmony_ci TEST( op "vs" s " r7, sp, lsr #4") \ 1168c2ecf20Sopenharmony_ci TEST_RR( op "vc" s " r8, r",7, val, ", lsl r",0, 3,"") \ 1178c2ecf20Sopenharmony_ci TEST_RR( op "hi" s " r9, r",9, val, ", lsr r",7, 4,"") \ 1188c2ecf20Sopenharmony_ci TEST_RR( op "ls" s " r10, r",9, val, ", asr r",7, 5,"") \ 1198c2ecf20Sopenharmony_ci TEST_RR( op "ge" s " r11, r",11,N(val),", asr r",7, 6,"") \ 1208c2ecf20Sopenharmony_ci TEST_RR( op "lt" s " r12, r",11,val, ", ror r",14,7,"") \ 1218c2ecf20Sopenharmony_ci TEST_R( op "gt" s " r14, r13" ", lsl r",14,8,"") \ 1228c2ecf20Sopenharmony_ci TEST( op "eq" s " r0, #0xf5") \ 1238c2ecf20Sopenharmony_ci TEST( op "ne" s " r11, #0xf5000000") \ 1248c2ecf20Sopenharmony_ci TEST( op s " r7, #0x000af000") \ 1258c2ecf20Sopenharmony_ci TEST( op s " r4, #0x00005a00") 1268c2ecf20Sopenharmony_ci 1278c2ecf20Sopenharmony_ci#define DATA_PROCESSING_DM(op,val) \ 1288c2ecf20Sopenharmony_ci _DATA_PROCESSING_DM(op,"",val) \ 1298c2ecf20Sopenharmony_ci _DATA_PROCESSING_DM(op,"s",val) 1308c2ecf20Sopenharmony_ci 1318c2ecf20Sopenharmony_ci DATA_PROCESSING_DNM("and",0xf00f00ff) 1328c2ecf20Sopenharmony_ci DATA_PROCESSING_DNM("eor",0xf00f00ff) 1338c2ecf20Sopenharmony_ci DATA_PROCESSING_DNM("sub",VAL2) 1348c2ecf20Sopenharmony_ci DATA_PROCESSING_DNM("rsb",VAL2) 1358c2ecf20Sopenharmony_ci DATA_PROCESSING_DNM("add",VAL2) 1368c2ecf20Sopenharmony_ci DATA_PROCESSING_DNM("adc",VAL2) 1378c2ecf20Sopenharmony_ci DATA_PROCESSING_DNM("sbc",VAL2) 1388c2ecf20Sopenharmony_ci DATA_PROCESSING_DNM("rsc",VAL2) 1398c2ecf20Sopenharmony_ci DATA_PROCESSING_NM("tst",0xf00f00ff) 1408c2ecf20Sopenharmony_ci DATA_PROCESSING_NM("teq",0xf00f00ff) 1418c2ecf20Sopenharmony_ci DATA_PROCESSING_NM("cmp",VAL2) 1428c2ecf20Sopenharmony_ci DATA_PROCESSING_NM("cmn",VAL2) 1438c2ecf20Sopenharmony_ci DATA_PROCESSING_DNM("orr",0xf00f00ff) 1448c2ecf20Sopenharmony_ci DATA_PROCESSING_DM("mov",VAL2) 1458c2ecf20Sopenharmony_ci DATA_PROCESSING_DNM("bic",0xf00f00ff) 1468c2ecf20Sopenharmony_ci DATA_PROCESSING_DM("mvn",VAL2) 1478c2ecf20Sopenharmony_ci 1488c2ecf20Sopenharmony_ci TEST("mov ip, sp") /* This has special case emulation code */ 1498c2ecf20Sopenharmony_ci 1508c2ecf20Sopenharmony_ci TEST_SUPPORTED("mov pc, #0x1000"); 1518c2ecf20Sopenharmony_ci TEST_SUPPORTED("mov sp, #0x1000"); 1528c2ecf20Sopenharmony_ci TEST_SUPPORTED("cmp pc, #0x1000"); 1538c2ecf20Sopenharmony_ci TEST_SUPPORTED("cmp sp, #0x1000"); 1548c2ecf20Sopenharmony_ci 1558c2ecf20Sopenharmony_ci /* Data-processing with PC and a shift count in a register */ 1568c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe15c0f1e) " @ cmp r12, r14, asl pc") 1578c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe1a0cf1e) " @ mov r12, r14, asl pc") 1588c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe08caf1e) " @ add r10, r12, r14, asl pc") 1598c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe151021f) " @ cmp r1, pc, lsl r2") 1608c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe17f0211) " @ cmn pc, r1, lsl r2") 1618c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe1a0121f) " @ mov r1, pc, lsl r2") 1628c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe1a0f211) " @ mov pc, r1, lsl r2") 1638c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe042131f) " @ sub r1, r2, pc, lsl r3") 1648c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe1cf1312) " @ bic r1, pc, r2, lsl r3") 1658c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe081f312) " @ add pc, r1, r2, lsl r3") 1668c2ecf20Sopenharmony_ci 1678c2ecf20Sopenharmony_ci /* Data-processing with PC as a target and status registers updated */ 1688c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("movs pc, r1") 1698c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("movs pc, r1, lsl r2") 1708c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("movs pc, #0x10000") 1718c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("adds pc, lr, r1") 1728c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("adds pc, lr, r1, lsl r2") 1738c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("adds pc, lr, #4") 1748c2ecf20Sopenharmony_ci 1758c2ecf20Sopenharmony_ci /* Data-processing with SP as target */ 1768c2ecf20Sopenharmony_ci TEST("add sp, sp, #16") 1778c2ecf20Sopenharmony_ci TEST("sub sp, sp, #8") 1788c2ecf20Sopenharmony_ci TEST("bic sp, sp, #0x20") 1798c2ecf20Sopenharmony_ci TEST("orr sp, sp, #0x20") 1808c2ecf20Sopenharmony_ci TEST_PR( "add sp, r",10,0,", r",11,4,"") 1818c2ecf20Sopenharmony_ci TEST_PRR("add sp, r",10,0,", r",11,4,", asl r",12,1,"") 1828c2ecf20Sopenharmony_ci TEST_P( "mov sp, r",10,0,"") 1838c2ecf20Sopenharmony_ci TEST_PR( "mov sp, r",10,0,", asl r",12,0,"") 1848c2ecf20Sopenharmony_ci 1858c2ecf20Sopenharmony_ci /* Data-processing with PC as target */ 1868c2ecf20Sopenharmony_ci TEST_BF( "add pc, pc, #2f-1b-8") 1878c2ecf20Sopenharmony_ci TEST_BF_R ("add pc, pc, r",14,2f-1f-8,"") 1888c2ecf20Sopenharmony_ci TEST_BF_R ("add pc, r",14,2f-1f-8,", pc") 1898c2ecf20Sopenharmony_ci TEST_BF_R ("mov pc, r",0,2f,"") 1908c2ecf20Sopenharmony_ci TEST_BF_R ("add pc, pc, r",14,(2f-1f-8)*2,", asr #1") 1918c2ecf20Sopenharmony_ci TEST_BB( "sub pc, pc, #1b-2b+8") 1928c2ecf20Sopenharmony_ci#if __LINUX_ARM_ARCH__ == 6 && !defined(CONFIG_CPU_V7) 1938c2ecf20Sopenharmony_ci TEST_BB( "sub pc, pc, #1b-2b+8-2") /* UNPREDICTABLE before and after ARMv6 */ 1948c2ecf20Sopenharmony_ci#endif 1958c2ecf20Sopenharmony_ci TEST_BB_R( "sub pc, pc, r",14, 1f-2f+8,"") 1968c2ecf20Sopenharmony_ci TEST_BB_R( "rsb pc, r",14,1f-2f+8,", pc") 1978c2ecf20Sopenharmony_ci TEST_R( "add pc, pc, r",10,-2,", asl #1") 1988c2ecf20Sopenharmony_ci#ifdef CONFIG_THUMB2_KERNEL 1998c2ecf20Sopenharmony_ci TEST_ARM_TO_THUMB_INTERWORK_R("add pc, pc, r",0,3f-1f-8+1,"") 2008c2ecf20Sopenharmony_ci TEST_ARM_TO_THUMB_INTERWORK_R("sub pc, r",0,3f+8+1,", #8") 2018c2ecf20Sopenharmony_ci#endif 2028c2ecf20Sopenharmony_ci TEST_GROUP("Miscellaneous instructions") 2038c2ecf20Sopenharmony_ci 2048c2ecf20Sopenharmony_ci TEST_RMASKED("mrs r",0,~PSR_IGNORE_BITS,", cpsr") 2058c2ecf20Sopenharmony_ci TEST_RMASKED("mrspl r",7,~PSR_IGNORE_BITS,", cpsr") 2068c2ecf20Sopenharmony_ci TEST_RMASKED("mrs r",14,~PSR_IGNORE_BITS,", cpsr") 2078c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe10ff000) " @ mrs r15, cpsr") 2088c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("mrs r0, spsr") 2098c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("mrs lr, spsr") 2108c2ecf20Sopenharmony_ci 2118c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("msr cpsr, r0") 2128c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("msr cpsr_f, lr") 2138c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("msr spsr, r0") 2148c2ecf20Sopenharmony_ci 2158c2ecf20Sopenharmony_ci#if __LINUX_ARM_ARCH__ >= 5 || \ 2168c2ecf20Sopenharmony_ci (__LINUX_ARM_ARCH__ == 4 && !defined(CONFIG_CPU_32v4)) 2178c2ecf20Sopenharmony_ci TEST_BF_R("bx r",0,2f,"") 2188c2ecf20Sopenharmony_ci TEST_BB_R("bx r",7,2f,"") 2198c2ecf20Sopenharmony_ci TEST_BF_R("bxeq r",14,2f,"") 2208c2ecf20Sopenharmony_ci#endif 2218c2ecf20Sopenharmony_ci 2228c2ecf20Sopenharmony_ci#if __LINUX_ARM_ARCH__ >= 5 2238c2ecf20Sopenharmony_ci TEST_R("clz r0, r",0, 0x0,"") 2248c2ecf20Sopenharmony_ci TEST_R("clzeq r7, r",14,0x1,"") 2258c2ecf20Sopenharmony_ci TEST_R("clz lr, r",7, 0xffffffff,"") 2268c2ecf20Sopenharmony_ci TEST( "clz r4, sp") 2278c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0x016fff10) " @ clz pc, r0") 2288c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0x016f0f1f) " @ clz r0, pc") 2298c2ecf20Sopenharmony_ci 2308c2ecf20Sopenharmony_ci#if __LINUX_ARM_ARCH__ >= 6 2318c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("bxj r0") 2328c2ecf20Sopenharmony_ci#endif 2338c2ecf20Sopenharmony_ci 2348c2ecf20Sopenharmony_ci TEST_BF_R("blx r",0,2f,"") 2358c2ecf20Sopenharmony_ci TEST_BB_R("blx r",7,2f,"") 2368c2ecf20Sopenharmony_ci TEST_BF_R("blxeq r",14,2f,"") 2378c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0x0120003f) " @ blx pc") 2388c2ecf20Sopenharmony_ci 2398c2ecf20Sopenharmony_ci TEST_RR( "qadd r0, r",1, VAL1,", r",2, VAL2,"") 2408c2ecf20Sopenharmony_ci TEST_RR( "qaddvs lr, r",9, VAL2,", r",8, VAL1,"") 2418c2ecf20Sopenharmony_ci TEST_R( "qadd lr, r",9, VAL2,", r13") 2428c2ecf20Sopenharmony_ci TEST_RR( "qsub r0, r",1, VAL1,", r",2, VAL2,"") 2438c2ecf20Sopenharmony_ci TEST_RR( "qsubvs lr, r",9, VAL2,", r",8, VAL1,"") 2448c2ecf20Sopenharmony_ci TEST_R( "qsub lr, r",9, VAL2,", r13") 2458c2ecf20Sopenharmony_ci TEST_RR( "qdadd r0, r",1, VAL1,", r",2, VAL2,"") 2468c2ecf20Sopenharmony_ci TEST_RR( "qdaddvs lr, r",9, VAL2,", r",8, VAL1,"") 2478c2ecf20Sopenharmony_ci TEST_R( "qdadd lr, r",9, VAL2,", r13") 2488c2ecf20Sopenharmony_ci TEST_RR( "qdsub r0, r",1, VAL1,", r",2, VAL2,"") 2498c2ecf20Sopenharmony_ci TEST_RR( "qdsubvs lr, r",9, VAL2,", r",8, VAL1,"") 2508c2ecf20Sopenharmony_ci TEST_R( "qdsub lr, r",9, VAL2,", r13") 2518c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe101f050) " @ qadd pc, r0, r1") 2528c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe121f050) " @ qsub pc, r0, r1") 2538c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe141f050) " @ qdadd pc, r0, r1") 2548c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe161f050) " @ qdsub pc, r0, r1") 2558c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe16f2050) " @ qdsub r2, r0, pc") 2568c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe161205f) " @ qdsub r2, pc, r1") 2578c2ecf20Sopenharmony_ci 2588c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("bkpt 0xffff") 2598c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("bkpt 0x0000") 2608c2ecf20Sopenharmony_ci 2618c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe1600070) " @ smc #0") 2628c2ecf20Sopenharmony_ci 2638c2ecf20Sopenharmony_ci TEST_GROUP("Halfword multiply and multiply-accumulate") 2648c2ecf20Sopenharmony_ci 2658c2ecf20Sopenharmony_ci TEST_RRR( "smlabb r0, r",1, VAL1,", r",2, VAL2,", r",3, VAL3,"") 2668c2ecf20Sopenharmony_ci TEST_RRR( "smlabbge r7, r",8, VAL3,", r",9, VAL1,", r",10, VAL2,"") 2678c2ecf20Sopenharmony_ci TEST_RR( "smlabb lr, r",1, VAL2,", r",2, VAL3,", r13") 2688c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe10f3281) " @ smlabb pc, r1, r2, r3") 2698c2ecf20Sopenharmony_ci TEST_RRR( "smlatb r0, r",1, VAL1,", r",2, VAL2,", r",3, VAL3,"") 2708c2ecf20Sopenharmony_ci TEST_RRR( "smlatbge r7, r",8, VAL3,", r",9, VAL1,", r",10, VAL2,"") 2718c2ecf20Sopenharmony_ci TEST_RR( "smlatb lr, r",1, VAL2,", r",2, VAL3,", r13") 2728c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe10f32a1) " @ smlatb pc, r1, r2, r3") 2738c2ecf20Sopenharmony_ci TEST_RRR( "smlabt r0, r",1, VAL1,", r",2, VAL2,", r",3, VAL3,"") 2748c2ecf20Sopenharmony_ci TEST_RRR( "smlabtge r7, r",8, VAL3,", r",9, VAL1,", r",10, VAL2,"") 2758c2ecf20Sopenharmony_ci TEST_RR( "smlabt lr, r",1, VAL2,", r",2, VAL3,", r13") 2768c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe10f32c1) " @ smlabt pc, r1, r2, r3") 2778c2ecf20Sopenharmony_ci TEST_RRR( "smlatt r0, r",1, VAL1,", r",2, VAL2,", r",3, VAL3,"") 2788c2ecf20Sopenharmony_ci TEST_RRR( "smlattge r7, r",8, VAL3,", r",9, VAL1,", r",10, VAL2,"") 2798c2ecf20Sopenharmony_ci TEST_RR( "smlatt lr, r",1, VAL2,", r",2, VAL3,", r13") 2808c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe10f32e1) " @ smlatt pc, r1, r2, r3") 2818c2ecf20Sopenharmony_ci 2828c2ecf20Sopenharmony_ci TEST_RRR( "smlawb r0, r",1, VAL1,", r",2, VAL2,", r",3, VAL3,"") 2838c2ecf20Sopenharmony_ci TEST_RRR( "smlawbge r7, r",8, VAL3,", r",9, VAL1,", r",10, VAL2,"") 2848c2ecf20Sopenharmony_ci TEST_RR( "smlawb lr, r",1, VAL2,", r",2, VAL3,", r13") 2858c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe12f3281) " @ smlawb pc, r1, r2, r3") 2868c2ecf20Sopenharmony_ci TEST_RRR( "smlawt r0, r",1, VAL1,", r",2, VAL2,", r",3, VAL3,"") 2878c2ecf20Sopenharmony_ci TEST_RRR( "smlawtge r7, r",8, VAL3,", r",9, VAL1,", r",10, VAL2,"") 2888c2ecf20Sopenharmony_ci TEST_RR( "smlawt lr, r",1, VAL2,", r",2, VAL3,", r13") 2898c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe12f32c1) " @ smlawt pc, r1, r2, r3") 2908c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe12032cf) " @ smlawt r0, pc, r2, r3") 2918c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe1203fc1) " @ smlawt r0, r1, pc, r3") 2928c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe120f2c1) " @ smlawt r0, r1, r2, pc") 2938c2ecf20Sopenharmony_ci 2948c2ecf20Sopenharmony_ci TEST_RR( "smulwb r0, r",1, VAL1,", r",2, VAL2,"") 2958c2ecf20Sopenharmony_ci TEST_RR( "smulwbge r7, r",8, VAL3,", r",9, VAL1,"") 2968c2ecf20Sopenharmony_ci TEST_R( "smulwb lr, r",1, VAL2,", r13") 2978c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe12f02a1) " @ smulwb pc, r1, r2") 2988c2ecf20Sopenharmony_ci TEST_RR( "smulwt r0, r",1, VAL1,", r",2, VAL2,"") 2998c2ecf20Sopenharmony_ci TEST_RR( "smulwtge r7, r",8, VAL3,", r",9, VAL1,"") 3008c2ecf20Sopenharmony_ci TEST_R( "smulwt lr, r",1, VAL2,", r13") 3018c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe12f02e1) " @ smulwt pc, r1, r2") 3028c2ecf20Sopenharmony_ci 3038c2ecf20Sopenharmony_ci TEST_RRRR( "smlalbb r",0, VAL1,", r",1, VAL2,", r",2, VAL3,", r",3, VAL4) 3048c2ecf20Sopenharmony_ci TEST_RRRR( "smlalbble r",8, VAL4,", r",9, VAL1,", r",10,VAL2,", r",11,VAL3) 3058c2ecf20Sopenharmony_ci TEST_RRR( "smlalbb r",14,VAL3,", r",7, VAL4,", r",5, VAL1,", r13") 3068c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe14f1382) " @ smlalbb pc, r1, r2, r3") 3078c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe141f382) " @ smlalbb r1, pc, r2, r3") 3088c2ecf20Sopenharmony_ci TEST_RRRR( "smlaltb r",0, VAL1,", r",1, VAL2,", r",2, VAL3,", r",3, VAL4) 3098c2ecf20Sopenharmony_ci TEST_RRRR( "smlaltble r",8, VAL4,", r",9, VAL1,", r",10,VAL2,", r",11,VAL3) 3108c2ecf20Sopenharmony_ci TEST_RRR( "smlaltb r",14,VAL3,", r",7, VAL4,", r",5, VAL1,", r13") 3118c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe14f13a2) " @ smlaltb pc, r1, r2, r3") 3128c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe141f3a2) " @ smlaltb r1, pc, r2, r3") 3138c2ecf20Sopenharmony_ci TEST_RRRR( "smlalbt r",0, VAL1,", r",1, VAL2,", r",2, VAL3,", r",3, VAL4) 3148c2ecf20Sopenharmony_ci TEST_RRRR( "smlalbtle r",8, VAL4,", r",9, VAL1,", r",10,VAL2,", r",11,VAL3) 3158c2ecf20Sopenharmony_ci TEST_RRR( "smlalbt r",14,VAL3,", r",7, VAL4,", r",5, VAL1,", r13") 3168c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe14f13c2) " @ smlalbt pc, r1, r2, r3") 3178c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe141f3c2) " @ smlalbt r1, pc, r2, r3") 3188c2ecf20Sopenharmony_ci TEST_RRRR( "smlaltt r",0, VAL1,", r",1, VAL2,", r",2, VAL3,", r",3, VAL4) 3198c2ecf20Sopenharmony_ci TEST_RRRR( "smlalttle r",8, VAL4,", r",9, VAL1,", r",10,VAL2,", r",11,VAL3) 3208c2ecf20Sopenharmony_ci TEST_RRR( "smlaltt r",14,VAL3,", r",7, VAL4,", r",5, VAL1,", r13") 3218c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe14f13e2) " @ smlalbb pc, r1, r2, r3") 3228c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe140f3e2) " @ smlalbb r0, pc, r2, r3") 3238c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe14013ef) " @ smlalbb r0, r1, pc, r3") 3248c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe1401fe2) " @ smlalbb r0, r1, r2, pc") 3258c2ecf20Sopenharmony_ci 3268c2ecf20Sopenharmony_ci TEST_RR( "smulbb r0, r",1, VAL1,", r",2, VAL2,"") 3278c2ecf20Sopenharmony_ci TEST_RR( "smulbbge r7, r",8, VAL3,", r",9, VAL1,"") 3288c2ecf20Sopenharmony_ci TEST_R( "smulbb lr, r",1, VAL2,", r13") 3298c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe16f0281) " @ smulbb pc, r1, r2") 3308c2ecf20Sopenharmony_ci TEST_RR( "smultb r0, r",1, VAL1,", r",2, VAL2,"") 3318c2ecf20Sopenharmony_ci TEST_RR( "smultbge r7, r",8, VAL3,", r",9, VAL1,"") 3328c2ecf20Sopenharmony_ci TEST_R( "smultb lr, r",1, VAL2,", r13") 3338c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe16f02a1) " @ smultb pc, r1, r2") 3348c2ecf20Sopenharmony_ci TEST_RR( "smulbt r0, r",1, VAL1,", r",2, VAL2,"") 3358c2ecf20Sopenharmony_ci TEST_RR( "smulbtge r7, r",8, VAL3,", r",9, VAL1,"") 3368c2ecf20Sopenharmony_ci TEST_R( "smulbt lr, r",1, VAL2,", r13") 3378c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe16f02c1) " @ smultb pc, r1, r2") 3388c2ecf20Sopenharmony_ci TEST_RR( "smultt r0, r",1, VAL1,", r",2, VAL2,"") 3398c2ecf20Sopenharmony_ci TEST_RR( "smulttge r7, r",8, VAL3,", r",9, VAL1,"") 3408c2ecf20Sopenharmony_ci TEST_R( "smultt lr, r",1, VAL2,", r13") 3418c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe16f02e1) " @ smultt pc, r1, r2") 3428c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe16002ef) " @ smultt r0, pc, r2") 3438c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe1600fe1) " @ smultt r0, r1, pc") 3448c2ecf20Sopenharmony_ci#endif 3458c2ecf20Sopenharmony_ci 3468c2ecf20Sopenharmony_ci TEST_GROUP("Multiply and multiply-accumulate") 3478c2ecf20Sopenharmony_ci 3488c2ecf20Sopenharmony_ci TEST_RR( "mul r0, r",1, VAL1,", r",2, VAL2,"") 3498c2ecf20Sopenharmony_ci TEST_RR( "mulls r7, r",8, VAL2,", r",9, VAL2,"") 3508c2ecf20Sopenharmony_ci TEST_R( "mul lr, r",4, VAL3,", r13") 3518c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe00f0291) " @ mul pc, r1, r2") 3528c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe000029f) " @ mul r0, pc, r2") 3538c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe0000f91) " @ mul r0, r1, pc") 3548c2ecf20Sopenharmony_ci TEST_RR( "muls r0, r",1, VAL1,", r",2, VAL2,"") 3558c2ecf20Sopenharmony_ci TEST_RR( "mullss r7, r",8, VAL2,", r",9, VAL2,"") 3568c2ecf20Sopenharmony_ci TEST_R( "muls lr, r",4, VAL3,", r13") 3578c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe01f0291) " @ muls pc, r1, r2") 3588c2ecf20Sopenharmony_ci 3598c2ecf20Sopenharmony_ci TEST_RRR( "mla r0, r",1, VAL1,", r",2, VAL2,", r",3, VAL3,"") 3608c2ecf20Sopenharmony_ci TEST_RRR( "mlahi r7, r",8, VAL3,", r",9, VAL1,", r",10, VAL2,"") 3618c2ecf20Sopenharmony_ci TEST_RR( "mla lr, r",1, VAL2,", r",2, VAL3,", r13") 3628c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe02f3291) " @ mla pc, r1, r2, r3") 3638c2ecf20Sopenharmony_ci TEST_RRR( "mlas r0, r",1, VAL1,", r",2, VAL2,", r",3, VAL3,"") 3648c2ecf20Sopenharmony_ci TEST_RRR( "mlahis r7, r",8, VAL3,", r",9, VAL1,", r",10, VAL2,"") 3658c2ecf20Sopenharmony_ci TEST_RR( "mlas lr, r",1, VAL2,", r",2, VAL3,", r13") 3668c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe03f3291) " @ mlas pc, r1, r2, r3") 3678c2ecf20Sopenharmony_ci 3688c2ecf20Sopenharmony_ci#if __LINUX_ARM_ARCH__ >= 6 3698c2ecf20Sopenharmony_ci TEST_RR( "umaal r0, r1, r",2, VAL1,", r",3, VAL2,"") 3708c2ecf20Sopenharmony_ci TEST_RR( "umaalls r7, r8, r",9, VAL2,", r",10, VAL1,"") 3718c2ecf20Sopenharmony_ci TEST_R( "umaal lr, r12, r",11,VAL3,", r13") 3728c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe041f392) " @ umaal pc, r1, r2, r3") 3738c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe04f0392) " @ umaal r0, pc, r2, r3") 3748c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe0500090) " @ undef") 3758c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe05fff9f) " @ undef") 3768c2ecf20Sopenharmony_ci#endif 3778c2ecf20Sopenharmony_ci 3788c2ecf20Sopenharmony_ci#if __LINUX_ARM_ARCH__ >= 7 3798c2ecf20Sopenharmony_ci TEST_RRR( "mls r0, r",1, VAL1,", r",2, VAL2,", r",3, VAL3,"") 3808c2ecf20Sopenharmony_ci TEST_RRR( "mlshi r7, r",8, VAL3,", r",9, VAL1,", r",10, VAL2,"") 3818c2ecf20Sopenharmony_ci TEST_RR( "mls lr, r",1, VAL2,", r",2, VAL3,", r13") 3828c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe06f3291) " @ mls pc, r1, r2, r3") 3838c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe060329f) " @ mls r0, pc, r2, r3") 3848c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe0603f91) " @ mls r0, r1, pc, r3") 3858c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe060f291) " @ mls r0, r1, r2, pc") 3868c2ecf20Sopenharmony_ci#endif 3878c2ecf20Sopenharmony_ci 3888c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe0700090) " @ undef") 3898c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe07fff9f) " @ undef") 3908c2ecf20Sopenharmony_ci 3918c2ecf20Sopenharmony_ci TEST_RR( "umull r0, r1, r",2, VAL1,", r",3, VAL2,"") 3928c2ecf20Sopenharmony_ci TEST_RR( "umullls r7, r8, r",9, VAL2,", r",10, VAL1,"") 3938c2ecf20Sopenharmony_ci TEST_R( "umull lr, r12, r",11,VAL3,", r13") 3948c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe081f392) " @ umull pc, r1, r2, r3") 3958c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe08f1392) " @ umull r1, pc, r2, r3") 3968c2ecf20Sopenharmony_ci TEST_RR( "umulls r0, r1, r",2, VAL1,", r",3, VAL2,"") 3978c2ecf20Sopenharmony_ci TEST_RR( "umulllss r7, r8, r",9, VAL2,", r",10, VAL1,"") 3988c2ecf20Sopenharmony_ci TEST_R( "umulls lr, r12, r",11,VAL3,", r13") 3998c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe091f392) " @ umulls pc, r1, r2, r3") 4008c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe09f1392) " @ umulls r1, pc, r2, r3") 4018c2ecf20Sopenharmony_ci 4028c2ecf20Sopenharmony_ci TEST_RRRR( "umlal r",0, VAL1,", r",1, VAL2,", r",2, VAL3,", r",3, VAL4) 4038c2ecf20Sopenharmony_ci TEST_RRRR( "umlalle r",8, VAL4,", r",9, VAL1,", r",10,VAL2,", r",11,VAL3) 4048c2ecf20Sopenharmony_ci TEST_RRR( "umlal r",14,VAL3,", r",7, VAL4,", r",5, VAL1,", r13") 4058c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe0af1392) " @ umlal pc, r1, r2, r3") 4068c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe0a1f392) " @ umlal r1, pc, r2, r3") 4078c2ecf20Sopenharmony_ci TEST_RRRR( "umlals r",0, VAL1,", r",1, VAL2,", r",2, VAL3,", r",3, VAL4) 4088c2ecf20Sopenharmony_ci TEST_RRRR( "umlalles r",8, VAL4,", r",9, VAL1,", r",10,VAL2,", r",11,VAL3) 4098c2ecf20Sopenharmony_ci TEST_RRR( "umlals r",14,VAL3,", r",7, VAL4,", r",5, VAL1,", r13") 4108c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe0bf1392) " @ umlals pc, r1, r2, r3") 4118c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe0b1f392) " @ umlals r1, pc, r2, r3") 4128c2ecf20Sopenharmony_ci 4138c2ecf20Sopenharmony_ci TEST_RR( "smull r0, r1, r",2, VAL1,", r",3, VAL2,"") 4148c2ecf20Sopenharmony_ci TEST_RR( "smullls r7, r8, r",9, VAL2,", r",10, VAL1,"") 4158c2ecf20Sopenharmony_ci TEST_R( "smull lr, r12, r",11,VAL3,", r13") 4168c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe0c1f392) " @ smull pc, r1, r2, r3") 4178c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe0cf1392) " @ smull r1, pc, r2, r3") 4188c2ecf20Sopenharmony_ci TEST_RR( "smulls r0, r1, r",2, VAL1,", r",3, VAL2,"") 4198c2ecf20Sopenharmony_ci TEST_RR( "smulllss r7, r8, r",9, VAL2,", r",10, VAL1,"") 4208c2ecf20Sopenharmony_ci TEST_R( "smulls lr, r12, r",11,VAL3,", r13") 4218c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe0d1f392) " @ smulls pc, r1, r2, r3") 4228c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe0df1392) " @ smulls r1, pc, r2, r3") 4238c2ecf20Sopenharmony_ci 4248c2ecf20Sopenharmony_ci TEST_RRRR( "smlal r",0, VAL1,", r",1, VAL2,", r",2, VAL3,", r",3, VAL4) 4258c2ecf20Sopenharmony_ci TEST_RRRR( "smlalle r",8, VAL4,", r",9, VAL1,", r",10,VAL2,", r",11,VAL3) 4268c2ecf20Sopenharmony_ci TEST_RRR( "smlal r",14,VAL3,", r",7, VAL4,", r",5, VAL1,", r13") 4278c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe0ef1392) " @ smlal pc, r1, r2, r3") 4288c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe0e1f392) " @ smlal r1, pc, r2, r3") 4298c2ecf20Sopenharmony_ci TEST_RRRR( "smlals r",0, VAL1,", r",1, VAL2,", r",2, VAL3,", r",3, VAL4) 4308c2ecf20Sopenharmony_ci TEST_RRRR( "smlalles r",8, VAL4,", r",9, VAL1,", r",10,VAL2,", r",11,VAL3) 4318c2ecf20Sopenharmony_ci TEST_RRR( "smlals r",14,VAL3,", r",7, VAL4,", r",5, VAL1,", r13") 4328c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe0ff1392) " @ smlals pc, r1, r2, r3") 4338c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe0f0f392) " @ smlals r0, pc, r2, r3") 4348c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe0f0139f) " @ smlals r0, r1, pc, r3") 4358c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe0f01f92) " @ smlals r0, r1, r2, pc") 4368c2ecf20Sopenharmony_ci 4378c2ecf20Sopenharmony_ci TEST_GROUP("Synchronization primitives") 4388c2ecf20Sopenharmony_ci 4398c2ecf20Sopenharmony_ci#if __LINUX_ARM_ARCH__ < 6 4408c2ecf20Sopenharmony_ci TEST_RP("swp lr, r",7,VAL2,", [r",8,0,"]") 4418c2ecf20Sopenharmony_ci TEST_R( "swpvs r0, r",1,VAL1,", [sp]") 4428c2ecf20Sopenharmony_ci TEST_RP("swp sp, r",14,VAL2,", [r",12,13*4,"]") 4438c2ecf20Sopenharmony_ci#else 4448c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe108e097) " @ swp lr, r7, [r8]") 4458c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0x610d0091) " @ swpvs r0, r1, [sp]") 4468c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe10cd09e) " @ swp sp, r14 [r12]") 4478c2ecf20Sopenharmony_ci#endif 4488c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe102f091) " @ swp pc, r1, [r2]") 4498c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe102009f) " @ swp r0, pc, [r2]") 4508c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe10f0091) " @ swp r0, r1, [pc]") 4518c2ecf20Sopenharmony_ci#if __LINUX_ARM_ARCH__ < 6 4528c2ecf20Sopenharmony_ci TEST_RP("swpb lr, r",7,VAL2,", [r",8,0,"]") 4538c2ecf20Sopenharmony_ci TEST_R( "swpvsb r0, r",1,VAL1,", [sp]") 4548c2ecf20Sopenharmony_ci#else 4558c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe148e097) " @ swpb lr, r7, [r8]") 4568c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0x614d0091) " @ swpvsb r0, r1, [sp]") 4578c2ecf20Sopenharmony_ci#endif 4588c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe142f091) " @ swpb pc, r1, [r2]") 4598c2ecf20Sopenharmony_ci 4608c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe1100090)) /* Unallocated space */ 4618c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe1200090)) /* Unallocated space */ 4628c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe1300090)) /* Unallocated space */ 4638c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe1500090)) /* Unallocated space */ 4648c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe1600090)) /* Unallocated space */ 4658c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe1700090)) /* Unallocated space */ 4668c2ecf20Sopenharmony_ci#if __LINUX_ARM_ARCH__ >= 6 4678c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("ldrex r2, [sp]") 4688c2ecf20Sopenharmony_ci#endif 4698c2ecf20Sopenharmony_ci#if (__LINUX_ARM_ARCH__ >= 7) || defined(CONFIG_CPU_32v6K) 4708c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("strexd r0, r2, r3, [sp]") 4718c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("ldrexd r2, r3, [sp]") 4728c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("strexb r0, r2, [sp]") 4738c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("ldrexb r2, [sp]") 4748c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("strexh r0, r2, [sp]") 4758c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("ldrexh r2, [sp]") 4768c2ecf20Sopenharmony_ci#endif 4778c2ecf20Sopenharmony_ci TEST_GROUP("Extra load/store instructions") 4788c2ecf20Sopenharmony_ci 4798c2ecf20Sopenharmony_ci TEST_RPR( "strh r",0, VAL1,", [r",1, 48,", -r",2, 24,"]") 4808c2ecf20Sopenharmony_ci TEST_RPR( "streqh r",14,VAL2,", [r",11,0, ", r",12, 48,"]") 4818c2ecf20Sopenharmony_ci TEST_UNSUPPORTED( "streqh r14, [r13, r12]") 4828c2ecf20Sopenharmony_ci TEST_UNSUPPORTED( "streqh r14, [r12, r13]") 4838c2ecf20Sopenharmony_ci TEST_RPR( "strh r",1, VAL1,", [r",2, 24,", r",3, 48,"]!") 4848c2ecf20Sopenharmony_ci TEST_RPR( "strneh r",12,VAL2,", [r",11,48,", -r",10,24,"]!") 4858c2ecf20Sopenharmony_ci TEST_RPR( "strh r",2, VAL1,", [r",3, 24,"], r",4, 48,"") 4868c2ecf20Sopenharmony_ci TEST_RPR( "strh r",10,VAL2,", [r",9, 48,"], -r",11,24,"") 4878c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe1afc0ba) " @ strh r12, [pc, r10]!") 4888c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe089f0bb) " @ strh pc, [r9], r11") 4898c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe089a0bf) " @ strh r10, [r9], pc") 4908c2ecf20Sopenharmony_ci 4918c2ecf20Sopenharmony_ci TEST_PR( "ldrh r0, [r",0, 48,", -r",2, 24,"]") 4928c2ecf20Sopenharmony_ci TEST_PR( "ldrcsh r14, [r",13,0, ", r",12, 48,"]") 4938c2ecf20Sopenharmony_ci TEST_PR( "ldrh r1, [r",2, 24,", r",3, 48,"]!") 4948c2ecf20Sopenharmony_ci TEST_PR( "ldrcch r12, [r",11,48,", -r",10,24,"]!") 4958c2ecf20Sopenharmony_ci TEST_PR( "ldrh r2, [r",3, 24,"], r",4, 48,"") 4968c2ecf20Sopenharmony_ci TEST_PR( "ldrh r10, [r",9, 48,"], -r",11,24,"") 4978c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe1bfc0ba) " @ ldrh r12, [pc, r10]!") 4988c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe099f0bb) " @ ldrh pc, [r9], r11") 4998c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe099a0bf) " @ ldrh r10, [r9], pc") 5008c2ecf20Sopenharmony_ci 5018c2ecf20Sopenharmony_ci TEST_RP( "strh r",0, VAL1,", [r",1, 24,", #-2]") 5028c2ecf20Sopenharmony_ci TEST_RP( "strmih r",14,VAL2,", [r",13,0, ", #2]") 5038c2ecf20Sopenharmony_ci TEST_RP( "strh r",1, VAL1,", [r",2, 24,", #4]!") 5048c2ecf20Sopenharmony_ci TEST_RP( "strplh r",12,VAL2,", [r",11,24,", #-4]!") 5058c2ecf20Sopenharmony_ci TEST_RP( "strh r",2, VAL1,", [r",3, 24,"], #48") 5068c2ecf20Sopenharmony_ci TEST_RP( "strh r",10,VAL2,", [r",9, 64,"], #-48") 5078c2ecf20Sopenharmony_ci TEST_RP( "strh r",3, VAL1,", [r",13,TEST_MEMORY_SIZE,", #-"__stringify(MAX_STACK_SIZE)"]!") 5088c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("strh r3, [r13, #-"__stringify(MAX_STACK_SIZE)"-8]!") 5098c2ecf20Sopenharmony_ci TEST_RP( "strh r",4, VAL1,", [r",14,TEST_MEMORY_SIZE,", #-"__stringify(MAX_STACK_SIZE)"-8]!") 5108c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe1efc3b0) " @ strh r12, [pc, #48]!") 5118c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe0c9f3b0) " @ strh pc, [r9], #48") 5128c2ecf20Sopenharmony_ci 5138c2ecf20Sopenharmony_ci TEST_P( "ldrh r0, [r",0, 24,", #-2]") 5148c2ecf20Sopenharmony_ci TEST_P( "ldrvsh r14, [r",13,0, ", #2]") 5158c2ecf20Sopenharmony_ci TEST_P( "ldrh r1, [r",2, 24,", #4]!") 5168c2ecf20Sopenharmony_ci TEST_P( "ldrvch r12, [r",11,24,", #-4]!") 5178c2ecf20Sopenharmony_ci TEST_P( "ldrh r2, [r",3, 24,"], #48") 5188c2ecf20Sopenharmony_ci TEST_P( "ldrh r10, [r",9, 64,"], #-48") 5198c2ecf20Sopenharmony_ci TEST( "ldrh r0, [pc, #0]") 5208c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe1ffc3b0) " @ ldrh r12, [pc, #48]!") 5218c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe0d9f3b0) " @ ldrh pc, [r9], #48") 5228c2ecf20Sopenharmony_ci 5238c2ecf20Sopenharmony_ci TEST_PR( "ldrsb r0, [r",0, 48,", -r",2, 24,"]") 5248c2ecf20Sopenharmony_ci TEST_PR( "ldrhisb r14, [r",13,0,", r",12, 48,"]") 5258c2ecf20Sopenharmony_ci TEST_PR( "ldrsb r1, [r",2, 24,", r",3, 48,"]!") 5268c2ecf20Sopenharmony_ci TEST_PR( "ldrlssb r12, [r",11,48,", -r",10,24,"]!") 5278c2ecf20Sopenharmony_ci TEST_PR( "ldrsb r2, [r",3, 24,"], r",4, 48,"") 5288c2ecf20Sopenharmony_ci TEST_PR( "ldrsb r10, [r",9, 48,"], -r",11,24,"") 5298c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe1bfc0da) " @ ldrsb r12, [pc, r10]!") 5308c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe099f0db) " @ ldrsb pc, [r9], r11") 5318c2ecf20Sopenharmony_ci 5328c2ecf20Sopenharmony_ci TEST_P( "ldrsb r0, [r",0, 24,", #-1]") 5338c2ecf20Sopenharmony_ci TEST_P( "ldrgesb r14, [r",13,0, ", #1]") 5348c2ecf20Sopenharmony_ci TEST_P( "ldrsb r1, [r",2, 24,", #4]!") 5358c2ecf20Sopenharmony_ci TEST_P( "ldrltsb r12, [r",11,24,", #-4]!") 5368c2ecf20Sopenharmony_ci TEST_P( "ldrsb r2, [r",3, 24,"], #48") 5378c2ecf20Sopenharmony_ci TEST_P( "ldrsb r10, [r",9, 64,"], #-48") 5388c2ecf20Sopenharmony_ci TEST( "ldrsb r0, [pc, #0]") 5398c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe1ffc3d0) " @ ldrsb r12, [pc, #48]!") 5408c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe0d9f3d0) " @ ldrsb pc, [r9], #48") 5418c2ecf20Sopenharmony_ci 5428c2ecf20Sopenharmony_ci TEST_PR( "ldrsh r0, [r",0, 48,", -r",2, 24,"]") 5438c2ecf20Sopenharmony_ci TEST_PR( "ldrgtsh r14, [r",13,0, ", r",12, 48,"]") 5448c2ecf20Sopenharmony_ci TEST_PR( "ldrsh r1, [r",2, 24,", r",3, 48,"]!") 5458c2ecf20Sopenharmony_ci TEST_PR( "ldrlesh r12, [r",11,48,", -r",10,24,"]!") 5468c2ecf20Sopenharmony_ci TEST_PR( "ldrsh r2, [r",3, 24,"], r",4, 48,"") 5478c2ecf20Sopenharmony_ci TEST_PR( "ldrsh r10, [r",9, 48,"], -r",11,24,"") 5488c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe1bfc0fa) " @ ldrsh r12, [pc, r10]!") 5498c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe099f0fb) " @ ldrsh pc, [r9], r11") 5508c2ecf20Sopenharmony_ci 5518c2ecf20Sopenharmony_ci TEST_P( "ldrsh r0, [r",0, 24,", #-1]") 5528c2ecf20Sopenharmony_ci TEST_P( "ldreqsh r14, [r",13,0 ,", #1]") 5538c2ecf20Sopenharmony_ci TEST_P( "ldrsh r1, [r",2, 24,", #4]!") 5548c2ecf20Sopenharmony_ci TEST_P( "ldrnesh r12, [r",11,24,", #-4]!") 5558c2ecf20Sopenharmony_ci TEST_P( "ldrsh r2, [r",3, 24,"], #48") 5568c2ecf20Sopenharmony_ci TEST_P( "ldrsh r10, [r",9, 64,"], #-48") 5578c2ecf20Sopenharmony_ci TEST( "ldrsh r0, [pc, #0]") 5588c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe1ffc3f0) " @ ldrsh r12, [pc, #48]!") 5598c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe0d9f3f0) " @ ldrsh pc, [r9], #48") 5608c2ecf20Sopenharmony_ci 5618c2ecf20Sopenharmony_ci#if __LINUX_ARM_ARCH__ >= 7 5628c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("strht r1, [r2], r3") 5638c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("ldrht r1, [r2], r3") 5648c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("strht r1, [r2], #48") 5658c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("ldrht r1, [r2], #48") 5668c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("ldrsbt r1, [r2], r3") 5678c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("ldrsbt r1, [r2], #48") 5688c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("ldrsht r1, [r2], r3") 5698c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("ldrsht r1, [r2], #48") 5708c2ecf20Sopenharmony_ci#endif 5718c2ecf20Sopenharmony_ci 5728c2ecf20Sopenharmony_ci#if __LINUX_ARM_ARCH__ >= 5 5738c2ecf20Sopenharmony_ci TEST_RPR( "strd r",0, VAL1,", [r",1, 48,", -r",2,24,"]") 5748c2ecf20Sopenharmony_ci TEST_RPR( "strccd r",8, VAL2,", [r",11,0, ", r",12,48,"]") 5758c2ecf20Sopenharmony_ci TEST_UNSUPPORTED( "strccd r8, [r13, r12]") 5768c2ecf20Sopenharmony_ci TEST_UNSUPPORTED( "strccd r8, [r12, r13]") 5778c2ecf20Sopenharmony_ci TEST_RPR( "strd r",4, VAL1,", [r",2, 24,", r",3, 48,"]!") 5788c2ecf20Sopenharmony_ci TEST_RPR( "strcsd r",12,VAL2,", [r",11,48,", -r",10,24,"]!") 5798c2ecf20Sopenharmony_ci TEST_RPR( "strd r",2, VAL1,", [r",5, 24,"], r",4,48,"") 5808c2ecf20Sopenharmony_ci TEST_RPR( "strd r",10,VAL2,", [r",9, 48,"], -r",7,24,"") 5818c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe1afc0fa) " @ strd r12, [pc, r10]!") 5828c2ecf20Sopenharmony_ci 5838c2ecf20Sopenharmony_ci TEST_PR( "ldrd r0, [r",0, 48,", -r",2,24,"]") 5848c2ecf20Sopenharmony_ci TEST_PR( "ldrmid r8, [r",13,0, ", r",12,48,"]") 5858c2ecf20Sopenharmony_ci TEST_PR( "ldrd r4, [r",2, 24,", r",3, 48,"]!") 5868c2ecf20Sopenharmony_ci TEST_PR( "ldrpld r6, [r",11,48,", -r",10,24,"]!") 5878c2ecf20Sopenharmony_ci TEST_PR( "ldrd r2, [r",5, 24,"], r",4,48,"") 5888c2ecf20Sopenharmony_ci TEST_PR( "ldrd r10, [r",9,48,"], -r",7,24,"") 5898c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe1afc0da) " @ ldrd r12, [pc, r10]!") 5908c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe089f0db) " @ ldrd pc, [r9], r11") 5918c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe089e0db) " @ ldrd lr, [r9], r11") 5928c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe089c0df) " @ ldrd r12, [r9], pc") 5938c2ecf20Sopenharmony_ci 5948c2ecf20Sopenharmony_ci TEST_RP( "strd r",0, VAL1,", [r",1, 24,", #-8]") 5958c2ecf20Sopenharmony_ci TEST_RP( "strvsd r",8, VAL2,", [r",13,0, ", #8]") 5968c2ecf20Sopenharmony_ci TEST_RP( "strd r",4, VAL1,", [r",2, 24,", #16]!") 5978c2ecf20Sopenharmony_ci TEST_RP( "strvcd r",12,VAL2,", [r",11,24,", #-16]!") 5988c2ecf20Sopenharmony_ci TEST_RP( "strd r",2, VAL1,", [r",4, 24,"], #48") 5998c2ecf20Sopenharmony_ci TEST_RP( "strd r",10,VAL2,", [r",9, 64,"], #-48") 6008c2ecf20Sopenharmony_ci TEST_RP( "strd r",6, VAL1,", [r",13,TEST_MEMORY_SIZE,", #-"__stringify(MAX_STACK_SIZE)"]!") 6018c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("strd r6, [r13, #-"__stringify(MAX_STACK_SIZE)"-8]!") 6028c2ecf20Sopenharmony_ci TEST_RP( "strd r",4, VAL1,", [r",12,TEST_MEMORY_SIZE,", #-"__stringify(MAX_STACK_SIZE)"-8]!") 6038c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe1efc3f0) " @ strd r12, [pc, #48]!") 6048c2ecf20Sopenharmony_ci 6058c2ecf20Sopenharmony_ci TEST_P( "ldrd r0, [r",0, 24,", #-8]") 6068c2ecf20Sopenharmony_ci TEST_P( "ldrhid r8, [r",13,0, ", #8]") 6078c2ecf20Sopenharmony_ci TEST_P( "ldrd r4, [r",2, 24,", #16]!") 6088c2ecf20Sopenharmony_ci TEST_P( "ldrlsd r6, [r",11,24,", #-16]!") 6098c2ecf20Sopenharmony_ci TEST_P( "ldrd r2, [r",5, 24,"], #48") 6108c2ecf20Sopenharmony_ci TEST_P( "ldrd r10, [r",9,6,"], #-48") 6118c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe1efc3d0) " @ ldrd r12, [pc, #48]!") 6128c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe0c9f3d0) " @ ldrd pc, [r9], #48") 6138c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe0c9e3d0) " @ ldrd lr, [r9], #48") 6148c2ecf20Sopenharmony_ci#endif 6158c2ecf20Sopenharmony_ci 6168c2ecf20Sopenharmony_ci TEST_GROUP("Miscellaneous") 6178c2ecf20Sopenharmony_ci 6188c2ecf20Sopenharmony_ci#if __LINUX_ARM_ARCH__ >= 7 6198c2ecf20Sopenharmony_ci TEST("movw r0, #0") 6208c2ecf20Sopenharmony_ci TEST("movw r0, #0xffff") 6218c2ecf20Sopenharmony_ci TEST("movw lr, #0xffff") 6228c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe300f000) " @ movw pc, #0") 6238c2ecf20Sopenharmony_ci TEST_R("movt r",0, VAL1,", #0") 6248c2ecf20Sopenharmony_ci TEST_R("movt r",0, VAL2,", #0xffff") 6258c2ecf20Sopenharmony_ci TEST_R("movt r",14,VAL1,", #0xffff") 6268c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe340f000) " @ movt pc, #0") 6278c2ecf20Sopenharmony_ci#endif 6288c2ecf20Sopenharmony_ci 6298c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("msr cpsr, 0x13") 6308c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("msr cpsr_f, 0xf0000000") 6318c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("msr spsr, 0x13") 6328c2ecf20Sopenharmony_ci 6338c2ecf20Sopenharmony_ci#if __LINUX_ARM_ARCH__ >= 7 6348c2ecf20Sopenharmony_ci TEST_SUPPORTED("yield") 6358c2ecf20Sopenharmony_ci TEST("sev") 6368c2ecf20Sopenharmony_ci TEST("nop") 6378c2ecf20Sopenharmony_ci TEST("wfi") 6388c2ecf20Sopenharmony_ci TEST_SUPPORTED("wfe") 6398c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("dbg #0") 6408c2ecf20Sopenharmony_ci#endif 6418c2ecf20Sopenharmony_ci 6428c2ecf20Sopenharmony_ci TEST_GROUP("Load/store word and unsigned byte") 6438c2ecf20Sopenharmony_ci 6448c2ecf20Sopenharmony_ci#define LOAD_STORE(byte) \ 6458c2ecf20Sopenharmony_ci TEST_RP( "str"byte" r",0, VAL1,", [r",1, 24,", #-2]") \ 6468c2ecf20Sopenharmony_ci TEST_RP( "str"byte" r",14,VAL2,", [r",13,0, ", #2]") \ 6478c2ecf20Sopenharmony_ci TEST_RP( "str"byte" r",1, VAL1,", [r",2, 24,", #4]!") \ 6488c2ecf20Sopenharmony_ci TEST_RP( "str"byte" r",12,VAL2,", [r",11,24,", #-4]!") \ 6498c2ecf20Sopenharmony_ci TEST_RP( "str"byte" r",2, VAL1,", [r",3, 24,"], #48") \ 6508c2ecf20Sopenharmony_ci TEST_RP( "str"byte" r",10,VAL2,", [r",9, 64,"], #-48") \ 6518c2ecf20Sopenharmony_ci TEST_RP( "str"byte" r",3, VAL1,", [r",13,TEST_MEMORY_SIZE,", #-"__stringify(MAX_STACK_SIZE)"]!") \ 6528c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("str"byte" r3, [r13, #-"__stringify(MAX_STACK_SIZE)"-8]!") \ 6538c2ecf20Sopenharmony_ci TEST_RP( "str"byte" r",4, VAL1,", [r",10,TEST_MEMORY_SIZE,", #-"__stringify(MAX_STACK_SIZE)"-8]!") \ 6548c2ecf20Sopenharmony_ci TEST_RPR("str"byte" r",0, VAL1,", [r",1, 48,", -r",2, 24,"]") \ 6558c2ecf20Sopenharmony_ci TEST_RPR("str"byte" r",14,VAL2,", [r",11,0, ", r",12, 48,"]") \ 6568c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("str"byte" r14, [r13, r12]") \ 6578c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("str"byte" r14, [r12, r13]") \ 6588c2ecf20Sopenharmony_ci TEST_RPR("str"byte" r",1, VAL1,", [r",2, 24,", r",3, 48,"]!") \ 6598c2ecf20Sopenharmony_ci TEST_RPR("str"byte" r",12,VAL2,", [r",11,48,", -r",10,24,"]!") \ 6608c2ecf20Sopenharmony_ci TEST_RPR("str"byte" r",2, VAL1,", [r",3, 24,"], r",4, 48,"") \ 6618c2ecf20Sopenharmony_ci TEST_RPR("str"byte" r",10,VAL2,", [r",9, 48,"], -r",11,24,"") \ 6628c2ecf20Sopenharmony_ci TEST_RPR("str"byte" r",0, VAL1,", [r",1, 24,", r",2, 32,", asl #1]")\ 6638c2ecf20Sopenharmony_ci TEST_RPR("str"byte" r",14,VAL2,", [r",11,0, ", r",12, 32,", lsr #2]")\ 6648c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("str"byte" r14, [r13, r12, lsr #2]") \ 6658c2ecf20Sopenharmony_ci TEST_RPR("str"byte" r",1, VAL1,", [r",2, 24,", r",3, 32,", asr #3]!")\ 6668c2ecf20Sopenharmony_ci TEST_RPR("str"byte" r",12,VAL2,", [r",11,24,", r",10, 4,", ror #31]!")\ 6678c2ecf20Sopenharmony_ci TEST_P( "ldr"byte" r0, [r",0, 24,", #-2]") \ 6688c2ecf20Sopenharmony_ci TEST_P( "ldr"byte" r14, [r",13,0, ", #2]") \ 6698c2ecf20Sopenharmony_ci TEST_P( "ldr"byte" r1, [r",2, 24,", #4]!") \ 6708c2ecf20Sopenharmony_ci TEST_P( "ldr"byte" r12, [r",11,24,", #-4]!") \ 6718c2ecf20Sopenharmony_ci TEST_P( "ldr"byte" r2, [r",3, 24,"], #48") \ 6728c2ecf20Sopenharmony_ci TEST_P( "ldr"byte" r10, [r",9, 64,"], #-48") \ 6738c2ecf20Sopenharmony_ci TEST_PR( "ldr"byte" r0, [r",0, 48,", -r",2, 24,"]") \ 6748c2ecf20Sopenharmony_ci TEST_PR( "ldr"byte" r14, [r",13,0, ", r",12, 48,"]") \ 6758c2ecf20Sopenharmony_ci TEST_PR( "ldr"byte" r1, [r",2, 24,", r",3, 48,"]!") \ 6768c2ecf20Sopenharmony_ci TEST_PR( "ldr"byte" r12, [r",11,48,", -r",10,24,"]!") \ 6778c2ecf20Sopenharmony_ci TEST_PR( "ldr"byte" r2, [r",3, 24,"], r",4, 48,"") \ 6788c2ecf20Sopenharmony_ci TEST_PR( "ldr"byte" r10, [r",9, 48,"], -r",11,24,"") \ 6798c2ecf20Sopenharmony_ci TEST_PR( "ldr"byte" r0, [r",0, 24,", r",2, 32,", asl #1]") \ 6808c2ecf20Sopenharmony_ci TEST_PR( "ldr"byte" r14, [r",13,0, ", r",12, 32,", lsr #2]") \ 6818c2ecf20Sopenharmony_ci TEST_PR( "ldr"byte" r1, [r",2, 24,", r",3, 32,", asr #3]!") \ 6828c2ecf20Sopenharmony_ci TEST_PR( "ldr"byte" r12, [r",11,24,", r",10, 4,", ror #31]!") \ 6838c2ecf20Sopenharmony_ci TEST( "ldr"byte" r0, [pc, #0]") \ 6848c2ecf20Sopenharmony_ci TEST_R( "ldr"byte" r12, [pc, r",14,0,"]") 6858c2ecf20Sopenharmony_ci 6868c2ecf20Sopenharmony_ci LOAD_STORE("") 6878c2ecf20Sopenharmony_ci TEST_P( "str pc, [r",0,0,", #15*4]") 6888c2ecf20Sopenharmony_ci TEST_UNSUPPORTED( "str pc, [sp, r2]") 6898c2ecf20Sopenharmony_ci TEST_BF( "ldr pc, [sp, #15*4]") 6908c2ecf20Sopenharmony_ci TEST_BF_R("ldr pc, [sp, r",2,15*4,"]") 6918c2ecf20Sopenharmony_ci 6928c2ecf20Sopenharmony_ci TEST_P( "str sp, [r",0,0,", #13*4]") 6938c2ecf20Sopenharmony_ci TEST_UNSUPPORTED( "str sp, [sp, r2]") 6948c2ecf20Sopenharmony_ci TEST_BF( "ldr sp, [sp, #13*4]") 6958c2ecf20Sopenharmony_ci TEST_BF_R("ldr sp, [sp, r",2,13*4,"]") 6968c2ecf20Sopenharmony_ci 6978c2ecf20Sopenharmony_ci#ifdef CONFIG_THUMB2_KERNEL 6988c2ecf20Sopenharmony_ci TEST_ARM_TO_THUMB_INTERWORK_P("ldr pc, [r",0,0,", #15*4]") 6998c2ecf20Sopenharmony_ci#endif 7008c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe5af6008) " @ str r6, [pc, #8]!") 7018c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe7af6008) " @ str r6, [pc, r8]!") 7028c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe5bf6008) " @ ldr r6, [pc, #8]!") 7038c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe7bf6008) " @ ldr r6, [pc, r8]!") 7048c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe788600f) " @ str r6, [r8, pc]") 7058c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe798600f) " @ ldr r6, [r8, pc]") 7068c2ecf20Sopenharmony_ci 7078c2ecf20Sopenharmony_ci LOAD_STORE("b") 7088c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe5f7f008) " @ ldrb pc, [r7, #8]!") 7098c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe7f7f008) " @ ldrb pc, [r7, r8]!") 7108c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe5ef6008) " @ strb r6, [pc, #8]!") 7118c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe7ef6008) " @ strb r6, [pc, r3]!") 7128c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe5ff6008) " @ ldrb r6, [pc, #8]!") 7138c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe7ff6008) " @ ldrb r6, [pc, r3]!") 7148c2ecf20Sopenharmony_ci 7158c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("ldrt r0, [r1], #4") 7168c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("ldrt r1, [r2], r3") 7178c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("strt r2, [r3], #4") 7188c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("strt r3, [r4], r5") 7198c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("ldrbt r4, [r5], #4") 7208c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("ldrbt r5, [r6], r7") 7218c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("strbt r6, [r7], #4") 7228c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("strbt r7, [r8], r9") 7238c2ecf20Sopenharmony_ci 7248c2ecf20Sopenharmony_ci#if __LINUX_ARM_ARCH__ >= 7 7258c2ecf20Sopenharmony_ci TEST_GROUP("Parallel addition and subtraction, signed") 7268c2ecf20Sopenharmony_ci 7278c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe6000010) "") /* Unallocated space */ 7288c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe60fffff) "") /* Unallocated space */ 7298c2ecf20Sopenharmony_ci 7308c2ecf20Sopenharmony_ci TEST_RR( "sadd16 r0, r",0, HH1,", r",1, HH2,"") 7318c2ecf20Sopenharmony_ci TEST_RR( "sadd16 r14, r",12,HH2,", r",10,HH1,"") 7328c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe61cff1a) " @ sadd16 pc, r12, r10") 7338c2ecf20Sopenharmony_ci TEST_RR( "sasx r0, r",0, HH1,", r",1, HH2,"") 7348c2ecf20Sopenharmony_ci TEST_RR( "sasx r14, r",12,HH2,", r",10,HH1,"") 7358c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe61cff3a) " @ sasx pc, r12, r10") 7368c2ecf20Sopenharmony_ci TEST_RR( "ssax r0, r",0, HH1,", r",1, HH2,"") 7378c2ecf20Sopenharmony_ci TEST_RR( "ssax r14, r",12,HH2,", r",10,HH1,"") 7388c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe61cff5a) " @ ssax pc, r12, r10") 7398c2ecf20Sopenharmony_ci TEST_RR( "ssub16 r0, r",0, HH1,", r",1, HH2,"") 7408c2ecf20Sopenharmony_ci TEST_RR( "ssub16 r14, r",12,HH2,", r",10,HH1,"") 7418c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe61cff7a) " @ ssub16 pc, r12, r10") 7428c2ecf20Sopenharmony_ci TEST_RR( "sadd8 r0, r",0, HH1,", r",1, HH2,"") 7438c2ecf20Sopenharmony_ci TEST_RR( "sadd8 r14, r",12,HH2,", r",10,HH1,"") 7448c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe61cff9a) " @ sadd8 pc, r12, r10") 7458c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe61000b0) "") /* Unallocated space */ 7468c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe61fffbf) "") /* Unallocated space */ 7478c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe61000d0) "") /* Unallocated space */ 7488c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe61fffdf) "") /* Unallocated space */ 7498c2ecf20Sopenharmony_ci TEST_RR( "ssub8 r0, r",0, HH1,", r",1, HH2,"") 7508c2ecf20Sopenharmony_ci TEST_RR( "ssub8 r14, r",12,HH2,", r",10,HH1,"") 7518c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe61cfffa) " @ ssub8 pc, r12, r10") 7528c2ecf20Sopenharmony_ci 7538c2ecf20Sopenharmony_ci TEST_RR( "qadd16 r0, r",0, HH1,", r",1, HH2,"") 7548c2ecf20Sopenharmony_ci TEST_RR( "qadd16 r14, r",12,HH2,", r",10,HH1,"") 7558c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe62cff1a) " @ qadd16 pc, r12, r10") 7568c2ecf20Sopenharmony_ci TEST_RR( "qasx r0, r",0, HH1,", r",1, HH2,"") 7578c2ecf20Sopenharmony_ci TEST_RR( "qasx r14, r",12,HH2,", r",10,HH1,"") 7588c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe62cff3a) " @ qasx pc, r12, r10") 7598c2ecf20Sopenharmony_ci TEST_RR( "qsax r0, r",0, HH1,", r",1, HH2,"") 7608c2ecf20Sopenharmony_ci TEST_RR( "qsax r14, r",12,HH2,", r",10,HH1,"") 7618c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe62cff5a) " @ qsax pc, r12, r10") 7628c2ecf20Sopenharmony_ci TEST_RR( "qsub16 r0, r",0, HH1,", r",1, HH2,"") 7638c2ecf20Sopenharmony_ci TEST_RR( "qsub16 r14, r",12,HH2,", r",10,HH1,"") 7648c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe62cff7a) " @ qsub16 pc, r12, r10") 7658c2ecf20Sopenharmony_ci TEST_RR( "qadd8 r0, r",0, HH1,", r",1, HH2,"") 7668c2ecf20Sopenharmony_ci TEST_RR( "qadd8 r14, r",12,HH2,", r",10,HH1,"") 7678c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe62cff9a) " @ qadd8 pc, r12, r10") 7688c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe62000b0) "") /* Unallocated space */ 7698c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe62fffbf) "") /* Unallocated space */ 7708c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe62000d0) "") /* Unallocated space */ 7718c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe62fffdf) "") /* Unallocated space */ 7728c2ecf20Sopenharmony_ci TEST_RR( "qsub8 r0, r",0, HH1,", r",1, HH2,"") 7738c2ecf20Sopenharmony_ci TEST_RR( "qsub8 r14, r",12,HH2,", r",10,HH1,"") 7748c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe62cfffa) " @ qsub8 pc, r12, r10") 7758c2ecf20Sopenharmony_ci 7768c2ecf20Sopenharmony_ci TEST_RR( "shadd16 r0, r",0, HH1,", r",1, HH2,"") 7778c2ecf20Sopenharmony_ci TEST_RR( "shadd16 r14, r",12,HH2,", r",10,HH1,"") 7788c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe63cff1a) " @ shadd16 pc, r12, r10") 7798c2ecf20Sopenharmony_ci TEST_RR( "shasx r0, r",0, HH1,", r",1, HH2,"") 7808c2ecf20Sopenharmony_ci TEST_RR( "shasx r14, r",12,HH2,", r",10,HH1,"") 7818c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe63cff3a) " @ shasx pc, r12, r10") 7828c2ecf20Sopenharmony_ci TEST_RR( "shsax r0, r",0, HH1,", r",1, HH2,"") 7838c2ecf20Sopenharmony_ci TEST_RR( "shsax r14, r",12,HH2,", r",10,HH1,"") 7848c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe63cff5a) " @ shsax pc, r12, r10") 7858c2ecf20Sopenharmony_ci TEST_RR( "shsub16 r0, r",0, HH1,", r",1, HH2,"") 7868c2ecf20Sopenharmony_ci TEST_RR( "shsub16 r14, r",12,HH2,", r",10,HH1,"") 7878c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe63cff7a) " @ shsub16 pc, r12, r10") 7888c2ecf20Sopenharmony_ci TEST_RR( "shadd8 r0, r",0, HH1,", r",1, HH2,"") 7898c2ecf20Sopenharmony_ci TEST_RR( "shadd8 r14, r",12,HH2,", r",10,HH1,"") 7908c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe63cff9a) " @ shadd8 pc, r12, r10") 7918c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe63000b0) "") /* Unallocated space */ 7928c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe63fffbf) "") /* Unallocated space */ 7938c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe63000d0) "") /* Unallocated space */ 7948c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe63fffdf) "") /* Unallocated space */ 7958c2ecf20Sopenharmony_ci TEST_RR( "shsub8 r0, r",0, HH1,", r",1, HH2,"") 7968c2ecf20Sopenharmony_ci TEST_RR( "shsub8 r14, r",12,HH2,", r",10,HH1,"") 7978c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe63cfffa) " @ shsub8 pc, r12, r10") 7988c2ecf20Sopenharmony_ci 7998c2ecf20Sopenharmony_ci TEST_GROUP("Parallel addition and subtraction, unsigned") 8008c2ecf20Sopenharmony_ci 8018c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe6400010) "") /* Unallocated space */ 8028c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe64fffff) "") /* Unallocated space */ 8038c2ecf20Sopenharmony_ci 8048c2ecf20Sopenharmony_ci TEST_RR( "uadd16 r0, r",0, HH1,", r",1, HH2,"") 8058c2ecf20Sopenharmony_ci TEST_RR( "uadd16 r14, r",12,HH2,", r",10,HH1,"") 8068c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe65cff1a) " @ uadd16 pc, r12, r10") 8078c2ecf20Sopenharmony_ci TEST_RR( "uasx r0, r",0, HH1,", r",1, HH2,"") 8088c2ecf20Sopenharmony_ci TEST_RR( "uasx r14, r",12,HH2,", r",10,HH1,"") 8098c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe65cff3a) " @ uasx pc, r12, r10") 8108c2ecf20Sopenharmony_ci TEST_RR( "usax r0, r",0, HH1,", r",1, HH2,"") 8118c2ecf20Sopenharmony_ci TEST_RR( "usax r14, r",12,HH2,", r",10,HH1,"") 8128c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe65cff5a) " @ usax pc, r12, r10") 8138c2ecf20Sopenharmony_ci TEST_RR( "usub16 r0, r",0, HH1,", r",1, HH2,"") 8148c2ecf20Sopenharmony_ci TEST_RR( "usub16 r14, r",12,HH2,", r",10,HH1,"") 8158c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe65cff7a) " @ usub16 pc, r12, r10") 8168c2ecf20Sopenharmony_ci TEST_RR( "uadd8 r0, r",0, HH1,", r",1, HH2,"") 8178c2ecf20Sopenharmony_ci TEST_RR( "uadd8 r14, r",12,HH2,", r",10,HH1,"") 8188c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe65cff9a) " @ uadd8 pc, r12, r10") 8198c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe65000b0) "") /* Unallocated space */ 8208c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe65fffbf) "") /* Unallocated space */ 8218c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe65000d0) "") /* Unallocated space */ 8228c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe65fffdf) "") /* Unallocated space */ 8238c2ecf20Sopenharmony_ci TEST_RR( "usub8 r0, r",0, HH1,", r",1, HH2,"") 8248c2ecf20Sopenharmony_ci TEST_RR( "usub8 r14, r",12,HH2,", r",10,HH1,"") 8258c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe65cfffa) " @ usub8 pc, r12, r10") 8268c2ecf20Sopenharmony_ci 8278c2ecf20Sopenharmony_ci TEST_RR( "uqadd16 r0, r",0, HH1,", r",1, HH2,"") 8288c2ecf20Sopenharmony_ci TEST_RR( "uqadd16 r14, r",12,HH2,", r",10,HH1,"") 8298c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe66cff1a) " @ uqadd16 pc, r12, r10") 8308c2ecf20Sopenharmony_ci TEST_RR( "uqasx r0, r",0, HH1,", r",1, HH2,"") 8318c2ecf20Sopenharmony_ci TEST_RR( "uqasx r14, r",12,HH2,", r",10,HH1,"") 8328c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe66cff3a) " @ uqasx pc, r12, r10") 8338c2ecf20Sopenharmony_ci TEST_RR( "uqsax r0, r",0, HH1,", r",1, HH2,"") 8348c2ecf20Sopenharmony_ci TEST_RR( "uqsax r14, r",12,HH2,", r",10,HH1,"") 8358c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe66cff5a) " @ uqsax pc, r12, r10") 8368c2ecf20Sopenharmony_ci TEST_RR( "uqsub16 r0, r",0, HH1,", r",1, HH2,"") 8378c2ecf20Sopenharmony_ci TEST_RR( "uqsub16 r14, r",12,HH2,", r",10,HH1,"") 8388c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe66cff7a) " @ uqsub16 pc, r12, r10") 8398c2ecf20Sopenharmony_ci TEST_RR( "uqadd8 r0, r",0, HH1,", r",1, HH2,"") 8408c2ecf20Sopenharmony_ci TEST_RR( "uqadd8 r14, r",12,HH2,", r",10,HH1,"") 8418c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe66cff9a) " @ uqadd8 pc, r12, r10") 8428c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe66000b0) "") /* Unallocated space */ 8438c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe66fffbf) "") /* Unallocated space */ 8448c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe66000d0) "") /* Unallocated space */ 8458c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe66fffdf) "") /* Unallocated space */ 8468c2ecf20Sopenharmony_ci TEST_RR( "uqsub8 r0, r",0, HH1,", r",1, HH2,"") 8478c2ecf20Sopenharmony_ci TEST_RR( "uqsub8 r14, r",12,HH2,", r",10,HH1,"") 8488c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe66cfffa) " @ uqsub8 pc, r12, r10") 8498c2ecf20Sopenharmony_ci 8508c2ecf20Sopenharmony_ci TEST_RR( "uhadd16 r0, r",0, HH1,", r",1, HH2,"") 8518c2ecf20Sopenharmony_ci TEST_RR( "uhadd16 r14, r",12,HH2,", r",10,HH1,"") 8528c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe67cff1a) " @ uhadd16 pc, r12, r10") 8538c2ecf20Sopenharmony_ci TEST_RR( "uhasx r0, r",0, HH1,", r",1, HH2,"") 8548c2ecf20Sopenharmony_ci TEST_RR( "uhasx r14, r",12,HH2,", r",10,HH1,"") 8558c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe67cff3a) " @ uhasx pc, r12, r10") 8568c2ecf20Sopenharmony_ci TEST_RR( "uhsax r0, r",0, HH1,", r",1, HH2,"") 8578c2ecf20Sopenharmony_ci TEST_RR( "uhsax r14, r",12,HH2,", r",10,HH1,"") 8588c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe67cff5a) " @ uhsax pc, r12, r10") 8598c2ecf20Sopenharmony_ci TEST_RR( "uhsub16 r0, r",0, HH1,", r",1, HH2,"") 8608c2ecf20Sopenharmony_ci TEST_RR( "uhsub16 r14, r",12,HH2,", r",10,HH1,"") 8618c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe67cff7a) " @ uhsub16 pc, r12, r10") 8628c2ecf20Sopenharmony_ci TEST_RR( "uhadd8 r0, r",0, HH1,", r",1, HH2,"") 8638c2ecf20Sopenharmony_ci TEST_RR( "uhadd8 r14, r",12,HH2,", r",10,HH1,"") 8648c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe67cff9a) " @ uhadd8 pc, r12, r10") 8658c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe67000b0) "") /* Unallocated space */ 8668c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe67fffbf) "") /* Unallocated space */ 8678c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe67000d0) "") /* Unallocated space */ 8688c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe67fffdf) "") /* Unallocated space */ 8698c2ecf20Sopenharmony_ci TEST_RR( "uhsub8 r0, r",0, HH1,", r",1, HH2,"") 8708c2ecf20Sopenharmony_ci TEST_RR( "uhsub8 r14, r",12,HH2,", r",10,HH1,"") 8718c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe67cfffa) " @ uhsub8 pc, r12, r10") 8728c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe67feffa) " @ uhsub8 r14, pc, r10") 8738c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe67cefff) " @ uhsub8 r14, r12, pc") 8748c2ecf20Sopenharmony_ci#endif /* __LINUX_ARM_ARCH__ >= 7 */ 8758c2ecf20Sopenharmony_ci 8768c2ecf20Sopenharmony_ci#if __LINUX_ARM_ARCH__ >= 6 8778c2ecf20Sopenharmony_ci TEST_GROUP("Packing, unpacking, saturation, and reversal") 8788c2ecf20Sopenharmony_ci 8798c2ecf20Sopenharmony_ci TEST_RR( "pkhbt r0, r",0, HH1,", r",1, HH2,"") 8808c2ecf20Sopenharmony_ci TEST_RR( "pkhbt r14,r",12, HH1,", r",10,HH2,", lsl #2") 8818c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe68cf11a) " @ pkhbt pc, r12, r10, lsl #2") 8828c2ecf20Sopenharmony_ci TEST_RR( "pkhtb r0, r",0, HH1,", r",1, HH2,"") 8838c2ecf20Sopenharmony_ci TEST_RR( "pkhtb r14,r",12, HH1,", r",10,HH2,", asr #2") 8848c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe68cf15a) " @ pkhtb pc, r12, r10, asr #2") 8858c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe68fe15a) " @ pkhtb r14, pc, r10, asr #2") 8868c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe68ce15f) " @ pkhtb r14, r12, pc, asr #2") 8878c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe6900010) "") /* Unallocated space */ 8888c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe69fffdf) "") /* Unallocated space */ 8898c2ecf20Sopenharmony_ci 8908c2ecf20Sopenharmony_ci TEST_R( "ssat r0, #24, r",0, VAL1,"") 8918c2ecf20Sopenharmony_ci TEST_R( "ssat r14, #24, r",12, VAL2,"") 8928c2ecf20Sopenharmony_ci TEST_R( "ssat r0, #24, r",0, VAL1,", lsl #8") 8938c2ecf20Sopenharmony_ci TEST_R( "ssat r14, #24, r",12, VAL2,", asr #8") 8948c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe6b7f01c) " @ ssat pc, #24, r12") 8958c2ecf20Sopenharmony_ci 8968c2ecf20Sopenharmony_ci TEST_R( "usat r0, #24, r",0, VAL1,"") 8978c2ecf20Sopenharmony_ci TEST_R( "usat r14, #24, r",12, VAL2,"") 8988c2ecf20Sopenharmony_ci TEST_R( "usat r0, #24, r",0, VAL1,", lsl #8") 8998c2ecf20Sopenharmony_ci TEST_R( "usat r14, #24, r",12, VAL2,", asr #8") 9008c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe6f7f01c) " @ usat pc, #24, r12") 9018c2ecf20Sopenharmony_ci 9028c2ecf20Sopenharmony_ci TEST_RR( "sxtab16 r0, r",0, HH1,", r",1, HH2,"") 9038c2ecf20Sopenharmony_ci TEST_RR( "sxtab16 r14,r",12, HH2,", r",10,HH1,", ror #8") 9048c2ecf20Sopenharmony_ci TEST_R( "sxtb16 r8, r",7, HH1,"") 9058c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe68cf47a) " @ sxtab16 pc,r12, r10, ror #8") 9068c2ecf20Sopenharmony_ci 9078c2ecf20Sopenharmony_ci TEST_RR( "sel r0, r",0, VAL1,", r",1, VAL2,"") 9088c2ecf20Sopenharmony_ci TEST_RR( "sel r14, r",12,VAL1,", r",10, VAL2,"") 9098c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe68cffba) " @ sel pc, r12, r10") 9108c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe68fefba) " @ sel r14, pc, r10") 9118c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe68cefbf) " @ sel r14, r12, pc") 9128c2ecf20Sopenharmony_ci 9138c2ecf20Sopenharmony_ci TEST_R( "ssat16 r0, #12, r",0, HH1,"") 9148c2ecf20Sopenharmony_ci TEST_R( "ssat16 r14, #12, r",12, HH2,"") 9158c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe6abff3c) " @ ssat16 pc, #12, r12") 9168c2ecf20Sopenharmony_ci 9178c2ecf20Sopenharmony_ci TEST_RR( "sxtab r0, r",0, HH1,", r",1, HH2,"") 9188c2ecf20Sopenharmony_ci TEST_RR( "sxtab r14,r",12, HH2,", r",10,HH1,", ror #8") 9198c2ecf20Sopenharmony_ci TEST_R( "sxtb r8, r",7, HH1,"") 9208c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe6acf47a) " @ sxtab pc,r12, r10, ror #8") 9218c2ecf20Sopenharmony_ci 9228c2ecf20Sopenharmony_ci TEST_R( "rev r0, r",0, VAL1,"") 9238c2ecf20Sopenharmony_ci TEST_R( "rev r14, r",12, VAL2,"") 9248c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe6bfff3c) " @ rev pc, r12") 9258c2ecf20Sopenharmony_ci 9268c2ecf20Sopenharmony_ci TEST_RR( "sxtah r0, r",0, HH1,", r",1, HH2,"") 9278c2ecf20Sopenharmony_ci TEST_RR( "sxtah r14,r",12, HH2,", r",10,HH1,", ror #8") 9288c2ecf20Sopenharmony_ci TEST_R( "sxth r8, r",7, HH1,"") 9298c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe6bcf47a) " @ sxtah pc,r12, r10, ror #8") 9308c2ecf20Sopenharmony_ci 9318c2ecf20Sopenharmony_ci TEST_R( "rev16 r0, r",0, VAL1,"") 9328c2ecf20Sopenharmony_ci TEST_R( "rev16 r14, r",12, VAL2,"") 9338c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe6bfffbc) " @ rev16 pc, r12") 9348c2ecf20Sopenharmony_ci 9358c2ecf20Sopenharmony_ci TEST_RR( "uxtab16 r0, r",0, HH1,", r",1, HH2,"") 9368c2ecf20Sopenharmony_ci TEST_RR( "uxtab16 r14,r",12, HH2,", r",10,HH1,", ror #8") 9378c2ecf20Sopenharmony_ci TEST_R( "uxtb16 r8, r",7, HH1,"") 9388c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe6ccf47a) " @ uxtab16 pc,r12, r10, ror #8") 9398c2ecf20Sopenharmony_ci 9408c2ecf20Sopenharmony_ci TEST_R( "usat16 r0, #12, r",0, HH1,"") 9418c2ecf20Sopenharmony_ci TEST_R( "usat16 r14, #12, r",12, HH2,"") 9428c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe6ecff3c) " @ usat16 pc, #12, r12") 9438c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe6ecef3f) " @ usat16 r14, #12, pc") 9448c2ecf20Sopenharmony_ci 9458c2ecf20Sopenharmony_ci TEST_RR( "uxtab r0, r",0, HH1,", r",1, HH2,"") 9468c2ecf20Sopenharmony_ci TEST_RR( "uxtab r14,r",12, HH2,", r",10,HH1,", ror #8") 9478c2ecf20Sopenharmony_ci TEST_R( "uxtb r8, r",7, HH1,"") 9488c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe6ecf47a) " @ uxtab pc,r12, r10, ror #8") 9498c2ecf20Sopenharmony_ci 9508c2ecf20Sopenharmony_ci#if __LINUX_ARM_ARCH__ >= 7 9518c2ecf20Sopenharmony_ci TEST_R( "rbit r0, r",0, VAL1,"") 9528c2ecf20Sopenharmony_ci TEST_R( "rbit r14, r",12, VAL2,"") 9538c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe6ffff3c) " @ rbit pc, r12") 9548c2ecf20Sopenharmony_ci#endif 9558c2ecf20Sopenharmony_ci 9568c2ecf20Sopenharmony_ci TEST_RR( "uxtah r0, r",0, HH1,", r",1, HH2,"") 9578c2ecf20Sopenharmony_ci TEST_RR( "uxtah r14,r",12, HH2,", r",10,HH1,", ror #8") 9588c2ecf20Sopenharmony_ci TEST_R( "uxth r8, r",7, HH1,"") 9598c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe6fff077) " @ uxth pc, r7") 9608c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe6ff807f) " @ uxth r8, pc") 9618c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe6fcf47a) " @ uxtah pc, r12, r10, ror #8") 9628c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe6fce47f) " @ uxtah r14, r12, pc, ror #8") 9638c2ecf20Sopenharmony_ci 9648c2ecf20Sopenharmony_ci TEST_R( "revsh r0, r",0, VAL1,"") 9658c2ecf20Sopenharmony_ci TEST_R( "revsh r14, r",12, VAL2,"") 9668c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe6ffff3c) " @ revsh pc, r12") 9678c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe6ffef3f) " @ revsh r14, pc") 9688c2ecf20Sopenharmony_ci 9698c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe6900070) "") /* Unallocated space */ 9708c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe69fff7f) "") /* Unallocated space */ 9718c2ecf20Sopenharmony_ci 9728c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe6d00070) "") /* Unallocated space */ 9738c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe6dfff7f) "") /* Unallocated space */ 9748c2ecf20Sopenharmony_ci#endif /* __LINUX_ARM_ARCH__ >= 6 */ 9758c2ecf20Sopenharmony_ci 9768c2ecf20Sopenharmony_ci#if __LINUX_ARM_ARCH__ >= 6 9778c2ecf20Sopenharmony_ci TEST_GROUP("Signed multiplies") 9788c2ecf20Sopenharmony_ci 9798c2ecf20Sopenharmony_ci TEST_RRR( "smlad r0, r",0, HH1,", r",1, HH2,", r",2, VAL1,"") 9808c2ecf20Sopenharmony_ci TEST_RRR( "smlad r14, r",12,HH2,", r",10,HH1,", r",8, VAL2,"") 9818c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe70f8a1c) " @ smlad pc, r12, r10, r8") 9828c2ecf20Sopenharmony_ci TEST_RRR( "smladx r0, r",0, HH1,", r",1, HH2,", r",2, VAL1,"") 9838c2ecf20Sopenharmony_ci TEST_RRR( "smladx r14, r",12,HH2,", r",10,HH1,", r",8, VAL2,"") 9848c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe70f8a3c) " @ smladx pc, r12, r10, r8") 9858c2ecf20Sopenharmony_ci 9868c2ecf20Sopenharmony_ci TEST_RR( "smuad r0, r",0, HH1,", r",1, HH2,"") 9878c2ecf20Sopenharmony_ci TEST_RR( "smuad r14, r",12,HH2,", r",10,HH1,"") 9888c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe70ffa1c) " @ smuad pc, r12, r10") 9898c2ecf20Sopenharmony_ci TEST_RR( "smuadx r0, r",0, HH1,", r",1, HH2,"") 9908c2ecf20Sopenharmony_ci TEST_RR( "smuadx r14, r",12,HH2,", r",10,HH1,"") 9918c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe70ffa3c) " @ smuadx pc, r12, r10") 9928c2ecf20Sopenharmony_ci 9938c2ecf20Sopenharmony_ci TEST_RRR( "smlsd r0, r",0, HH1,", r",1, HH2,", r",2, VAL1,"") 9948c2ecf20Sopenharmony_ci TEST_RRR( "smlsd r14, r",12,HH2,", r",10,HH1,", r",8, VAL2,"") 9958c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe70f8a5c) " @ smlsd pc, r12, r10, r8") 9968c2ecf20Sopenharmony_ci TEST_RRR( "smlsdx r0, r",0, HH1,", r",1, HH2,", r",2, VAL1,"") 9978c2ecf20Sopenharmony_ci TEST_RRR( "smlsdx r14, r",12,HH2,", r",10,HH1,", r",8, VAL2,"") 9988c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe70f8a7c) " @ smlsdx pc, r12, r10, r8") 9998c2ecf20Sopenharmony_ci 10008c2ecf20Sopenharmony_ci TEST_RR( "smusd r0, r",0, HH1,", r",1, HH2,"") 10018c2ecf20Sopenharmony_ci TEST_RR( "smusd r14, r",12,HH2,", r",10,HH1,"") 10028c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe70ffa5c) " @ smusd pc, r12, r10") 10038c2ecf20Sopenharmony_ci TEST_RR( "smusdx r0, r",0, HH1,", r",1, HH2,"") 10048c2ecf20Sopenharmony_ci TEST_RR( "smusdx r14, r",12,HH2,", r",10,HH1,"") 10058c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe70ffa7c) " @ smusdx pc, r12, r10") 10068c2ecf20Sopenharmony_ci 10078c2ecf20Sopenharmony_ci TEST_RRRR( "smlald r",0, VAL1,", r",1, VAL2, ", r",0, HH1,", r",1, HH2) 10088c2ecf20Sopenharmony_ci TEST_RRRR( "smlald r",11,VAL2,", r",10,VAL1, ", r",9, HH2,", r",8, HH1) 10098c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe74af819) " @ smlald pc, r10, r9, r8") 10108c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe74fb819) " @ smlald r11, pc, r9, r8") 10118c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe74ab81f) " @ smlald r11, r10, pc, r8") 10128c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe74abf19) " @ smlald r11, r10, r9, pc") 10138c2ecf20Sopenharmony_ci 10148c2ecf20Sopenharmony_ci TEST_RRRR( "smlaldx r",0, VAL1,", r",1, VAL2, ", r",0, HH1,", r",1, HH2) 10158c2ecf20Sopenharmony_ci TEST_RRRR( "smlaldx r",11,VAL2,", r",10,VAL1, ", r",9, HH2,", r",8, HH1) 10168c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe74af839) " @ smlaldx pc, r10, r9, r8") 10178c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe74fb839) " @ smlaldx r11, pc, r9, r8") 10188c2ecf20Sopenharmony_ci 10198c2ecf20Sopenharmony_ci TEST_RRR( "smmla r0, r",0, VAL1,", r",1, VAL2,", r",2, VAL1,"") 10208c2ecf20Sopenharmony_ci TEST_RRR( "smmla r14, r",12,VAL2,", r",10,VAL1,", r",8, VAL2,"") 10218c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe75f8a1c) " @ smmla pc, r12, r10, r8") 10228c2ecf20Sopenharmony_ci TEST_RRR( "smmlar r0, r",0, VAL1,", r",1, VAL2,", r",2, VAL1,"") 10238c2ecf20Sopenharmony_ci TEST_RRR( "smmlar r14, r",12,VAL2,", r",10,VAL1,", r",8, VAL2,"") 10248c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe75f8a3c) " @ smmlar pc, r12, r10, r8") 10258c2ecf20Sopenharmony_ci 10268c2ecf20Sopenharmony_ci TEST_RR( "smmul r0, r",0, VAL1,", r",1, VAL2,"") 10278c2ecf20Sopenharmony_ci TEST_RR( "smmul r14, r",12,VAL2,", r",10,VAL1,"") 10288c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe75ffa1c) " @ smmul pc, r12, r10") 10298c2ecf20Sopenharmony_ci TEST_RR( "smmulr r0, r",0, VAL1,", r",1, VAL2,"") 10308c2ecf20Sopenharmony_ci TEST_RR( "smmulr r14, r",12,VAL2,", r",10,VAL1,"") 10318c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe75ffa3c) " @ smmulr pc, r12, r10") 10328c2ecf20Sopenharmony_ci 10338c2ecf20Sopenharmony_ci TEST_RRR( "smmls r0, r",0, VAL1,", r",1, VAL2,", r",2, VAL1,"") 10348c2ecf20Sopenharmony_ci TEST_RRR( "smmls r14, r",12,VAL2,", r",10,VAL1,", r",8, VAL2,"") 10358c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe75f8adc) " @ smmls pc, r12, r10, r8") 10368c2ecf20Sopenharmony_ci TEST_RRR( "smmlsr r0, r",0, VAL1,", r",1, VAL2,", r",2, VAL1,"") 10378c2ecf20Sopenharmony_ci TEST_RRR( "smmlsr r14, r",12,VAL2,", r",10,VAL1,", r",8, VAL2,"") 10388c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe75f8afc) " @ smmlsr pc, r12, r10, r8") 10398c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe75e8aff) " @ smmlsr r14, pc, r10, r8") 10408c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe75e8ffc) " @ smmlsr r14, r12, pc, r8") 10418c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe75efafc) " @ smmlsr r14, r12, r10, pc") 10428c2ecf20Sopenharmony_ci 10438c2ecf20Sopenharmony_ci TEST_RR( "usad8 r0, r",0, VAL1,", r",1, VAL2,"") 10448c2ecf20Sopenharmony_ci TEST_RR( "usad8 r14, r",12,VAL2,", r",10,VAL1,"") 10458c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe75ffa1c) " @ usad8 pc, r12, r10") 10468c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe75efa1f) " @ usad8 r14, pc, r10") 10478c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe75eff1c) " @ usad8 r14, r12, pc") 10488c2ecf20Sopenharmony_ci 10498c2ecf20Sopenharmony_ci TEST_RRR( "usada8 r0, r",0, VAL1,", r",1, VAL2,", r",2, VAL3,"") 10508c2ecf20Sopenharmony_ci TEST_RRR( "usada8 r14, r",12,VAL2,", r",10,VAL1,", r",8, VAL3,"") 10518c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe78f8a1c) " @ usada8 pc, r12, r10, r8") 10528c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe78e8a1f) " @ usada8 r14, pc, r10, r8") 10538c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe78e8f1c) " @ usada8 r14, r12, pc, r8") 10548c2ecf20Sopenharmony_ci#endif /* __LINUX_ARM_ARCH__ >= 6 */ 10558c2ecf20Sopenharmony_ci 10568c2ecf20Sopenharmony_ci#if __LINUX_ARM_ARCH__ >= 7 10578c2ecf20Sopenharmony_ci TEST_GROUP("Bit Field") 10588c2ecf20Sopenharmony_ci 10598c2ecf20Sopenharmony_ci TEST_R( "sbfx r0, r",0 , VAL1,", #0, #31") 10608c2ecf20Sopenharmony_ci TEST_R( "sbfxeq r14, r",12, VAL2,", #8, #16") 10618c2ecf20Sopenharmony_ci TEST_R( "sbfx r4, r",10, VAL1,", #16, #15") 10628c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe7aff45c) " @ sbfx pc, r12, #8, #16") 10638c2ecf20Sopenharmony_ci 10648c2ecf20Sopenharmony_ci TEST_R( "ubfx r0, r",0 , VAL1,", #0, #31") 10658c2ecf20Sopenharmony_ci TEST_R( "ubfxcs r14, r",12, VAL2,", #8, #16") 10668c2ecf20Sopenharmony_ci TEST_R( "ubfx r4, r",10, VAL1,", #16, #15") 10678c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe7eff45c) " @ ubfx pc, r12, #8, #16") 10688c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe7efc45f) " @ ubfx r12, pc, #8, #16") 10698c2ecf20Sopenharmony_ci 10708c2ecf20Sopenharmony_ci TEST_R( "bfc r",0, VAL1,", #4, #20") 10718c2ecf20Sopenharmony_ci TEST_R( "bfcvs r",14,VAL2,", #4, #20") 10728c2ecf20Sopenharmony_ci TEST_R( "bfc r",7, VAL1,", #0, #31") 10738c2ecf20Sopenharmony_ci TEST_R( "bfc r",8, VAL2,", #0, #31") 10748c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe7def01f) " @ bfc pc, #0, #31"); 10758c2ecf20Sopenharmony_ci 10768c2ecf20Sopenharmony_ci TEST_RR( "bfi r",0, VAL1,", r",0 , VAL2,", #0, #31") 10778c2ecf20Sopenharmony_ci TEST_RR( "bfipl r",12,VAL1,", r",14 , VAL2,", #4, #20") 10788c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xe7d7f21e) " @ bfi pc, r14, #4, #20") 10798c2ecf20Sopenharmony_ci 10808c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0x07f000f0) "") /* Permanently UNDEFINED */ 10818c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0x07ffffff) "") /* Permanently UNDEFINED */ 10828c2ecf20Sopenharmony_ci#endif /* __LINUX_ARM_ARCH__ >= 6 */ 10838c2ecf20Sopenharmony_ci 10848c2ecf20Sopenharmony_ci TEST_GROUP("Branch, branch with link, and block data transfer") 10858c2ecf20Sopenharmony_ci 10868c2ecf20Sopenharmony_ci TEST_P( "stmda r",0, 16*4,", {r0}") 10878c2ecf20Sopenharmony_ci TEST_P( "stmeqda r",4, 16*4,", {r0-r15}") 10888c2ecf20Sopenharmony_ci TEST_P( "stmneda r",8, 16*4,"!, {r8-r15}") 10898c2ecf20Sopenharmony_ci TEST_P( "stmda r",12,16*4,"!, {r1,r3,r5,r7,r8-r11,r14}") 10908c2ecf20Sopenharmony_ci TEST_P( "stmda r",13,0, "!, {pc}") 10918c2ecf20Sopenharmony_ci 10928c2ecf20Sopenharmony_ci TEST_P( "ldmda r",0, 16*4,", {r0}") 10938c2ecf20Sopenharmony_ci TEST_BF_P("ldmcsda r",4, 15*4,", {r0-r15}") 10948c2ecf20Sopenharmony_ci TEST_BF_P("ldmccda r",7, 15*4,"!, {r8-r15}") 10958c2ecf20Sopenharmony_ci TEST_P( "ldmda r",12,16*4,"!, {r1,r3,r5,r7,r8-r11,r14}") 10968c2ecf20Sopenharmony_ci TEST_BF_P("ldmda r",14,15*4,"!, {pc}") 10978c2ecf20Sopenharmony_ci 10988c2ecf20Sopenharmony_ci TEST_P( "stmia r",0, 16*4,", {r0}") 10998c2ecf20Sopenharmony_ci TEST_P( "stmmiia r",4, 16*4,", {r0-r15}") 11008c2ecf20Sopenharmony_ci TEST_P( "stmplia r",8, 16*4,"!, {r8-r15}") 11018c2ecf20Sopenharmony_ci TEST_P( "stmia r",12,16*4,"!, {r1,r3,r5,r7,r8-r11,r14}") 11028c2ecf20Sopenharmony_ci TEST_P( "stmia r",14,0, "!, {pc}") 11038c2ecf20Sopenharmony_ci 11048c2ecf20Sopenharmony_ci TEST_P( "ldmia r",0, 16*4,", {r0}") 11058c2ecf20Sopenharmony_ci TEST_BF_P("ldmvsia r",4, 0, ", {r0-r15}") 11068c2ecf20Sopenharmony_ci TEST_BF_P("ldmvcia r",7, 8*4, "!, {r8-r15}") 11078c2ecf20Sopenharmony_ci TEST_P( "ldmia r",12,16*4,"!, {r1,r3,r5,r7,r8-r11,r14}") 11088c2ecf20Sopenharmony_ci TEST_BF_P("ldmia r",14,15*4,"!, {pc}") 11098c2ecf20Sopenharmony_ci 11108c2ecf20Sopenharmony_ci TEST_P( "stmdb r",0, 16*4,", {r0}") 11118c2ecf20Sopenharmony_ci TEST_P( "stmhidb r",4, 16*4,", {r0-r15}") 11128c2ecf20Sopenharmony_ci TEST_P( "stmlsdb r",8, 16*4,"!, {r8-r15}") 11138c2ecf20Sopenharmony_ci TEST_P( "stmdb r",12,16*4,"!, {r1,r3,r5,r7,r8-r11,r14}") 11148c2ecf20Sopenharmony_ci TEST_P( "stmdb r",13,4, "!, {pc}") 11158c2ecf20Sopenharmony_ci 11168c2ecf20Sopenharmony_ci TEST_P( "ldmdb r",0, 16*4,", {r0}") 11178c2ecf20Sopenharmony_ci TEST_BF_P("ldmgedb r",4, 16*4,", {r0-r15}") 11188c2ecf20Sopenharmony_ci TEST_BF_P("ldmltdb r",7, 16*4,"!, {r8-r15}") 11198c2ecf20Sopenharmony_ci TEST_P( "ldmdb r",12,16*4,"!, {r1,r3,r5,r7,r8-r11,r14}") 11208c2ecf20Sopenharmony_ci TEST_BF_P("ldmdb r",14,16*4,"!, {pc}") 11218c2ecf20Sopenharmony_ci 11228c2ecf20Sopenharmony_ci TEST_P( "stmib r",0, 16*4,", {r0}") 11238c2ecf20Sopenharmony_ci TEST_P( "stmgtib r",4, 16*4,", {r0-r15}") 11248c2ecf20Sopenharmony_ci TEST_P( "stmleib r",8, 16*4,"!, {r8-r15}") 11258c2ecf20Sopenharmony_ci TEST_P( "stmib r",12,16*4,"!, {r1,r3,r5,r7,r8-r11,r14}") 11268c2ecf20Sopenharmony_ci TEST_P( "stmib r",13,-4, "!, {pc}") 11278c2ecf20Sopenharmony_ci 11288c2ecf20Sopenharmony_ci TEST_P( "ldmib r",0, 16*4,", {r0}") 11298c2ecf20Sopenharmony_ci TEST_BF_P("ldmeqib r",4, -4,", {r0-r15}") 11308c2ecf20Sopenharmony_ci TEST_BF_P("ldmneib r",7, 7*4,"!, {r8-r15}") 11318c2ecf20Sopenharmony_ci TEST_P( "ldmib r",12,16*4,"!, {r1,r3,r5,r7,r8-r11,r14}") 11328c2ecf20Sopenharmony_ci TEST_BF_P("ldmib r",14,14*4,"!, {pc}") 11338c2ecf20Sopenharmony_ci 11348c2ecf20Sopenharmony_ci TEST_P( "stmdb r",13,16*4,"!, {r3-r12,lr}") 11358c2ecf20Sopenharmony_ci TEST_P( "stmeqdb r",13,16*4,"!, {r3-r12}") 11368c2ecf20Sopenharmony_ci TEST_P( "stmnedb r",2, 16*4,", {r3-r12,lr}") 11378c2ecf20Sopenharmony_ci TEST_P( "stmdb r",13,16*4,"!, {r2-r12,lr}") 11388c2ecf20Sopenharmony_ci TEST_P( "stmdb r",0, 16*4,", {r0-r12}") 11398c2ecf20Sopenharmony_ci TEST_P( "stmdb r",0, 16*4,", {r0-r12,lr}") 11408c2ecf20Sopenharmony_ci 11418c2ecf20Sopenharmony_ci TEST_BF_P("ldmia r",13,5*4, "!, {r3-r12,pc}") 11428c2ecf20Sopenharmony_ci TEST_P( "ldmccia r",13,5*4, "!, {r3-r12}") 11438c2ecf20Sopenharmony_ci TEST_BF_P("ldmcsia r",2, 5*4, "!, {r3-r12,pc}") 11448c2ecf20Sopenharmony_ci TEST_BF_P("ldmia r",13,4*4, "!, {r2-r12,pc}") 11458c2ecf20Sopenharmony_ci TEST_P( "ldmia r",0, 16*4,", {r0-r12}") 11468c2ecf20Sopenharmony_ci TEST_P( "ldmia r",0, 16*4,", {r0-r12,lr}") 11478c2ecf20Sopenharmony_ci 11488c2ecf20Sopenharmony_ci#ifdef CONFIG_THUMB2_KERNEL 11498c2ecf20Sopenharmony_ci TEST_ARM_TO_THUMB_INTERWORK_P("ldmplia r",0,15*4,", {pc}") 11508c2ecf20Sopenharmony_ci TEST_ARM_TO_THUMB_INTERWORK_P("ldmmiia r",13,0,", {r0-r15}") 11518c2ecf20Sopenharmony_ci#endif 11528c2ecf20Sopenharmony_ci TEST_BF("b 2f") 11538c2ecf20Sopenharmony_ci TEST_BF("bl 2f") 11548c2ecf20Sopenharmony_ci TEST_BB("b 2b") 11558c2ecf20Sopenharmony_ci TEST_BB("bl 2b") 11568c2ecf20Sopenharmony_ci 11578c2ecf20Sopenharmony_ci TEST_BF("beq 2f") 11588c2ecf20Sopenharmony_ci TEST_BF("bleq 2f") 11598c2ecf20Sopenharmony_ci TEST_BB("bne 2b") 11608c2ecf20Sopenharmony_ci TEST_BB("blne 2b") 11618c2ecf20Sopenharmony_ci 11628c2ecf20Sopenharmony_ci TEST_BF("bgt 2f") 11638c2ecf20Sopenharmony_ci TEST_BF("blgt 2f") 11648c2ecf20Sopenharmony_ci TEST_BB("blt 2b") 11658c2ecf20Sopenharmony_ci TEST_BB("bllt 2b") 11668c2ecf20Sopenharmony_ci 11678c2ecf20Sopenharmony_ci TEST_GROUP("Supervisor Call, and coprocessor instructions") 11688c2ecf20Sopenharmony_ci 11698c2ecf20Sopenharmony_ci /* 11708c2ecf20Sopenharmony_ci * We can't really test these by executing them, so all 11718c2ecf20Sopenharmony_ci * we can do is check that probes are, or are not allowed. 11728c2ecf20Sopenharmony_ci * At the moment none are allowed... 11738c2ecf20Sopenharmony_ci */ 11748c2ecf20Sopenharmony_ci#define TEST_COPROCESSOR(code) TEST_UNSUPPORTED(code) 11758c2ecf20Sopenharmony_ci 11768c2ecf20Sopenharmony_ci#define COPROCESSOR_INSTRUCTIONS_ST_LD(two,cc) \ 11778c2ecf20Sopenharmony_ci TEST_COPROCESSOR("stc"two" 0, cr0, [r13, #4]") \ 11788c2ecf20Sopenharmony_ci TEST_COPROCESSOR("stc"two" 0, cr0, [r13, #-4]") \ 11798c2ecf20Sopenharmony_ci TEST_COPROCESSOR("stc"two" 0, cr0, [r13, #4]!") \ 11808c2ecf20Sopenharmony_ci TEST_COPROCESSOR("stc"two" 0, cr0, [r13, #-4]!") \ 11818c2ecf20Sopenharmony_ci TEST_COPROCESSOR("stc"two" 0, cr0, [r13], #4") \ 11828c2ecf20Sopenharmony_ci TEST_COPROCESSOR("stc"two" 0, cr0, [r13], #-4") \ 11838c2ecf20Sopenharmony_ci TEST_COPROCESSOR("stc"two" 0, cr0, [r13], {1}") \ 11848c2ecf20Sopenharmony_ci TEST_COPROCESSOR("stc"two"l 0, cr0, [r13, #4]") \ 11858c2ecf20Sopenharmony_ci TEST_COPROCESSOR("stc"two"l 0, cr0, [r13, #-4]") \ 11868c2ecf20Sopenharmony_ci TEST_COPROCESSOR("stc"two"l 0, cr0, [r13, #4]!") \ 11878c2ecf20Sopenharmony_ci TEST_COPROCESSOR("stc"two"l 0, cr0, [r13, #-4]!") \ 11888c2ecf20Sopenharmony_ci TEST_COPROCESSOR("stc"two"l 0, cr0, [r13], #4") \ 11898c2ecf20Sopenharmony_ci TEST_COPROCESSOR("stc"two"l 0, cr0, [r13], #-4") \ 11908c2ecf20Sopenharmony_ci TEST_COPROCESSOR("stc"two"l 0, cr0, [r13], {1}") \ 11918c2ecf20Sopenharmony_ci TEST_COPROCESSOR("ldc"two" 0, cr0, [r13, #4]") \ 11928c2ecf20Sopenharmony_ci TEST_COPROCESSOR("ldc"two" 0, cr0, [r13, #-4]") \ 11938c2ecf20Sopenharmony_ci TEST_COPROCESSOR("ldc"two" 0, cr0, [r13, #4]!") \ 11948c2ecf20Sopenharmony_ci TEST_COPROCESSOR("ldc"two" 0, cr0, [r13, #-4]!") \ 11958c2ecf20Sopenharmony_ci TEST_COPROCESSOR("ldc"two" 0, cr0, [r13], #4") \ 11968c2ecf20Sopenharmony_ci TEST_COPROCESSOR("ldc"two" 0, cr0, [r13], #-4") \ 11978c2ecf20Sopenharmony_ci TEST_COPROCESSOR("ldc"two" 0, cr0, [r13], {1}") \ 11988c2ecf20Sopenharmony_ci TEST_COPROCESSOR("ldc"two"l 0, cr0, [r13, #4]") \ 11998c2ecf20Sopenharmony_ci TEST_COPROCESSOR("ldc"two"l 0, cr0, [r13, #-4]") \ 12008c2ecf20Sopenharmony_ci TEST_COPROCESSOR("ldc"two"l 0, cr0, [r13, #4]!") \ 12018c2ecf20Sopenharmony_ci TEST_COPROCESSOR("ldc"two"l 0, cr0, [r13, #-4]!") \ 12028c2ecf20Sopenharmony_ci TEST_COPROCESSOR("ldc"two"l 0, cr0, [r13], #4") \ 12038c2ecf20Sopenharmony_ci TEST_COPROCESSOR("ldc"two"l 0, cr0, [r13], #-4") \ 12048c2ecf20Sopenharmony_ci TEST_COPROCESSOR("ldc"two"l 0, cr0, [r13], {1}") \ 12058c2ecf20Sopenharmony_ci \ 12068c2ecf20Sopenharmony_ci TEST_COPROCESSOR( "stc"two" 0, cr0, [r15, #4]") \ 12078c2ecf20Sopenharmony_ci TEST_COPROCESSOR( "stc"two" 0, cr0, [r15, #-4]") \ 12088c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0x##cc##daf0001) " @ stc"two" 0, cr0, [r15, #4]!") \ 12098c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0x##cc##d2f0001) " @ stc"two" 0, cr0, [r15, #-4]!") \ 12108c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0x##cc##caf0001) " @ stc"two" 0, cr0, [r15], #4") \ 12118c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0x##cc##c2f0001) " @ stc"two" 0, cr0, [r15], #-4") \ 12128c2ecf20Sopenharmony_ci TEST_COPROCESSOR( "stc"two" 0, cr0, [r15], {1}") \ 12138c2ecf20Sopenharmony_ci TEST_COPROCESSOR( "stc"two"l 0, cr0, [r15, #4]") \ 12148c2ecf20Sopenharmony_ci TEST_COPROCESSOR( "stc"two"l 0, cr0, [r15, #-4]") \ 12158c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0x##cc##def0001) " @ stc"two"l 0, cr0, [r15, #4]!") \ 12168c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0x##cc##d6f0001) " @ stc"two"l 0, cr0, [r15, #-4]!") \ 12178c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0x##cc##cef0001) " @ stc"two"l 0, cr0, [r15], #4") \ 12188c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0x##cc##c6f0001) " @ stc"two"l 0, cr0, [r15], #-4") \ 12198c2ecf20Sopenharmony_ci TEST_COPROCESSOR( "stc"two"l 0, cr0, [r15], {1}") \ 12208c2ecf20Sopenharmony_ci TEST_COPROCESSOR( "ldc"two" 0, cr0, [r15, #4]") \ 12218c2ecf20Sopenharmony_ci TEST_COPROCESSOR( "ldc"two" 0, cr0, [r15, #-4]") \ 12228c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0x##cc##dbf0001) " @ ldc"two" 0, cr0, [r15, #4]!") \ 12238c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0x##cc##d3f0001) " @ ldc"two" 0, cr0, [r15, #-4]!") \ 12248c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0x##cc##cbf0001) " @ ldc"two" 0, cr0, [r15], #4") \ 12258c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0x##cc##c3f0001) " @ ldc"two" 0, cr0, [r15], #-4") \ 12268c2ecf20Sopenharmony_ci TEST_COPROCESSOR( "ldc"two" 0, cr0, [r15], {1}") \ 12278c2ecf20Sopenharmony_ci TEST_COPROCESSOR( "ldc"two"l 0, cr0, [r15, #4]") \ 12288c2ecf20Sopenharmony_ci TEST_COPROCESSOR( "ldc"two"l 0, cr0, [r15, #-4]") \ 12298c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0x##cc##dff0001) " @ ldc"two"l 0, cr0, [r15, #4]!") \ 12308c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0x##cc##d7f0001) " @ ldc"two"l 0, cr0, [r15, #-4]!") \ 12318c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0x##cc##cff0001) " @ ldc"two"l 0, cr0, [r15], #4") \ 12328c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0x##cc##c7f0001) " @ ldc"two"l 0, cr0, [r15], #-4") \ 12338c2ecf20Sopenharmony_ci TEST_COPROCESSOR( "ldc"two"l 0, cr0, [r15], {1}") 12348c2ecf20Sopenharmony_ci 12358c2ecf20Sopenharmony_ci#define COPROCESSOR_INSTRUCTIONS_MC_MR(two,cc) \ 12368c2ecf20Sopenharmony_ci \ 12378c2ecf20Sopenharmony_ci TEST_COPROCESSOR( "mcrr"two" 0, 15, r0, r14, cr0") \ 12388c2ecf20Sopenharmony_ci TEST_COPROCESSOR( "mcrr"two" 15, 0, r14, r0, cr15") \ 12398c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0x##cc##c4f00f0) " @ mcrr"two" 0, 15, r0, r15, cr0") \ 12408c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0x##cc##c40ff0f) " @ mcrr"two" 15, 0, r15, r0, cr15") \ 12418c2ecf20Sopenharmony_ci TEST_COPROCESSOR( "mrrc"two" 0, 15, r0, r14, cr0") \ 12428c2ecf20Sopenharmony_ci TEST_COPROCESSOR( "mrrc"two" 15, 0, r14, r0, cr15") \ 12438c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0x##cc##c5f00f0) " @ mrrc"two" 0, 15, r0, r15, cr0") \ 12448c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0x##cc##c50ff0f) " @ mrrc"two" 15, 0, r15, r0, cr15") \ 12458c2ecf20Sopenharmony_ci TEST_COPROCESSOR( "cdp"two" 15, 15, cr15, cr15, cr15, 7") \ 12468c2ecf20Sopenharmony_ci TEST_COPROCESSOR( "cdp"two" 0, 0, cr0, cr0, cr0, 0") \ 12478c2ecf20Sopenharmony_ci TEST_COPROCESSOR( "mcr"two" 15, 7, r15, cr15, cr15, 7") \ 12488c2ecf20Sopenharmony_ci TEST_COPROCESSOR( "mcr"two" 0, 0, r0, cr0, cr0, 0") \ 12498c2ecf20Sopenharmony_ci TEST_COPROCESSOR( "mrc"two" 15, 7, r15, cr15, cr15, 7") \ 12508c2ecf20Sopenharmony_ci TEST_COPROCESSOR( "mrc"two" 0, 0, r0, cr0, cr0, 0") 12518c2ecf20Sopenharmony_ci 12528c2ecf20Sopenharmony_ci COPROCESSOR_INSTRUCTIONS_ST_LD("",e) 12538c2ecf20Sopenharmony_ci#if __LINUX_ARM_ARCH__ >= 5 12548c2ecf20Sopenharmony_ci COPROCESSOR_INSTRUCTIONS_MC_MR("",e) 12558c2ecf20Sopenharmony_ci#endif 12568c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("svc 0") 12578c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("svc 0xffffff") 12588c2ecf20Sopenharmony_ci 12598c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("svc 0") 12608c2ecf20Sopenharmony_ci 12618c2ecf20Sopenharmony_ci TEST_GROUP("Unconditional instruction") 12628c2ecf20Sopenharmony_ci 12638c2ecf20Sopenharmony_ci#if __LINUX_ARM_ARCH__ >= 6 12648c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("srsda sp, 0x13") 12658c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("srsdb sp, 0x13") 12668c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("srsia sp, 0x13") 12678c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("srsib sp, 0x13") 12688c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("srsda sp!, 0x13") 12698c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("srsdb sp!, 0x13") 12708c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("srsia sp!, 0x13") 12718c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("srsib sp!, 0x13") 12728c2ecf20Sopenharmony_ci 12738c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("rfeda sp") 12748c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("rfedb sp") 12758c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("rfeia sp") 12768c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("rfeib sp") 12778c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("rfeda sp!") 12788c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("rfedb sp!") 12798c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("rfeia sp!") 12808c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("rfeib sp!") 12818c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xf81d0a00) " @ rfeda pc") 12828c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xf91d0a00) " @ rfedb pc") 12838c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xf89d0a00) " @ rfeia pc") 12848c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xf99d0a00) " @ rfeib pc") 12858c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xf83d0a00) " @ rfeda pc!") 12868c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xf93d0a00) " @ rfedb pc!") 12878c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xf8bd0a00) " @ rfeia pc!") 12888c2ecf20Sopenharmony_ci TEST_UNSUPPORTED(__inst_arm(0xf9bd0a00) " @ rfeib pc!") 12898c2ecf20Sopenharmony_ci#endif /* __LINUX_ARM_ARCH__ >= 6 */ 12908c2ecf20Sopenharmony_ci 12918c2ecf20Sopenharmony_ci#if __LINUX_ARM_ARCH__ >= 6 12928c2ecf20Sopenharmony_ci TEST_X( "blx __dummy_thumb_subroutine_even", 12938c2ecf20Sopenharmony_ci ".thumb \n\t" 12948c2ecf20Sopenharmony_ci ".space 4 \n\t" 12958c2ecf20Sopenharmony_ci ".type __dummy_thumb_subroutine_even, %%function \n\t" 12968c2ecf20Sopenharmony_ci "__dummy_thumb_subroutine_even: \n\t" 12978c2ecf20Sopenharmony_ci "mov r0, pc \n\t" 12988c2ecf20Sopenharmony_ci "bx lr \n\t" 12998c2ecf20Sopenharmony_ci ".arm \n\t" 13008c2ecf20Sopenharmony_ci ) 13018c2ecf20Sopenharmony_ci TEST( "blx __dummy_thumb_subroutine_even") 13028c2ecf20Sopenharmony_ci 13038c2ecf20Sopenharmony_ci TEST_X( "blx __dummy_thumb_subroutine_odd", 13048c2ecf20Sopenharmony_ci ".thumb \n\t" 13058c2ecf20Sopenharmony_ci ".space 2 \n\t" 13068c2ecf20Sopenharmony_ci ".type __dummy_thumb_subroutine_odd, %%function \n\t" 13078c2ecf20Sopenharmony_ci "__dummy_thumb_subroutine_odd: \n\t" 13088c2ecf20Sopenharmony_ci "mov r0, pc \n\t" 13098c2ecf20Sopenharmony_ci "bx lr \n\t" 13108c2ecf20Sopenharmony_ci ".arm \n\t" 13118c2ecf20Sopenharmony_ci ) 13128c2ecf20Sopenharmony_ci TEST( "blx __dummy_thumb_subroutine_odd") 13138c2ecf20Sopenharmony_ci#endif /* __LINUX_ARM_ARCH__ >= 6 */ 13148c2ecf20Sopenharmony_ci 13158c2ecf20Sopenharmony_ci#if __LINUX_ARM_ARCH__ >= 5 13168c2ecf20Sopenharmony_ci COPROCESSOR_INSTRUCTIONS_ST_LD("2",f) 13178c2ecf20Sopenharmony_ci#endif 13188c2ecf20Sopenharmony_ci#if __LINUX_ARM_ARCH__ >= 6 13198c2ecf20Sopenharmony_ci COPROCESSOR_INSTRUCTIONS_MC_MR("2",f) 13208c2ecf20Sopenharmony_ci#endif 13218c2ecf20Sopenharmony_ci 13228c2ecf20Sopenharmony_ci TEST_GROUP("Miscellaneous instructions, memory hints, and Advanced SIMD instructions") 13238c2ecf20Sopenharmony_ci 13248c2ecf20Sopenharmony_ci#if __LINUX_ARM_ARCH__ >= 6 13258c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("cps 0x13") 13268c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("cpsie i") 13278c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("cpsid i") 13288c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("cpsie i,0x13") 13298c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("cpsid i,0x13") 13308c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("setend le") 13318c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("setend be") 13328c2ecf20Sopenharmony_ci#endif 13338c2ecf20Sopenharmony_ci 13348c2ecf20Sopenharmony_ci#if __LINUX_ARM_ARCH__ >= 7 13358c2ecf20Sopenharmony_ci TEST_P("pli [r",0,0b,", #16]") 13368c2ecf20Sopenharmony_ci TEST( "pli [pc, #0]") 13378c2ecf20Sopenharmony_ci TEST_RR("pli [r",12,0b,", r",0, 16,"]") 13388c2ecf20Sopenharmony_ci TEST_RR("pli [r",0, 0b,", -r",12,16,", lsl #4]") 13398c2ecf20Sopenharmony_ci#endif 13408c2ecf20Sopenharmony_ci 13418c2ecf20Sopenharmony_ci#if __LINUX_ARM_ARCH__ >= 5 13428c2ecf20Sopenharmony_ci TEST_P("pld [r",0,32,", #-16]") 13438c2ecf20Sopenharmony_ci TEST( "pld [pc, #0]") 13448c2ecf20Sopenharmony_ci TEST_PR("pld [r",7, 24, ", r",0, 16,"]") 13458c2ecf20Sopenharmony_ci TEST_PR("pld [r",8, 24, ", -r",12,16,", lsl #4]") 13468c2ecf20Sopenharmony_ci#endif 13478c2ecf20Sopenharmony_ci 13488c2ecf20Sopenharmony_ci#if __LINUX_ARM_ARCH__ >= 7 13498c2ecf20Sopenharmony_ci TEST_SUPPORTED( __inst_arm(0xf590f000) " @ pldw [r0, #0]") 13508c2ecf20Sopenharmony_ci TEST_SUPPORTED( __inst_arm(0xf797f000) " @ pldw [r7, r0]") 13518c2ecf20Sopenharmony_ci TEST_SUPPORTED( __inst_arm(0xf798f18c) " @ pldw [r8, r12, lsl #3]"); 13528c2ecf20Sopenharmony_ci#endif 13538c2ecf20Sopenharmony_ci 13548c2ecf20Sopenharmony_ci#if __LINUX_ARM_ARCH__ >= 7 13558c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("clrex") 13568c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("dsb") 13578c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("dmb") 13588c2ecf20Sopenharmony_ci TEST_UNSUPPORTED("isb") 13598c2ecf20Sopenharmony_ci#endif 13608c2ecf20Sopenharmony_ci 13618c2ecf20Sopenharmony_ci verbose("\n"); 13628c2ecf20Sopenharmony_ci} 13638c2ecf20Sopenharmony_ci 1364