maria-developers team mailing list archive
-
maria-developers team
-
Mailing list archive
-
Message #04564
Re: something better than PMP
Arun Sharma <asharma@xxxxxx> writes:
> On 1/21/12 7:24 AM, Mark Callaghan wrote:
>> 1 millisecond per thread would be much better than what we experience
>> today.
>>
>
> Is there a reason why latency per-thread is more interesting than the
> absolute number?
You are right of course - the interesting number is the time we spent with the
target mysqld process suspended (stalled) under ptrace().
The reason I think in terms of latency-per-thread is this: Different mysqld
instances can have widely different number of threads - from a few handful to
perhaps thousands. Since we loop over threads while the process is
ptrace()-suspended, it seems a nice measure to estimate the cost independent
of number of threads in the process.
>>> Arun: What I've done so far is mostly to cache reads of the same word, and
>>> delay name resolve to after the target process is resumed. I think it can
>>> be
>>> made even faster by reading target process memory through /proc/PID/mem
>>> instead of ptrace and if we can reduce repeated reads of /proc/PID/maps
>>> and
>>> such.
>
> Sounds like a good optimization to have. There is already a cache
> internal to libunwind that maps a given IP address to it's unwind
> info. If the repeated reads come from that code path, tweaking the
> cache size might be a simpler fix.
Ok, that sounds cool!
- Kristian.