lkml.org 
[lkml]   [2005]   [Jul]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectSlowdown with randomize_va_space in 2.6.12.2

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
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-07-06 21:51    [W:0.059 / U:0.308 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site