2022-06-07 02:19:42 +00:00
|
|
|
/* SPDX-FileCopyrightText: © 2022 Decompollaborate */
|
|
|
|
/* SPDX-License-Identifier: MIT */
|
|
|
|
|
|
|
|
#ifndef RABBITIZER_INSTR_RSP_H
|
|
|
|
#define RABBITIZER_INSTR_RSP_H
|
|
|
|
#pragma once
|
|
|
|
|
|
|
|
#include "RabbitizerInstr.h"
|
|
|
|
|
|
|
|
|
2022-06-07 06:28:10 +00:00
|
|
|
#define RAB_INSTR_RSP_GET_VS(self) ((self)->rd)
|
|
|
|
#define RAB_INSTR_RSP_GET_VT(self) ((self)->rt)
|
|
|
|
#define RAB_INSTR_RSP_GET_VD(self) ((self)->sa)
|
|
|
|
|
|
|
|
#define RAB_INSTR_RSP_GET_ELEMENT_HIGH(self) ((((self)->rs)) & 0xF)
|
2022-06-07 02:19:42 +00:00
|
|
|
#define RAB_INSTR_RSP_GET_ELEMENT_LOW(self) ((((self)->sa) >> 1) & 0xF)
|
|
|
|
#define RAB_INSTR_RSP_GET_OFFSET_VECTOR_RAW(self) (RAB_INSTR_GET_IMMEDIATE(self) & 0x7F)
|
|
|
|
|
|
|
|
|
|
|
|
void RabbitizerInstrRsp_init(RabbitizerInstr *self, uint32_t word);
|
|
|
|
void RabbitizerInstrRsp_destroy(RabbitizerInstr *self);
|
|
|
|
|
|
|
|
|
|
|
|
void RabbitizerInstrRsp_processUniqueId_Normal(RabbitizerInstr *self);
|
2022-06-07 02:42:22 +00:00
|
|
|
void RabbitizerInstrRsp_processUniqueId_Special(RabbitizerInstr *self);
|
|
|
|
void RabbitizerInstrRsp_processUniqueId_Regimm(RabbitizerInstr *self);
|
|
|
|
|
2022-06-07 02:19:42 +00:00
|
|
|
void RabbitizerInstrRsp_processUniqueId(RabbitizerInstr *self);
|
|
|
|
|
|
|
|
|
|
|
|
uint16_t RabbitizerInstrRsp_GetOffsetVector(const RabbitizerInstr *self);
|
|
|
|
|
|
|
|
uint8_t RabbitizerInstrRsp_processVectorElement(const RabbitizerInstr *self, uint8_t element);
|
|
|
|
|
|
|
|
|
|
|
|
#endif
|