diff options
| author | LIU Zhiwei <zhiwei_liu@linux.alibaba.com> | 2024-12-06 11:24:11 +0800 |
|---|---|---|
| committer | Richard Henderson <richard.henderson@linaro.org> | 2025-01-16 20:57:16 -0800 |
| commit | f65f3ebfaddbbf679c01534d55600525a3cb330c (patch) | |
| tree | 9173151e54e273f00339fffeb16d979c0cd0da74 /tcg/optimize.c | |
| parent | 4d5d933bbc7cc52f6cc6b9021f91fa06266222d5 (diff) | |
| download | focaccia-qemu-f65f3ebfaddbbf679c01534d55600525a3cb330c.tar.gz focaccia-qemu-f65f3ebfaddbbf679c01534d55600525a3cb330c.zip | |
disas/riscv: Guard dec->cfg dereference for host disassemble
For riscv host, it will set dec->cfg to zero. Thus we shuld guard the dec->cfg deference for riscv host disassemble. And in general, we should only use dec->cfg for target in three cases: 1) For not incompatible encodings, such as zcmp/zcmt/zfinx. 2) For maybe-ops encodings, they are better to be disassembled to the "real" extensions, such as zicfiss. The guard of dec->zimop and dec->zcmop is for comment and avoid check for every extension that encoded in maybe-ops area. 3) For custom encodings, we have to use dec->cfg to disassemble custom encodings using the same encoding area. Signed-off-by: LIU Zhiwei <zhiwei_liu@linux.alibaba.com> Suggested-by: Richard Henderson <richard.henderson@linaro.org> Signed-off-by: Richard Henderson <richard.henderson@linaro.org> Message-ID: <20241206032411.52528-1-zhiwei_liu@linux.alibaba.com>
Diffstat (limited to 'tcg/optimize.c')
0 files changed, 0 insertions, 0 deletions