[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH v2 02/25] target/hexagon: Replace ldtul_p() -> ldl_p()
From: |
Philippe Mathieu-Daudé |
Subject: |
[PATCH v2 02/25] target/hexagon: Replace ldtul_p() -> ldl_p() |
Date: |
Fri, 4 Oct 2024 13:30:18 -0300 |
The Hexagon target is only built for 64-bit.
Using ldtul_p() is pointless, replace by ldl_p().
Mechanical change doing:
$ sed -i -e 's/ldtul_p/ldl_p/' \
$(git grep -wl ldtul_p target/hexagon/)
Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
---
target/hexagon/gdbstub.c | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/target/hexagon/gdbstub.c b/target/hexagon/gdbstub.c
index 94e1db8ef8d..557b3029785 100644
--- a/target/hexagon/gdbstub.c
+++ b/target/hexagon/gdbstub.c
@@ -52,7 +52,7 @@ int hexagon_gdb_write_register(CPUState *cs, uint8_t
*mem_buf, int n)
CPUHexagonState *env = cpu_env(cs);
if (n == HEX_REG_P3_0_ALIASED) {
- uint32_t p3_0 = ldtul_p(mem_buf);
+ uint32_t p3_0 = ldl_p(mem_buf);
for (int i = 0; i < NUM_PREGS; i++) {
env->pred[i] = extract32(p3_0, i * 8, 8);
}
@@ -60,14 +60,14 @@ int hexagon_gdb_write_register(CPUState *cs, uint8_t
*mem_buf, int n)
}
if (n < TOTAL_PER_THREAD_REGS) {
- env->gpr[n] = ldtul_p(mem_buf);
+ env->gpr[n] = ldl_p(mem_buf);
return sizeof(target_ulong);
}
n -= TOTAL_PER_THREAD_REGS;
if (n < NUM_PREGS) {
- env->pred[n] = ldtul_p(mem_buf) & 0xff;
+ env->pred[n] = ldl_p(mem_buf) & 0xff;
return sizeof(uint8_t);
}
@@ -117,7 +117,7 @@ static int gdb_put_vreg(CPUHexagonState *env, uint8_t
*mem_buf, int n)
{
int i;
for (i = 0; i < ARRAY_SIZE(env->VRegs[n].uw); i++) {
- env->VRegs[n].uw[i] = ldtul_p(mem_buf);
+ env->VRegs[n].uw[i] = ldl_p(mem_buf);
mem_buf += 4;
}
return MAX_VEC_SIZE_BYTES;
@@ -127,7 +127,7 @@ static int gdb_put_qreg(CPUHexagonState *env, uint8_t
*mem_buf, int n)
{
int i;
for (i = 0; i < ARRAY_SIZE(env->QRegs[n].uw); i++) {
- env->QRegs[n].uw[i] = ldtul_p(mem_buf);
+ env->QRegs[n].uw[i] = ldl_p(mem_buf);
mem_buf += 4;
}
return MAX_VEC_SIZE_BYTES / 8;
--
2.45.2
- [PATCH v2 00/25] misc: Use explicit endian LD/ST API, Philippe Mathieu-Daudé, 2024/10/04
- [PATCH v2 01/25] gdbstub/helpers: Have ldtul_p() definition use ldn_p(), Philippe Mathieu-Daudé, 2024/10/04
- [PATCH v2 02/25] target/hexagon: Replace ldtul_p() -> ldl_p(),
Philippe Mathieu-Daudé <=
- [PATCH v2 03/25] target/alpha: Replace ldtul_p() -> ldq_p(), Philippe Mathieu-Daudé, 2024/10/04
- [PATCH v2 04/25] target/s390x: Replace ldtul_p() -> ldq_p(), Philippe Mathieu-Daudé, 2024/10/04
- [PATCH v2 05/25] gdbstub/helpers: Introduce ldtul_$endian_p() helpers, Philippe Mathieu-Daudé, 2024/10/04
- [PATCH v2 06/25] target/alpha: Use explicit little-endian LD/ST API, Philippe Mathieu-Daudé, 2024/10/04
- [PATCH v2 07/25] target/hexagon: Use explicit little-endian LD/ST API, Philippe Mathieu-Daudé, 2024/10/04