This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
relocation table
- From: flowher <krzysiek at leeds dot pl>
- To: binutils at sourceware dot org
- Date: Fri, 30 Apr 2010 00:33:48 +0200
- Subject: relocation table
Hello,
I'm trying to improvement application startup time. My application has
many processes which are the same binary. One question recently came to
my mind and I can't sleep well because of that.
I'm wondering why relocation table for shared library is not shared
between two the same processes (in a sens that binary is the same)?
If the same binary is executed twice, why symbol resolution and
relocation is done in each case? What could happen if relocation is done
only once and then it is somehow delivered to the process which starts a
s a second one?
And one more question. Let say that we are in the situation where we
start process, this process loads shared library (dlopen) and then it
forks and it clones himself (so that in the end we have two processes
which are the same binary). In such situation is symbol resolution and
relocation done by the second process also?
Thanks a lot
Kris