[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Mon, 03 Mar 2014 18:31:45 +0900
From: Masami Hiramatsu <masami.hiramatsu.pt@...achi.com>
To: Andi Kleen <andi@...stfloor.org>
Cc: linux-kernel@...r.kernel.org, Ingo Molnar <mingo@...nel.org>,
Ananth N Mavinakayanahalli <ananth@...ibm.com>,
Sandeepa Prabhu <sandeepa.prabhu@...aro.org>,
Frederic Weisbecker <fweisbec@...il.com>, x86@...nel.org,
Steven Rostedt <rostedt@...dmis.org>, fche@...hat.com,
mingo@...hat.com, systemtap@...rceware.org,
"H. Peter Anvin" <hpa@...or.com>,
Thomas Gleixner <tglx@...utronix.de>
Subject: Re: Re: [PATCH -tip v7 24/26] kprobes: Enlarge hash table to 4096
entries
(2014/02/28 7:22), Masami Hiramatsu wrote:
> (2014/02/28 6:45), Andi Kleen wrote:
>> Masami Hiramatsu <masami.hiramatsu.pt@...achi.com> writes:
>>
>>> Currently, since the kprobes expects to be used
>>> with less than 100 probe points, its hash table
>>> just has 64 entries. This is too little to handle
>>> several thousands of probes.
>>> Enlarge this to 4096 entires which just consumes
>>> 32KB (on 64bit arch) for better scalability.
>>
>> 32K for a debug feature that most systems never use seems
>> too large to me.
>>
>> First can you check if smaller hash tables work too
>> (perhaps with a better hash, like jhash)
>
> I doubt jhash helps it, but yes, at least the various size
> should be tested.
Here, I tested the hash table performance with 2^6 to 2^12.
Cycles% of get_kprobe with 10k probes:
Size Cycles%
2^6 95.58%
2^7 85.83%
2^8 68.43%
2^9 48.61%
2^10 46.95%
2^11 48.46%
2^12 56.95%
So, we can see the hash table larger than 2^9 (512 entries,
which consumes 4KB) has no performance improvement.
Would you think 4kB is still big for kprobes? :)
Thank you,
--
Masami HIRAMATSU
IT Management Research Dept. Linux Technology Center
Hitachi, Ltd., Yokohama Research Laboratory
E-mail: masami.hiramatsu.pt@...achi.com
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists