capstone/tests/details
Andrew Gaul d770dd020c
AArch64: report NZCV access for MRS/MSR of NZCV (#3002)
MRS Xt, NZCV reads (and MSR NZCV, Xt writes) the same flags every
flag-setting instruction implicitly defines, but the generated
implicit register lists cannot express it: MRS/MSR are single generic
instructions whose system register is an immediate operand, so LLVM's
static Uses/Defs do not depend on it. The semantic link is already
half-modeled: AArch64_check_updates_flags() sets update_flags for
MSR NZCV, yet neither direction surfaces in the detail register lists
or cs_regs_access().

Add the aliased NZCV register to the implicit lists when MRS reads or
MSR writes it. The 128-bit pair forms MRRS/MSRR are deliberately
excluded: NZCV is not a valid 128-bit system register, so those
encodings are UNDEFINED rather than flag accesses (an exhaustive
2^32-word cross-check against an external NZCV-liveness model caught
exactly this over-match in an earlier revision of the patch).

Add detail tests covering both directions, a TPIDR_EL0 control case,
and exact-match register lists for MRRS/MSRR.
2026-07-22 16:13:58 +00:00
..
aarch64.yaml AArch64: report NZCV access for MRS/MSR of NZCV (#3002) 2026-07-22 16:13:58 +00:00
alpha.yaml Alpha: fix decoder bugs and add test coverage (#2967) 2026-06-20 13:28:47 +00:00
arc.yaml Rebased #2570 (#2614) 2025-01-28 22:34:24 +08:00
arm.yaml Fix arm pop reg access (#2718) 2025-05-26 11:00:58 +08:00
bpf.yaml Update BPF arch (#2568) 2024-12-15 20:46:45 +08:00
cs_common_details.yaml Alpha: fix decoder bugs and add test coverage (#2967) 2026-06-20 13:28:47 +00:00
evm.yaml Apply new EVM opcode updates (#2602) 2025-01-28 20:51:43 +08:00
hppa.yaml HPPA fix mem operands access and instruction printing (#2746) 2025-07-06 11:21:22 +00:00
loongarch.yaml Fix LoongArch ld/st instructions register info (#2701) 2025-05-20 17:34:48 +08:00
m68k.yaml M68K: Fix FPU condition and FMOVEM decoding (#2993) 2026-07-13 12:52:39 +00:00
m680x.yaml Extend M680X support to HCS12X (#2898) 2026-05-02 09:04:08 +00:00
mips.yaml Fix duplication of memory operand (#2761) 2025-07-23 17:58:47 +00:00
mos65xx.yaml Modern Testing (#2456) 2024-08-31 21:33:38 +08:00
ppc.yaml PPC regressions (#2575) 2024-12-15 14:05:26 +08:00
README.md Modern Testing (#2456) 2024-08-31 21:33:38 +08:00
riscv.yaml Add frm operands to float/double instructions (#2972) 2026-06-23 13:28:28 +00:00
sh.yaml Modern Testing (#2456) 2024-08-31 21:33:38 +08:00
sparc.yaml Apply other VIS instruction fixes from llvm/#130967 (#2777) 2025-08-20 15:28:10 +00:00
systemz.yaml SystemZ Auto-Sync refactor (#2462) 2024-09-14 16:57:54 +08:00
tms320c64x.yaml Tms32c64x Little Endian (#2648) 2025-03-22 21:49:54 +08:00
tricore.yaml Add tricore tc1.8 instructions (#2595) 2025-01-28 20:50:43 +08:00
wasm.yaml Modern Testing (#2456) 2024-08-31 21:33:38 +08:00
x86.yaml cmpxchg (#2821) 2025-12-02 18:04:30 +00:00
xcore.yaml Modern Testing (#2456) 2024-08-31 21:33:38 +08:00
xtensa.yaml Xtensa: gate ESP32-S3 and HIFI3 ops behind CS_MODE_XTENSA_ESP32S3 (#2979) 2026-07-22 16:13:28 +00:00

Test instruction details

This directory contains test cases for the cs_detail struct. Test files are consumed by the cstest tool (see: suite/cstest).