mirror of
https://github.com/qemu/qemu.git
synced 2024-11-25 11:53:39 +08:00
target/mips: Add nanoMIPS decoding and extraction utilities
Add some basic utility functions and macros for nanoMIPS decoding engine. Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Signed-off-by: Yongbok Kim <yongbok.kim@mips.com> Signed-off-by: Aleksandar Markovic <amarkovic@wavecomp.com> Signed-off-by: Stefan Markovic <smarkovic@wavecomp.com>
This commit is contained in:
parent
c533c0f474
commit
6bfa9f4c9c
@ -16593,6 +16593,17 @@ enum {
|
||||
*
|
||||
*/
|
||||
|
||||
|
||||
/* extraction utilities */
|
||||
|
||||
#define NANOMIPS_EXTRACT_RD(op) ((op >> 7) & 0x7)
|
||||
#define NANOMIPS_EXTRACT_RS(op) ((op >> 4) & 0x7)
|
||||
#define NANOMIPS_EXTRACT_RS2(op) uMIPS_RS(op)
|
||||
#define NANOMIPS_EXTRACT_RS1(op) ((op >> 1) & 0x7)
|
||||
#define NANOMIPS_EXTRACT_RD5(op) ((op >> 5) & 0x1f)
|
||||
#define NANOMIPS_EXTRACT_RS5(op) (op & 0x1f)
|
||||
|
||||
|
||||
static int decode_nanomips_opc(CPUMIPSState *env, DisasContext *ctx)
|
||||
{
|
||||
return 2;
|
||||
|
Loading…
Reference in New Issue
Block a user