public inbox for libc-help@sourceware.org
 help / color / mirror / Atom feed
* Re: About STATIC TLS in dl-open.c
       [not found]     ` <CAGLBsdCMMDu6JzAWFbYBEyVdqbDG-Bg4Fz_FOTBhNYgCegNMOA@mail.gmail.com>
@ 2019-12-30 14:35       ` Carlos O'Donell
  0 siblings, 0 replies; only message in thread
From: Carlos O'Donell @ 2019-12-30 14:35 UTC (permalink / raw)
  To: leo chen, libc-help

Leo,

I've adjusted the email address of libc-help so it makes it to the
list. My apologies
for the original typo in my email to you.

It may be possible to use LD_PRELOAD to specify all the shared object
and have them preloaded. Preloading all the objects you need may be
sufficient to force all the static TLS allocations to be carried out
early and immediately.

The fix (though I believe some issues remain) for the DTV issues was
introduced in glibc 2.19. Therefore if possible it would be best to
upgrade to a distribution that includes glibc 2.19 or newer.

On Fri, Dec 27, 2019 at 11:00 AM leo chen <izhiqiu.chen@gmail.com> wrote:
>
> Sorry, I think I may made a mistake when counting the DSOs, please dismiss last email.
> Regards.
>
> leo chen <izhiqiu.chen@gmail.com> 于2019年12月27日周五 下午11:50写道:
>>
>> Thanks, Carlos.
>>
>> I found some duplicate DSOs in the  log generated by straxce.
>> I mean, if I do not 'sort -u' to remove duplicates, the result is as follows.
>>
>>> lib64/libm.so.6
>>> lib64/libpthread.so.0
>>> lib64/libresolv.so.2
>>> lib64/librt.so.1
>>> lib64/libutil.so.1
>>> readelf -a -W libc.so.6
>>> usr/lib64/libgomp.so.1
>>> lib64/libpthread.so.0
>>> lib64/libutil.so.1
>>> lib64/libm.so.6
>>> libc.so.6
>>> lib64/libresolv.so.2
>>> lib64/librt.so.1
>>> usr/lib64/libgomp.so.1
>>
>>
>> which is 14 modules, exactly.
>>
>> And I wonder if there is any way to fix it, neither upgrade glibc nor increase DTV_SURPLUS.
>> For example, maybe change the loading order?
>>
>> Again, thanks for your help, and thanks glibc developers.
>>
>> leo
>>
>>
>> Carlos O'Donell <carlos@systemhalted.org> 于2019年12月27日周五 下午11:24写道:
>>>
>>> On Fri, Dec 27, 2019 at 10:18 AM leo chen <izhiqiu.chen@gmail.com> wrote:
>>> > I got a problem when loading a dynamic .so in python, the error message says,
>>> > "dlopen: cannot load any more object with static TLS".
>>> > The glibc is 2.18.
>>>
>>> Leo,
>>>
>>> Please email libc-help@soureceware.org with your question so others
>>> can see and help you out!
>>>
>>> Cheers,
>>> Carlos.

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2019-12-30 14:35 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <CAGLBsdAr1ji9Vqxece+RyzP6P+qkpxi2VaSZ3PRobLsud6Fi2w@mail.gmail.com>
     [not found] ` <CAE2sS1jjtpD5chRj4FvPyyayXQC7vrOovo=ezkC2u9K0JSf_jQ@mail.gmail.com>
     [not found]   ` <CAGLBsdDjqe5tJvm6Kt0G9F9xPY3MESj+NHiFeRdTYUr+p1J=9A@mail.gmail.com>
     [not found]     ` <CAGLBsdCMMDu6JzAWFbYBEyVdqbDG-Bg4Fz_FOTBhNYgCegNMOA@mail.gmail.com>
2019-12-30 14:35       ` About STATIC TLS in dl-open.c Carlos O'Donell

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).