From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:48378) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YBlw1-0002z2-J6 for qemu-devel@nongnu.org; Thu, 15 Jan 2015 10:02:10 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YBlw0-0005VT-JP for qemu-devel@nongnu.org; Thu, 15 Jan 2015 10:02:09 -0500 Received: from mnementh.archaic.org.uk ([2001:8b0:1d0::1]:54839) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YBlw0-0005Qc-D6 for qemu-devel@nongnu.org; Thu, 15 Jan 2015 10:02:08 -0500 From: Peter Maydell Date: Thu, 15 Jan 2015 15:01:55 +0000 Message-Id: <1421334118-3287-13-git-send-email-peter.maydell@linaro.org> In-Reply-To: <1421334118-3287-1-git-send-email-peter.maydell@linaro.org> References: <1421334118-3287-1-git-send-email-peter.maydell@linaro.org> Subject: [Qemu-devel] [PATCH 12/15] cpu_ldst_template.h: Use ld*_p directly rather than via ld*_raw macros List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Paolo Bonzini , Riku Voipio , Richard Henderson , patches@linaro.org The ld*_raw and st*_raw macros are now only used within the code produced by cpu_ldst_template.h, and only in three places. Expand these out to just call the ld_p and st_p functions directly. Note that in all the callsites the address argument is a uintptr_t, so we can drop that part of the double-cast used in the saddr() and laddr() macros. Signed-off-by: Peter Maydell --- include/exec/cpu_ldst_template.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/include/exec/cpu_ldst_template.h b/include/exec/cpu_ldst_template.h index 006093a..3b53605 100644 --- a/include/exec/cpu_ldst_template.h +++ b/include/exec/cpu_ldst_template.h @@ -79,7 +79,7 @@ glue(glue(cpu_ld, USUFFIX), MEMSUFFIX)(CPUArchState *env, target_ulong ptr) res = glue(glue(helper_ld, SUFFIX), MMUSUFFIX)(env, addr, mmu_idx); } else { uintptr_t hostaddr = addr + env->tlb_table[mmu_idx][page_index].addend; - res = glue(glue(ld, USUFFIX), _raw)(hostaddr); + res = glue(glue(ld, USUFFIX), _p)((uint8_t *)hostaddr); } return res; } @@ -101,7 +101,7 @@ glue(glue(cpu_lds, SUFFIX), MEMSUFFIX)(CPUArchState *env, target_ulong ptr) MMUSUFFIX)(env, addr, mmu_idx); } else { uintptr_t hostaddr = addr + env->tlb_table[mmu_idx][page_index].addend; - res = glue(glue(lds, SUFFIX), _raw)(hostaddr); + res = glue(glue(lds, SUFFIX), _p)((uint8_t *)hostaddr); } return res; } @@ -127,7 +127,7 @@ glue(glue(cpu_st, SUFFIX), MEMSUFFIX)(CPUArchState *env, target_ulong ptr, glue(glue(helper_st, SUFFIX), MMUSUFFIX)(env, addr, v, mmu_idx); } else { uintptr_t hostaddr = addr + env->tlb_table[mmu_idx][page_index].addend; - glue(glue(st, SUFFIX), _raw)(hostaddr, v); + glue(glue(st, SUFFIX), _p)((uint8_t *)hostaddr, v); } } -- 1.9.1