At 5:48 PM +0100 1/20/04, Leopold Toetsch wrote:
To estimate the costs of shared PMCs I have run this program[1], once with .Ref and once with .SharedRef.

There are 2 major issues:
1) PMC initialization (new_p_ic_p): The shared PMC needs additionally the allocation of the synchronize structure and the MUTEX_INIT.

This is a one-time cost. If a PMC has one, it should stick around after the PMC is destroyed and put on the free list.


2) PMC access (set_p_i): locking/unlocking the mutex
with SharedRef
  905  set_p_i                100000    0.049269      0.0005

with Ref
  905  set_p_i                100000    0.011356      0.0001

Yeah, that's about right. There is, unfortunately, little to be done about it. -- Dan

--------------------------------------"it's like this"-------------------
Dan Sugalski                          even samurai
[EMAIL PROTECTED]                         have teddy bears and even
                                      teddy bears get drunk

Reply via email to