[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v3 13/18] target/arm: Update contiguous first-fault and no-fa
From: |
Richard Henderson |
Subject: |
Re: [PATCH v3 13/18] target/arm: Update contiguous first-fault and no-fault loads |
Date: |
Tue, 28 Apr 2020 08:02:01 -0700 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.7.0 |
On 4/27/20 11:38 AM, Peter Maydell wrote:
> I would suggest something like:
>
> + * From this point on, all memory operations are MemSingleNF.
> + *
> + * Per the MemSingleNF pseudocode, a no-fault load from Device memory
> + * must not actually hit the bus -- it returns (UNKNOWN, FAULT) instead.
> + *
> + * Unfortuately we do not have access to the memory attributes from the
> PTE
> + * to tell Device memory from Normal memory. So we make a mostly
> + * correct check, and indicate (UNKNOWN, FAULT) for any MMIO.
> + * This gives the right answer for the common cases of "Normal memory,
> + * backed by host RAM" and "Device memory, backed by MMIO".
> + * The architecture allows us to suppress an NF load and return
> + * (UNKNOWN, FAULT) for any reason), so our behaviour (indicate
> + * fault) for the corner case of "Normal memory, backed by MMIO" is
> + * permitted. The case we get wrong is "Device memory, backed by
> + * host RAM", which we should return (UNKNOWN, FAULT) for but do not.
> + *
> + * Similarly, CPU_BP breakpoints would raise exceptions, and so
> + * return (UNKNOWN, FAULT). For simplicity, we consider gdb and
> + * architectural breakpoints the same.
>
> assuming my understanding is correct...
Yep, thanks. I'll merge this text.
r~
- [PATCH v3 10/18] target/arm: Use SVEContLdSt in sve_ld1_r, (continued)
- [PATCH v3 10/18] target/arm: Use SVEContLdSt in sve_ld1_r, Richard Henderson, 2020/04/22
- [PATCH v3 12/18] target/arm: Use SVEContLdSt for multi-register contiguous loads, Richard Henderson, 2020/04/22
- [PATCH v3 07/18] target/arm: Drop manual handling of set/clear_helper_retaddr, Richard Henderson, 2020/04/22
- [PATCH v3 14/18] target/arm: Use SVEContLdSt for contiguous stores, Richard Henderson, 2020/04/22
- [PATCH v3 13/18] target/arm: Update contiguous first-fault and no-fault loads, Richard Henderson, 2020/04/22
[PATCH v3 15/18] target/arm: Reuse sve_probe_page for gather first-fault loads, Richard Henderson, 2020/04/22
[PATCH v3 16/18] target/arm: Reuse sve_probe_page for scatter stores, Richard Henderson, 2020/04/22
[PATCH v3 18/18] target/arm: Remove sve_memopidx, Richard Henderson, 2020/04/22
[PATCH v3 11/18] target/arm: Handle watchpoints in sve_ld1_r, Richard Henderson, 2020/04/22
[PATCH v3 17/18] target/arm: Reuse sve_probe_page for gather loads, Richard Henderson, 2020/04/22
Re: [PATCH v3 00/18] target/arm: sve load/store improvements, no-reply, 2020/04/22