public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* Slowdown with randomize_va_space in 2.6.12.2
@ 2005-07-06 14:23 Paulo Marques
  2005-07-06 19:57 ` David S. Miller
  0 siblings, 1 reply; 15+ messages in thread
From: Paulo Marques @ 2005-07-06 14:23 UTC (permalink / raw)
  To: linux-kernel


Hi, all

I have a bash script that calls a small application several times 
(around 50 calls) that just send and receives data through an already 
open tcp socket to a local server through the loopback device. It also 
launches another small app several times that just reads a small file 
from disk and does some processing on it in memory.

We noticed a severe performance regression on this application under 
kernel 2.6.12.2 that we tracked down to the address space randomization 
patches:

# echo 0 > randomize_va_space
# time ./script
real    0m0.671s
user    0m0.293s
sys     0m0.325s

# echo 1 > randomize_va_space
# time ./script
real    0m3.310s
user    0m2.712s
sys     0m0.401s

Notice that the real time is 5x slower with "randomize_va_space" turned 
on. This is on a Transmeta Crusoe TM5600 at 533MHz.

What is weird is that most of the extra time is being accounted as 
user-space time, but the user-space application is exactly the same in 
both runs, only the "randomize_va_space" parameter changed.

I browsed the randomization patch code and I don't think the random 
calculations themselves could account for all that time.

Does anybody have a clue as to why this is happening or what I should do 
to debug this further?

-- 
Paulo Marques - www.grupopie.com

It is a mistake to think you can solve any major problems
just with potatoes.
Douglas Adams

^ permalink raw reply	[flat|nested] 15+ messages in thread

end of thread, other threads:[~2005-07-31 10:11 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-07-06 14:23 Slowdown with randomize_va_space in 2.6.12.2 Paulo Marques
2005-07-06 19:57 ` David S. Miller
2005-07-06 20:53   ` Dave Jones
2005-07-06 20:58     ` David S. Miller
2005-07-07  1:12     ` Andrew Morton
2005-07-07  2:07       ` David S. Miller
2005-07-07  4:11         ` pmarques
2005-07-07  6:37       ` Arjan van de Ven
2005-07-07  6:41         ` Andrew Morton
2005-07-07  6:46           ` Arjan van de Ven
2005-07-30  0:53         ` Eric Lammerts
2005-07-30  1:20           ` Andrew Morton
2005-07-30 11:49             ` Arjan van de Ven
2005-07-30 11:55             ` Arjan van de Ven
2005-07-06 21:00   ` Arjan van de Ven

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox