qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Richard Henderson <richard.henderson@linaro.org>
To: "Philippe Mathieu-Daudé" <philmd@linaro.org>, qemu-devel@nongnu.org
Cc: pierrick.bouvier@linaro.org
Subject: Re: [PATCH v2 09/42] include/exec: Inline *_data memory operations
Date: Tue, 1 Apr 2025 12:56:28 -0500	[thread overview]
Message-ID: <1205914e-b344-4f64-826e-416b5e491cc4@linaro.org> (raw)
In-Reply-To: <7b57e8c0-076b-44dc-859a-2829a68cf669@linaro.org>

On 4/1/25 01:24, Philippe Mathieu-Daudé wrote:
> On 18/3/25 22:31, Richard Henderson wrote:
>> These need to be per-target for 'abi_ptr'.  Expand inline to
>> the *_data_ra api with ra == 0.
>>
>> Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
>> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
>> ---
>>   include/exec/cpu_ldst.h     | 123 ++++++++++++++++++++++++++++++------
>>   accel/tcg/ldst_common.c.inc |  89 --------------------------
>>   2 files changed, 104 insertions(+), 108 deletions(-)
>>
>> diff --git a/include/exec/cpu_ldst.h b/include/exec/cpu_ldst.h
>> index a2a90c7554..d084da0b5f 100644
>> --- a/include/exec/cpu_ldst.h
>> +++ b/include/exec/cpu_ldst.h
>> @@ -74,25 +74,6 @@
>>   #include "user/guest-host.h"
>>   #endif /* CONFIG_USER_ONLY */
>> -uint32_t cpu_ldub_data(CPUArchState *env, abi_ptr ptr);
>> -int cpu_ldsb_data(CPUArchState *env, abi_ptr ptr);
>> -uint32_t cpu_lduw_be_data(CPUArchState *env, abi_ptr ptr);
>> -int cpu_ldsw_be_data(CPUArchState *env, abi_ptr ptr);
>> -uint32_t cpu_ldl_be_data(CPUArchState *env, abi_ptr ptr);
>> -uint64_t cpu_ldq_be_data(CPUArchState *env, abi_ptr ptr);
>> -uint32_t cpu_lduw_le_data(CPUArchState *env, abi_ptr ptr);
>> -int cpu_ldsw_le_data(CPUArchState *env, abi_ptr ptr);
>> -uint32_t cpu_ldl_le_data(CPUArchState *env, abi_ptr ptr);
>> -uint64_t cpu_ldq_le_data(CPUArchState *env, abi_ptr ptr);
>> -
>> -void cpu_stb_data(CPUArchState *env, abi_ptr ptr, uint32_t val);
>> -void cpu_stw_be_data(CPUArchState *env, abi_ptr ptr, uint32_t val);
>> -void cpu_stl_be_data(CPUArchState *env, abi_ptr ptr, uint32_t val);
>> -void cpu_stq_be_data(CPUArchState *env, abi_ptr ptr, uint64_t val);
>> -void cpu_stw_le_data(CPUArchState *env, abi_ptr ptr, uint32_t val);
>> -void cpu_stl_le_data(CPUArchState *env, abi_ptr ptr, uint32_t val);
>> -void cpu_stq_le_data(CPUArchState *env, abi_ptr ptr, uint64_t val);
>> -
>>   static inline uint32_t
>>   cpu_ldub_mmuidx_ra(CPUArchState *env, abi_ptr addr, int mmu_idx, uintptr_t ra)
>>   {
>> @@ -342,6 +323,110 @@ cpu_stq_le_data_ra(CPUArchState *env, abi_ptr addr, uint64_t val, 
>> uintptr_t ra)
>>       cpu_stq_le_mmuidx_ra(env, addr, val, mmu_index, ra);
>>   }
>> +/*--------------------------*/
>> +
>> +static inline uint32_t
> 
> Pre-existing, but why don't we use 'unsigned int' like for the signed
> variants, or the plain int8_t type?

It's the original type used by the api.

You'd never change this.  If you want to audit all of the uses vs the api change, you'd 
update to one of the newer function groups.


r~


  reply	other threads:[~2025-04-01 17:57 UTC|newest]

Thread overview: 90+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-03-18 21:31 [PATCH v2 00/42] accel/tcg, codebase: Build once patches Richard Henderson
2025-03-18 21:31 ` [PATCH v2 01/42] accel/tcg: Build user-exec-stub.c once Richard Henderson
2025-03-18 21:31 ` [PATCH v2 02/42] accel/tcg: Build plugin-gen.c once Richard Henderson
2025-03-18 21:31 ` [PATCH v2 03/42] accel/tcg: Fix cpu_ld*_code_mmu for user mode Richard Henderson
2025-03-18 23:52   ` Pierrick Bouvier
2025-03-19  1:05     ` Richard Henderson
2025-03-19  1:08       ` Pierrick Bouvier
2025-03-19  1:09   ` Pierrick Bouvier
2025-03-18 21:31 ` [PATCH v2 04/42] include/exec: Use vaddr for *_mmu guest memory access routines Richard Henderson
2025-03-18 21:31 ` [PATCH v2 05/42] include/exec: Split out cpu-ldst-common.h Richard Henderson
2025-03-18 21:31 ` [PATCH v2 06/42] include/exec: Split out cpu-mmu-index.h Richard Henderson
2025-03-19  0:02   ` Pierrick Bouvier
2025-03-19  1:16     ` Richard Henderson
2025-03-19 17:16       ` Pierrick Bouvier
2025-03-20 14:58         ` Richard Henderson
2025-03-20 15:13           ` Pierrick Bouvier
2025-04-02 11:26   ` Philippe Mathieu-Daudé
2025-04-02 18:33     ` Richard Henderson
2025-04-02 20:14       ` Philippe Mathieu-Daudé
2025-03-18 21:31 ` [PATCH v2 07/42] include/exec: Inline *_mmuidx_ra memory operations Richard Henderson
2025-03-18 21:31 ` [PATCH v2 08/42] include/exec: Inline *_data_ra " Richard Henderson
2025-03-18 21:31 ` [PATCH v2 09/42] include/exec: Inline *_data " Richard Henderson
2025-04-01  6:24   ` Philippe Mathieu-Daudé
2025-04-01 17:56     ` Richard Henderson [this message]
2025-03-18 21:31 ` [PATCH v2 10/42] include/exec: Inline *_code " Richard Henderson
2025-03-18 21:31 ` [PATCH v2 11/42] accel/tcg: Perform aligned atomic reads in translator_ld Richard Henderson
2025-03-19  0:05   ` Alistair Francis
2025-03-19  0:15   ` Pierrick Bouvier
2025-03-19  1:28     ` Richard Henderson
2025-03-19 17:18       ` Pierrick Bouvier
2025-03-19 17:18   ` Pierrick Bouvier
2025-04-01  6:18   ` Philippe Mathieu-Daudé
2025-03-18 21:31 ` [PATCH v2 12/42] accel/tcg: Use cpu_ld*_code_mmu in translator.c Richard Henderson
2025-03-19  0:23   ` Pierrick Bouvier
2025-03-21  0:48     ` Richard Henderson
2025-03-21 18:03       ` Pierrick Bouvier
2025-03-18 21:31 ` [PATCH v2 13/42] accel/tcg: Implement translator_ld*_end Richard Henderson
2025-03-18 21:31 ` [PATCH v2 14/42] accel/tcg: Remove mmap_lock/unlock from watchpoint.c Richard Henderson
2025-03-18 21:31 ` [PATCH v2 15/42] include/exec: Split out mmap-lock.h Richard Henderson
2025-03-31 22:05   ` Pierrick Bouvier
2025-03-31 22:07     ` Pierrick Bouvier
2025-03-18 21:31 ` [PATCH v2 16/42] include/system: Move exec/memory.h to system/memory.h Richard Henderson
2025-03-18 21:31 ` [PATCH v2 17/42] include/system: Move exec/address-spaces.h to system/address-spaces.h Richard Henderson
2025-03-18 21:31 ` [PATCH v2 18/42] include/system: Move exec/ioport.h to system/ioport.h Richard Henderson
2025-03-18 21:31 ` [PATCH v2 19/42] include/system: Move exec/ram_addr.h to system/ram_addr.h Richard Henderson
2025-03-18 21:31 ` [PATCH v2 20/42] include/system: Move exec/ramblock.h to system/ramblock.h Richard Henderson
2025-03-18 21:31 ` [PATCH v2 21/42] accel/tcg: Remove unnecesary inclusion of memory-internal.h in cputlb.c Richard Henderson
2025-03-18 21:31 ` [PATCH v2 22/42] exec: Restrict memory-internal.h to system/ Richard Henderson
2025-03-18 21:31 ` [PATCH v2 23/42] meson: Introduce top-level libuser_ss and libsystem_ss Richard Henderson
2025-03-18 21:31 ` [PATCH v2 24/42] gdbstub: Move syscalls.c out of common_ss Richard Henderson
2025-03-18 21:31 ` [PATCH v2 25/42] accel/tcg: Use libuser_ss and libsystem_ss Richard Henderson
2025-03-18 21:31 ` [PATCH v2 26/42] semihosting: Move user-only implementation out-of-line Richard Henderson
2025-03-19  0:26   ` Pierrick Bouvier
2025-03-19  7:16   ` Philippe Mathieu-Daudé
2025-03-21  0:50     ` Richard Henderson
2025-03-31 22:01   ` Pierrick Bouvier
2025-03-18 21:31 ` [PATCH v2 27/42] target/mips: Restrict semihosting tests to system mode Richard Henderson
2025-03-19  0:26   ` Pierrick Bouvier
2025-03-18 21:31 ` [PATCH v2 28/42] target/xtensa: " Richard Henderson
2025-03-19  0:27   ` Pierrick Bouvier
2025-03-18 21:31 ` [PATCH v2 29/42] include/exec: Split out watchpoint.h Richard Henderson
2025-03-19  0:30   ` Pierrick Bouvier
2025-03-19  1:33     ` Richard Henderson
2025-03-18 21:31 ` [PATCH v2 30/42] hw/core: Move unconditional files to libsystem_ss, libuser_ss Richard Henderson
2025-03-18 21:31 ` [PATCH v2 31/42] system: Move most files to libsystem_ss Richard Henderson
2025-03-19  0:32   ` Pierrick Bouvier
2025-03-19  7:18   ` Philippe Mathieu-Daudé
2025-03-18 21:31 ` [PATCH v2 32/42] plugins: Move api.c, core.c to libuser_ss, libsystem_ss Richard Henderson
2025-03-19  0:32   ` Pierrick Bouvier
2025-03-18 21:31 ` [PATCH v2 33/42] include/exec: Drop ifndef CONFIG_USER_ONLY from cpu-common.h Richard Henderson
2025-03-18 21:31 ` [PATCH v2 34/42] include/hw/core: Drop ifndef CONFIG_USER_ONLY from cpu.h Richard Henderson
2025-03-18 21:32 ` [PATCH v2 35/42] include/hw/intc: Remove ifndef CONFIG_USER_ONLY from armv7m_nvic.h Richard Henderson
2025-03-19  0:33   ` Pierrick Bouvier
2025-03-18 21:32 ` [PATCH v2 36/42] include/hw/s390x: Remove ifndef CONFIG_USER_ONLY in css.h Richard Henderson
2025-03-18 21:32 ` [PATCH v2 37/42] include/exec: Split out icount.h Richard Henderson
2025-03-19  0:33   ` Pierrick Bouvier
2025-03-19  7:21     ` Philippe Mathieu-Daudé
2025-03-21  0:56       ` Richard Henderson
2025-03-18 21:32 ` [PATCH v2 38/42] include/exec: Protect icount_enabled from poisoned symbols Richard Henderson
2025-03-19  0:42   ` Pierrick Bouvier
2025-03-19  1:41     ` Richard Henderson
2025-03-18 21:32 ` [PATCH v2 39/42] include/system: Remove ifndef CONFIG_USER_ONLY in qtest.h Richard Henderson
2025-03-19  0:43   ` Pierrick Bouvier
2025-03-19  7:26   ` Philippe Mathieu-Daudé
2025-03-19 17:25     ` Pierrick Bouvier
2025-03-18 21:32 ` [PATCH v2 40/42] include/qemu: Remove ifndef CONFIG_USER_ONLY from accel.h Richard Henderson
2025-03-18 21:32 ` [PATCH v2 41/42] target/riscv: Remove ifndef CONFIG_USER_ONLY from cpu_cfg.h Richard Henderson
2025-03-19  1:41   ` Alistair Francis
2025-03-18 21:32 ` [PATCH v2 42/42] meson: Only allow CONFIG_USER_ONLY from certain source sets Richard Henderson
2025-03-19  0:44   ` Pierrick Bouvier

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1205914e-b344-4f64-826e-416b5e491cc4@linaro.org \
    --to=richard.henderson@linaro.org \
    --cc=philmd@linaro.org \
    --cc=pierrick.bouvier@linaro.org \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).