This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
[pushed] Add readahead cache to gdb's vFile:pread (Re: [PATCH 0/2] Better handling of slow remote transfers)
- From: Pedro Alves <palves at redhat dot com>
- To: Gary Benson <gbenson at redhat dot com>
- Cc: Sandra Loosemore <sandra at codesourcery dot com>, Joel Brobecker <brobecker at adacore dot com>, Doug Evans <dje at google dot com>, Jan Kratochvil <jan dot kratochvil at redhat dot com>, gdb-patches <gdb-patches at sourceware dot org>, André Pönitz <apoenitz at t-online dot de>, Paul Koning <Paul_Koning at dell dot com>
- Date: Fri, 21 Aug 2015 10:34:32 +0100
- Subject: [pushed] Add readahead cache to gdb's vFile:pread (Re: [PATCH 0/2] Better handling of slow remote transfers)
- Authentication-results: sourceware.org; auth=none
- References: <20150814182648 dot GO22245 at adacore dot com> <55CE6AA3 dot 8000300 at codesourcery dot com> <20150816184913 dot GA2998 at adacore dot com> <20150817085310 dot GC25320 at blade dot nx> <55D1EE96 dot 9060202 at codesourcery dot com> <20150818095858 dot GB9815 at blade dot nx> <55D3625B dot 40101 at codesourcery dot com> <55D3DB83 dot 4050204 at redhat dot com> <20150819134242 dot GA18586 at blade dot nx> <55D5E84E dot 5060303 at redhat dot com> <20150820180122 dot GA15604 at blade dot nx>
On 08/20/2015 07:01 PM, Gary Benson wrote:
> Pedro Alves wrote:
>> Hey, that was a quick and dirty patch. :-)
>
> I know, no worries :)
>
>> Here's a cleaned up version. WDYT?
> [snip
>> This patch almost halves the time it takes to "target remote + run
>> to main" on a higher-latency connection.
>>
>> E.g., I've got a ping time of ~85ms to an x86-64 machine on the gcc
>> compile farm (almost 2000km away from me), and I'm behind a ~16Mbit
>> ADSL. When I connect to a gdbserver debugging itself on that machine
>> and run to main, it takes almost 55 seconds:
> [snip]
>> real 0m54.803s
>> user 0m0.329s
>> sys 0m0.064s
>>
>> While the readahead cache added by this patch, it drops to:
>>
>> real 0m29.462s
>> user 0m0.454s
>> sys 0m0.054s
>>
>> I added a few counters to show cache hit/miss, and got:
>>
>> readahead cache miss 142
>> readahead cache hit 310
>>
>> Tested on x86_64 Fedora 20.
>
> Very nice, please commit!
Pushed, master and 7.10.
Thanks,
Pedro Alves