@@ -856,7 +856,7 @@ class MipsOperand : public MCParsedAsmOperand {
856
856
public:
857
857
// / Coerce the register to GPR32 and return the real register for the current
858
858
// / target.
859
- unsigned getGPR32Reg () const {
859
+ MCRegister getGPR32Reg () const {
860
860
assert (isRegIdx () && (RegIdx.Kind & RegKind_GPR) && " Invalid access!" );
861
861
AsmParser.warnIfRegIndexIsAT (RegIdx.Index , StartLoc);
862
862
unsigned ClassID = Mips::GPR32RegClassID;
@@ -865,15 +865,15 @@ class MipsOperand : public MCParsedAsmOperand {
865
865
866
866
// / Coerce the register to GPR32 and return the real register for the current
867
867
// / target.
868
- unsigned getGPRMM16Reg () const {
868
+ MCRegister getGPRMM16Reg () const {
869
869
assert (isRegIdx () && (RegIdx.Kind & RegKind_GPR) && " Invalid access!" );
870
870
unsigned ClassID = Mips::GPR32RegClassID;
871
871
return RegIdx.RegInfo ->getRegClass (ClassID).getRegister (RegIdx.Index );
872
872
}
873
873
874
874
// / Coerce the register to GPR64 and return the real register for the current
875
875
// / target.
876
- unsigned getGPR64Reg () const {
876
+ MCRegister getGPR64Reg () const {
877
877
assert (isRegIdx () && (RegIdx.Kind & RegKind_GPR) && " Invalid access!" );
878
878
unsigned ClassID = Mips::GPR64RegClassID;
879
879
return RegIdx.RegInfo ->getRegClass (ClassID).getRegister (RegIdx.Index );
@@ -882,7 +882,7 @@ class MipsOperand : public MCParsedAsmOperand {
882
882
private:
883
883
// / Coerce the register to AFGR64 and return the real register for the current
884
884
// / target.
885
- unsigned getAFGR64Reg () const {
885
+ MCRegister getAFGR64Reg () const {
886
886
assert (isRegIdx () && (RegIdx.Kind & RegKind_FGR) && " Invalid access!" );
887
887
if (RegIdx.Index % 2 != 0 )
888
888
AsmParser.Warning (StartLoc, " Float register should be even." );
@@ -892,31 +892,31 @@ class MipsOperand : public MCParsedAsmOperand {
892
892
893
893
// / Coerce the register to FGR64 and return the real register for the current
894
894
// / target.
895
- unsigned getFGR64Reg () const {
895
+ MCRegister getFGR64Reg () const {
896
896
assert (isRegIdx () && (RegIdx.Kind & RegKind_FGR) && " Invalid access!" );
897
897
return RegIdx.RegInfo ->getRegClass (Mips::FGR64RegClassID)
898
898
.getRegister (RegIdx.Index );
899
899
}
900
900
901
901
// / Coerce the register to FGR32 and return the real register for the current
902
902
// / target.
903
- unsigned getFGR32Reg () const {
903
+ MCRegister getFGR32Reg () const {
904
904
assert (isRegIdx () && (RegIdx.Kind & RegKind_FGR) && " Invalid access!" );
905
905
return RegIdx.RegInfo ->getRegClass (Mips::FGR32RegClassID)
906
906
.getRegister (RegIdx.Index );
907
907
}
908
908
909
909
// / Coerce the register to FCC and return the real register for the current
910
910
// / target.
911
- unsigned getFCCReg () const {
911
+ MCRegister getFCCReg () const {
912
912
assert (isRegIdx () && (RegIdx.Kind & RegKind_FCC) && " Invalid access!" );
913
913
return RegIdx.RegInfo ->getRegClass (Mips::FCCRegClassID)
914
914
.getRegister (RegIdx.Index );
915
915
}
916
916
917
917
// / Coerce the register to MSA128 and return the real register for the current
918
918
// / target.
919
- unsigned getMSA128Reg () const {
919
+ MCRegister getMSA128Reg () const {
920
920
assert (isRegIdx () && (RegIdx.Kind & RegKind_MSA128) && " Invalid access!" );
921
921
// It doesn't matter which of the MSA128[BHWD] classes we use. They are all
922
922
// identical
@@ -926,71 +926,71 @@ class MipsOperand : public MCParsedAsmOperand {
926
926
927
927
// / Coerce the register to MSACtrl and return the real register for the
928
928
// / current target.
929
- unsigned getMSACtrlReg () const {
929
+ MCRegister getMSACtrlReg () const {
930
930
assert (isRegIdx () && (RegIdx.Kind & RegKind_MSACtrl) && " Invalid access!" );
931
931
unsigned ClassID = Mips::MSACtrlRegClassID;
932
932
return RegIdx.RegInfo ->getRegClass (ClassID).getRegister (RegIdx.Index );
933
933
}
934
934
935
935
// / Coerce the register to COP0 and return the real register for the
936
936
// / current target.
937
- unsigned getCOP0Reg () const {
937
+ MCRegister getCOP0Reg () const {
938
938
assert (isRegIdx () && (RegIdx.Kind & RegKind_COP0) && " Invalid access!" );
939
939
unsigned ClassID = Mips::COP0RegClassID;
940
940
return RegIdx.RegInfo ->getRegClass (ClassID).getRegister (RegIdx.Index );
941
941
}
942
942
943
943
// / Coerce the register to COP2 and return the real register for the
944
944
// / current target.
945
- unsigned getCOP2Reg () const {
945
+ MCRegister getCOP2Reg () const {
946
946
assert (isRegIdx () && (RegIdx.Kind & RegKind_COP2) && " Invalid access!" );
947
947
unsigned ClassID = Mips::COP2RegClassID;
948
948
return RegIdx.RegInfo ->getRegClass (ClassID).getRegister (RegIdx.Index );
949
949
}
950
950
951
951
// / Coerce the register to COP3 and return the real register for the
952
952
// / current target.
953
- unsigned getCOP3Reg () const {
953
+ MCRegister getCOP3Reg () const {
954
954
assert (isRegIdx () && (RegIdx.Kind & RegKind_COP3) && " Invalid access!" );
955
955
unsigned ClassID = Mips::COP3RegClassID;
956
956
return RegIdx.RegInfo ->getRegClass (ClassID).getRegister (RegIdx.Index );
957
957
}
958
958
959
959
// / Coerce the register to ACC64DSP and return the real register for the
960
960
// / current target.
961
- unsigned getACC64DSPReg () const {
961
+ MCRegister getACC64DSPReg () const {
962
962
assert (isRegIdx () && (RegIdx.Kind & RegKind_ACC) && " Invalid access!" );
963
963
unsigned ClassID = Mips::ACC64DSPRegClassID;
964
964
return RegIdx.RegInfo ->getRegClass (ClassID).getRegister (RegIdx.Index );
965
965
}
966
966
967
967
// / Coerce the register to HI32DSP and return the real register for the
968
968
// / current target.
969
- unsigned getHI32DSPReg () const {
969
+ MCRegister getHI32DSPReg () const {
970
970
assert (isRegIdx () && (RegIdx.Kind & RegKind_ACC) && " Invalid access!" );
971
971
unsigned ClassID = Mips::HI32DSPRegClassID;
972
972
return RegIdx.RegInfo ->getRegClass (ClassID).getRegister (RegIdx.Index );
973
973
}
974
974
975
975
// / Coerce the register to LO32DSP and return the real register for the
976
976
// / current target.
977
- unsigned getLO32DSPReg () const {
977
+ MCRegister getLO32DSPReg () const {
978
978
assert (isRegIdx () && (RegIdx.Kind & RegKind_ACC) && " Invalid access!" );
979
979
unsigned ClassID = Mips::LO32DSPRegClassID;
980
980
return RegIdx.RegInfo ->getRegClass (ClassID).getRegister (RegIdx.Index );
981
981
}
982
982
983
983
// / Coerce the register to CCR and return the real register for the
984
984
// / current target.
985
- unsigned getCCRReg () const {
985
+ MCRegister getCCRReg () const {
986
986
assert (isRegIdx () && (RegIdx.Kind & RegKind_CCR) && " Invalid access!" );
987
987
unsigned ClassID = Mips::CCRRegClassID;
988
988
return RegIdx.RegInfo ->getRegClass (ClassID).getRegister (RegIdx.Index );
989
989
}
990
990
991
991
// / Coerce the register to HWRegs and return the real register for the
992
992
// / current target.
993
- unsigned getHWRegsReg () const {
993
+ MCRegister getHWRegsReg () const {
994
994
assert (isRegIdx () && (RegIdx.Kind & RegKind_HWRegs) && " Invalid access!" );
995
995
unsigned ClassID = Mips::HWRegsRegClassID;
996
996
return RegIdx.RegInfo ->getRegClass (ClassID).getRegister (RegIdx.Index );
0 commit comments