From 2f8890efc521d0477728ade637cb1d03a4aa799d Mon Sep 17 00:00:00 2001 From: Victor Do Nascimento Date: Tue, 9 Jan 2024 16:22:07 +0000 Subject: aarch64: rcpc3: Create implicit load/store size calc function The allowed immediate offsets in integer rcpc3 load store instructions are not encoded explicitly in the instruction itself, being rather implicitly equivalent to the amount of data loaded/stored by the instruction. This leads to the requirement that this quantity be calculated based on the number of registers involved in the transfer, either as data source or destination registers and their respective qualifiers. This is done via `calc_ldst_datasize (const aarch64_opnd_info *opnds)' implemented here, using a cumulative sum of qualifier sizes preceding the address operand in the OPNDS operand list argument. --- include/opcode/aarch64.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'include/opcode') diff --git a/include/opcode/aarch64.h b/include/opcode/aarch64.h index 7c0f7ce..3c1f522 100644 --- a/include/opcode/aarch64.h +++ b/include/opcode/aarch64.h @@ -1858,6 +1858,9 @@ aarch64_sve_dupm_mov_immediate_p (uint64_t, int); extern bool aarch64_cpu_supports_inst_p (aarch64_feature_set, aarch64_inst *); +extern int +calc_ldst_datasize (const aarch64_opnd_info *opnds); + #ifdef DEBUG_AARCH64 extern int debug_dump; -- cgit v1.1