This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Fix solib-disc.exp regression with x86 gdbserver


On Mon, Apr 12, 2010 at 12:45 AM, Pedro Alves <pedro@codesourcery.com> wrote:
> On Sunday 11 April 2010 22:12:08, H.J. Lu wrote:
>> This patch breaks gdbserver on AVX. We have
>>
>> 1. Connect from GDB with XML support:
>> ? ? ? gdbserver enables XML support.
>> 2. Disconnect.
>> 3. Reconnect from any GDB
>> ? ? ? ?a. gdberver assumes GDB doesn't support XML sets to
>> ? ? ? ? ? target to Linux without AVX.
>> ? ? ? ?b. Gdbserver ?aborts when it tries to invalidate regcache
>> ? ? ? ? ? ?since the target doesn't support AVX registers.
>>
>> I will try to fix it.
>>
>
> Then, this means we're invalidating the regcache too late.
> We're flushing the old regcache contents to the threads, that were
> created using the previous gdb's register layout, but we're flushing
> the data using the _new_ register cache layout and low target
> methods. ?That sounds wrong indeed.
>
> I think this would help. ?Or is this still too late?
>
> --
> Pedro Alves
>
> 2010-04-12 ?Pedro Alves ?<pedro@codesourcery.com>
>
> ? ? ? ?gdb/gdbserver/
> ? ? ? ?* regcache.c (set_register_cache): Invalidate regcaches before
> ? ? ? ?changing the register cache layout.
> ? ? ? ?(regcache_invalidate_one): Allow a NULL regcache.
> ? ? ? ?* linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
> ? ? ? ?regcaches before changing the register cache layout or the target
> ? ? ? ?regsets.
>

It works.

Thanks.


-- 
H.J.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]