[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [RFC 6/7] linux-user: don't clone watchpoints
From: |
Paolo Bonzini |
Subject: |
Re: [Qemu-devel] [RFC 6/7] linux-user: don't clone watchpoints |
Date: |
Fri, 17 Jun 2016 19:18:05 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.1.0 |
On 17/06/2016 18:33, Alex Bennée wrote:
> The watchpoint code is stubbed out for CONFIG_USER_ONLY so there is no
> point attempting to copy the data here. Lets remove the code before the
> RCU protection goes in.
>
> Signed-off-by: Alex Bennée <address@hidden>
> ---
> linux-user/main.c | 8 --------
> 1 file changed, 8 deletions(-)
>
> diff --git a/linux-user/main.c b/linux-user/main.c
> index 2901626..9a5d017 100644
> --- a/linux-user/main.c
> +++ b/linux-user/main.c
> @@ -3812,14 +3812,6 @@ CPUArchState *cpu_copy(CPUArchState *env)
> Note: Once we support ptrace with hw-debug register access, make sure
> BP_CPU break/watchpoints are handled correctly on clone. */
> cpu_breakpoints_clone(cpu, new_cpu);
> - if (unlikely(cpu->watchpoints) && unlikely(cpu->watchpoints->len)) {
> - CPUWatchpoint *wp;
> - int i;
> - for (i = 0; i < cpu->watchpoints->len; i++) {
> - wp = &g_array_index(cpu->watchpoints, CPUWatchpoint, i);
> - cpu_watchpoint_insert(new_cpu, wp->vaddr, wp->len, wp->flags);
> - }
> - }
>
> return new_env;
> }
>
Hmm, I am not sure. It's still the correct thing to do.
Paolo
- [Qemu-devel] [RFC 0/7] Safe watch and breakpoint manipulation, Alex Bennée, 2016/06/17
- [Qemu-devel] [RFC 1/7] cpu: move break/watchpoints into arrays., Alex Bennée, 2016/06/17
- [Qemu-devel] [RFC 5/7] breakpoints: put breakpoints under RCU control, Alex Bennée, 2016/06/17
- [Qemu-devel] [RFC 3/7] exec: keep CPUBreakpoint references internal, Alex Bennée, 2016/06/17
- [Qemu-devel] [RFC 6/7] linux-user: don't clone watchpoints, Alex Bennée, 2016/06/17
- Re: [Qemu-devel] [RFC 6/7] linux-user: don't clone watchpoints,
Paolo Bonzini <=
- [Qemu-devel] [RFC 4/7] break/watchpoints: store inside array, Alex Bennée, 2016/06/17
- [Qemu-devel] [RFC 2/7] exec: keep CPUWatchpoint references internal, Alex Bennée, 2016/06/17
- [Qemu-devel] [RFC 7/7] watchpoints: put watchpoints under RCU control, Alex Bennée, 2016/06/17
- Re: [Qemu-devel] [RFC 0/7] Safe watch and breakpoint manipulation, Paolo Bonzini, 2016/06/17