[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 28/55] disas/nanomips: Delete wrapper functions
From: |
Philippe Mathieu-Daudé |
Subject: |
[PULL 28/55] disas/nanomips: Delete wrapper functions |
Date: |
Sun, 30 Oct 2022 23:28:14 +0100 |
From: Milica Lazarevic <milica.lazarevic@syrmia.com>
Following functions just wrap the decode_gpr_gpr3() function:
- encode_rs3_and_check_rs3_ge_rt3()
- encode_rs3_and_check_rs3_lt_rt3()
Therefore those have been deleted. Calls to these two functions have
been replaced with calls to decode_gpr_gpr3.
Signed-off-by: Milica Lazarevic <milica.lazarevic@syrmia.com>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Message-Id: <20220912122635.74032-15-milica.lazarevic@syrmia.com>
Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
---
disas/nanomips.cpp | 18 ++----------------
1 file changed, 2 insertions(+), 16 deletions(-)
diff --git a/disas/nanomips.cpp b/disas/nanomips.cpp
index b90be5744e..170f5c5c17 100644
--- a/disas/nanomips.cpp
+++ b/disas/nanomips.cpp
@@ -505,20 +505,6 @@ static int64 neg_copy(uint64 d)
}
-/* strange wrapper around gpr3 */
-static uint64 encode_rs3_and_check_rs3_ge_rt3(uint64 d)
-{
-return decode_gpr_gpr3(d);
-}
-
-
-/* strange wrapper around gpr3 */
-static uint64 encode_rs3_and_check_rs3_lt_rt3(uint64 d)
-{
- return decode_gpr_gpr3(d);
-}
-
-
static uint64 encode_count3_from_count(uint64 d)
{
IMGASSERTONCE(d < 8);
@@ -2958,7 +2944,7 @@ static std::string BEQC_16_(uint64 instruction, Dis_info
*info)
uint64 rs3_value = extract_rs3_6_5_4(instruction);
uint64 u_value = extract_u_3_2_1_0__s1(instruction);
- std::string rs3 = GPR(encode_rs3_and_check_rs3_lt_rt3(rs3_value));
+ std::string rs3 = GPR(decode_gpr_gpr3(rs3_value));
std::string rt3 = GPR(decode_gpr_gpr3(rt3_value));
std::string u = ADDRESS(u_value, 2, info);
@@ -3244,7 +3230,7 @@ static std::string BNEC_16_(uint64 instruction, Dis_info
*info)
uint64 rs3_value = extract_rs3_6_5_4(instruction);
uint64 u_value = extract_u_3_2_1_0__s1(instruction);
- std::string rs3 = GPR(encode_rs3_and_check_rs3_ge_rt3(rs3_value));
+ std::string rs3 = GPR(decode_gpr_gpr3(rs3_value));
std::string rt3 = GPR(decode_gpr_gpr3(rt3_value));
std::string u = ADDRESS(u_value, 2, info);
--
2.37.3
- [PULL 17/55] disas/nanomips: Delete NMD class field, (continued)
- [PULL 17/55] disas/nanomips: Delete NMD class field, Philippe Mathieu-Daudé, 2022/10/30
- [PULL 18/55] disas/nanomips: Delete NMD class second field, Philippe Mathieu-Daudé, 2022/10/30
- [PULL 19/55] disas/nanomips: Remove helper methods from class, Philippe Mathieu-Daudé, 2022/10/30
- [PULL 20/55] disas/nanomips: Remove __cond methods from class, Philippe Mathieu-Daudé, 2022/10/30
- [PULL 21/55] disas/nanomips: Remove disasm methods from class, Philippe Mathieu-Daudé, 2022/10/30
- [PULL 22/55] disas/nanomips: Remove Pool tables from the class, Philippe Mathieu-Daudé, 2022/10/30
- [PULL 23/55] disas/nanomips: Remove NMD class, Philippe Mathieu-Daudé, 2022/10/30
- [PULL 24/55] disas/nanomips: Move typedefs etc to nanomips.cpp, Philippe Mathieu-Daudé, 2022/10/30
- [PULL 25/55] disas/nanomips: Delete nanomips.h, Philippe Mathieu-Daudé, 2022/10/30
- [PULL 26/55] disas/nanomips: Remove #include <sstream>, Philippe Mathieu-Daudé, 2022/10/30
- [PULL 28/55] disas/nanomips: Delete wrapper functions,
Philippe Mathieu-Daudé <=
- [PULL 27/55] disas/nanomips: Delete copy functions, Philippe Mathieu-Daudé, 2022/10/30
- [PULL 30/55] disas/nanomips: Remove IMMEDIATE functions, Philippe Mathieu-Daudé, 2022/10/30
- [PULL 29/55] disas/nanomips: Replace std::string type, Philippe Mathieu-Daudé, 2022/10/30
- [PULL 31/55] disas/nanomips: Remove CPR function, Philippe Mathieu-Daudé, 2022/10/30
- [PULL 32/55] disas/nanomips: Prevent memory leaking, Philippe Mathieu-Daudé, 2022/10/30
- [PULL 33/55] disas/nanomips: Remove function overloading, Philippe Mathieu-Daudé, 2022/10/30
- [PULL 34/55] disas/nanomips: Expand Dis_info struct, Philippe Mathieu-Daudé, 2022/10/30
- [PULL 35/55] disas/nanomips: Replace exception handling, Philippe Mathieu-Daudé, 2022/10/30
- [PULL 36/55] disas/nanomips: Replace Cpp enums for C enums, Philippe Mathieu-Daudé, 2022/10/30
- [PULL 37/55] disas/nanomips: Remove argument passing by ref, Philippe Mathieu-Daudé, 2022/10/30