develooper Front page | perl.perl5.porters | Postings from March 2003

5.8.1@19053: crypt_r() takes 128K per thread

Thread Previous | Thread Next
Jarkko Hietaniemi
March 31, 2003 23:04
5.8.1@19053: crypt_r() takes 128K per thread
Message ID:
> The support of crypt_r() in a threaded perl allocates a struct
> crypt_data in each interpreter.  This struct takes 128K;

... in OS/2, that is.  Usually I've seen that to be in the range of
few hundred bytes.  But, wow, anyway.  That's definitely a lot.  Maybe
the IBM programmers took their task a bit too seriously :-)

> this is a very significant part of the overhead of each new created
> interpreter.  Do we want such an overhead on a remote chance of
> crypt() being used?

No, we don't.

> Is not it better to allocate it JIT, or just create a mutex?

The on-demand solution feels better (if there's a crypt_r, I assume
the platform designers assumed you would be using it).  I'll see what
I can do.

Jarkko Hietaniemi <> "There is this special
biologist word we use for 'stable'.  It is 'dead'." -- Jack Cohen

Thread Previous | Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About