[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v5 02/55] trace: add mmu_index to mem_info
From: |
Alex Bennée |
Subject: |
Re: [PATCH v5 02/55] trace: add mmu_index to mem_info |
Date: |
Tue, 15 Oct 2019 12:15:31 +0100 |
User-agent: |
mu4e 1.3.5; emacs 27.0.50 |
Richard Henderson <address@hidden> writes:
> On 10/14/19 3:48 AM, Alex Bennée wrote:
>> diff --git a/accel/tcg/cputlb.c b/accel/tcg/cputlb.c
>> index defc8d5929..1210d8f243 100644
>> --- a/accel/tcg/cputlb.c
>> +++ b/accel/tcg/cputlb.c
>> @@ -1811,6 +1811,7 @@ void helper_be_stq_mmu(CPUArchState *env, target_ulong
>> addr, uint64_t val,
>> #define ATOMIC_MMU_DECLS
>> #define ATOMIC_MMU_LOOKUP atomic_mmu_lookup(env, addr, oi, retaddr)
>> #define ATOMIC_MMU_CLEANUP
>> +#define ATOMIC_MMU_IDX oi
>
> That is not the mmu_idx. That's the whole mmu_idx + MemOp combo.
> Use get_mmuidx(oi).
Oops I missed that from last time. Fixing it for real now!
>
>> --- a/accel/tcg/user-exec.c
>> +++ b/accel/tcg/user-exec.c
>> @@ -751,6 +751,7 @@ static void *atomic_mmu_lookup(CPUArchState *env,
>> target_ulong addr,
>> #define ATOMIC_MMU_DECLS do {} while (0)
>> #define ATOMIC_MMU_LOOKUP atomic_mmu_lookup(env, addr, DATA_SIZE, GETPC())
>> #define ATOMIC_MMU_CLEANUP do { clear_helper_retaddr(); } while (0)
>> +#define ATOMIC_MMU_IDX 0
>
> MMU_USER_IDX. Best to be consistent, even if this is user-only and it isn't
> really used.
>
>> --- a/include/exec/cpu_ldst_useronly_template.h
>> +++ b/include/exec/cpu_ldst_useronly_template.h
>> @@ -73,7 +73,7 @@ glue(glue(cpu_ld, USUFFIX), MEMSUFFIX)(CPUArchState *env,
>> abi_ptr ptr)
>> #else
>> trace_guest_mem_before_exec(
>> env_cpu(env), ptr,
>> - trace_mem_build_info(SHIFT, false, MO_TE, false));
>> + trace_mem_build_info(SHIFT, false, MO_TE, false, 0));
>
> Likewise for the other uses in this file.
Fixed.
>
>
> r~
--
Alex Bennée
- [PATCH for 4.2 v5 00/55] Support for TCG plugins, Alex Bennée, 2019/10/14
- [PATCH v5 01/55] trace: expand mem_info:size_shift to 4 bits, Alex Bennée, 2019/10/14
- [PATCH v5 04/55] translate-all: use cpu_in_exclusive_work_context() in tb_flush, Alex Bennée, 2019/10/14
- [PATCH v5 05/55] docs/devel: add plugins.rst design document, Alex Bennée, 2019/10/14
- [PATCH v5 03/55] cpu: introduce cpu_in_exclusive_context(), Alex Bennée, 2019/10/14
- [PATCH v5 06/55] configure: add --enable-plugins (MOVE TO END), Alex Bennée, 2019/10/14
- [PATCH v5 02/55] trace: add mmu_index to mem_info, Alex Bennée, 2019/10/14
- [PATCH v5 09/55] plugin: add implementation of the api, Alex Bennée, 2019/10/14
- [PATCH v5 10/55] queue: add QTAILQ_REMOVE_SEVERAL, Alex Bennée, 2019/10/14
- [PATCH v5 07/55] plugin: add user-facing API, Alex Bennée, 2019/10/14
- [PATCH v5 11/55] cputlb: document get_page_addr_code, Alex Bennée, 2019/10/14
- [PATCH v5 24/55] target/arm: fetch code with translator_ld, Alex Bennée, 2019/10/14
- [PATCH v5 22/55] plugin-gen: add plugin_insn_append, Alex Bennée, 2019/10/14
- [PATCH v5 15/55] atomic_template: add inline trace/plugin helpers, Alex Bennée, 2019/10/14
- [PATCH v5 20/55] *-user: plugin syscalls, Alex Bennée, 2019/10/14
- [PATCH v5 25/55] target/ppc: fetch code with translator_ld, Alex Bennée, 2019/10/14
- [PATCH v5 12/55] cputlb: introduce get_page_addr_code_hostp, Alex Bennée, 2019/10/14