mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-08-04 06:26:28 +00:00
Add disassembler to MIPS.
Patch by Vladimir Medic. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@154935 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -95,45 +95,65 @@ multiclass MovnPats<RegisterClass CRC, RegisterClass DRC, Instruction MOVNInst,
|
||||
|
||||
// Instantiation of instructions.
|
||||
def MOVZ_I_I : CondMovIntInt<CPURegs, CPURegs, 0x0a, "movz">;
|
||||
let Predicates = [HasMips64] in {
|
||||
let Predicates = [HasMips64],DecoderNamespace = "Mips64" in {
|
||||
def MOVZ_I_I64 : CondMovIntInt<CPURegs, CPU64Regs, 0x0a, "movz">;
|
||||
def MOVZ_I64_I : CondMovIntInt<CPU64Regs, CPURegs, 0x0a, "movz">;
|
||||
def MOVZ_I64_I64 : CondMovIntInt<CPU64Regs, CPU64Regs, 0x0a, "movz">;
|
||||
def MOVZ_I64_I : CondMovIntInt<CPU64Regs, CPURegs, 0x0a, "movz"> {
|
||||
let isCodeGenOnly = 1;
|
||||
}
|
||||
def MOVZ_I64_I64 : CondMovIntInt<CPU64Regs, CPU64Regs, 0x0a, "movz"> {
|
||||
let isCodeGenOnly = 1;
|
||||
}
|
||||
}
|
||||
|
||||
def MOVN_I_I : CondMovIntInt<CPURegs, CPURegs, 0x0b, "movn">;
|
||||
let Predicates = [HasMips64] in {
|
||||
let Predicates = [HasMips64],DecoderNamespace = "Mips64" in {
|
||||
def MOVN_I_I64 : CondMovIntInt<CPURegs, CPU64Regs, 0x0b, "movn">;
|
||||
def MOVN_I64_I : CondMovIntInt<CPU64Regs, CPURegs, 0x0b, "movn">;
|
||||
def MOVN_I64_I64 : CondMovIntInt<CPU64Regs, CPU64Regs, 0x0b, "movn">;
|
||||
def MOVN_I64_I : CondMovIntInt<CPU64Regs, CPURegs, 0x0b, "movn"> {
|
||||
let isCodeGenOnly = 1;
|
||||
}
|
||||
def MOVN_I64_I64 : CondMovIntInt<CPU64Regs, CPU64Regs, 0x0b, "movn"> {
|
||||
let isCodeGenOnly = 1;
|
||||
}
|
||||
}
|
||||
|
||||
def MOVZ_I_S : CondMovIntFP<CPURegs, FGR32, 16, 18, "movz.s">;
|
||||
def MOVZ_I64_S : CondMovIntFP<CPU64Regs, FGR32, 16, 18, "movz.s">,
|
||||
Requires<[HasMips64]>;
|
||||
Requires<[HasMips64]> {
|
||||
let DecoderNamespace = "Mips64";
|
||||
}
|
||||
|
||||
def MOVN_I_S : CondMovIntFP<CPURegs, FGR32, 16, 19, "movn.s">;
|
||||
def MOVN_I64_S : CondMovIntFP<CPU64Regs, FGR32, 16, 19, "movn.s">,
|
||||
Requires<[HasMips64]>;
|
||||
Requires<[HasMips64]> {
|
||||
let DecoderNamespace = "Mips64";
|
||||
}
|
||||
|
||||
let Predicates = [NotFP64bit] in {
|
||||
def MOVZ_I_D32 : CondMovIntFP<CPURegs, AFGR64, 17, 18, "movz.d">;
|
||||
def MOVN_I_D32 : CondMovIntFP<CPURegs, AFGR64, 17, 19, "movn.d">;
|
||||
}
|
||||
let Predicates = [IsFP64bit] in {
|
||||
let Predicates = [IsFP64bit],DecoderNamespace = "Mips64" in {
|
||||
def MOVZ_I_D64 : CondMovIntFP<CPURegs, FGR64, 17, 18, "movz.d">;
|
||||
def MOVZ_I64_D64 : CondMovIntFP<CPU64Regs, FGR64, 17, 18, "movz.d">;
|
||||
def MOVZ_I64_D64 : CondMovIntFP<CPU64Regs, FGR64, 17, 18, "movz.d"> {
|
||||
let isCodeGenOnly = 1;
|
||||
}
|
||||
def MOVN_I_D64 : CondMovIntFP<CPURegs, FGR64, 17, 19, "movn.d">;
|
||||
def MOVN_I64_D64 : CondMovIntFP<CPU64Regs, FGR64, 17, 19, "movn.d">;
|
||||
def MOVN_I64_D64 : CondMovIntFP<CPU64Regs, FGR64, 17, 19, "movn.d"> {
|
||||
let isCodeGenOnly = 1;
|
||||
}
|
||||
}
|
||||
|
||||
def MOVT_I : CondMovFPInt<CPURegs, MipsCMovFP_T, 1, "movt">;
|
||||
def MOVT_I64 : CondMovFPInt<CPU64Regs, MipsCMovFP_T, 1, "movt">,
|
||||
Requires<[HasMips64]>;
|
||||
Requires<[HasMips64]> {
|
||||
let DecoderNamespace = "Mips64";
|
||||
}
|
||||
|
||||
def MOVF_I : CondMovFPInt<CPURegs, MipsCMovFP_F, 0, "movf">;
|
||||
def MOVF_I64 : CondMovFPInt<CPU64Regs, MipsCMovFP_F, 0, "movf">,
|
||||
Requires<[HasMips64]>;
|
||||
Requires<[HasMips64]> {
|
||||
let DecoderNamespace = "Mips64";
|
||||
}
|
||||
|
||||
def MOVT_S : CondMovFPFP<FGR32, MipsCMovFP_T, 16, 1, "movt.s">;
|
||||
def MOVF_S : CondMovFPFP<FGR32, MipsCMovFP_F, 16, 0, "movf.s">;
|
||||
@@ -142,7 +162,7 @@ let Predicates = [NotFP64bit] in {
|
||||
def MOVT_D32 : CondMovFPFP<AFGR64, MipsCMovFP_T, 17, 1, "movt.d">;
|
||||
def MOVF_D32 : CondMovFPFP<AFGR64, MipsCMovFP_F, 17, 0, "movf.d">;
|
||||
}
|
||||
let Predicates = [IsFP64bit] in {
|
||||
let Predicates = [IsFP64bit], DecoderNamespace = "Mips64" in {
|
||||
def MOVT_D64 : CondMovFPFP<FGR64, MipsCMovFP_T, 17, 1, "movt.d">;
|
||||
def MOVF_D64 : CondMovFPFP<FGR64, MipsCMovFP_F, 17, 0, "movf.d">;
|
||||
}
|
||||
|
Reference in New Issue
Block a user