[rtems commit] libdl: Add support to import base image TLS symbols

Chris Johns chrisj at rtems.org
Thu Sep 14 07:38:19 UTC 2023


On 14/9/2023 5:20 pm, Sebastian Huber wrote:
> On 14.09.23 09:12, Chris Johns wrote:
>> On 14/9/2023 4:55 pm, Sebastian Huber wrote:
>>> On 14.09.23 08:34, Sebastian Huber wrote:
>>>> This seems to break the mips build:
>>>>
>>>> cpukit/libdl/rtl-tls.c:104:2: error: #error unsupported architecture
>>>>     104 | #error unsupported architecture
>>>>         |  ^~~~~
>>>>
>>> Also the moxie and 64-bit powerpc (qoriq_e6500_64) no longer build with the
>>> error above.
>> Yes. It was decided this be a hard error so it gets fixed. The newlib TLS change
>> broke libdl and it is being fixed for the release. I have done what I can and
>> know about but some archs need help from those who know about it.
> 
> An intentionally broken build is not really helpful.

Yes it is not ideal but leaving libdl broken with no one knowing is also not
helpful. We needed a circuit breaker.

> There are also other bugs left to fix, for example:
> 
> https://devel.rtems.org/ticket/4953
> 
> How can I check if my patches break the build if it is already broken?

Like I said it is not a prefect solution and we need to resolve this as a team.
I have done some of the hard work in libdl to get things under way but I need
help in the TLS score area.

>> I am not sure about moxie, if it does not have TLS support it can disabled.
> 
> moxie and mips don't have TLS support.
> 
>>
>> The issue I faced was no score interface to get the TLS base for a thread to
>> determine a symbol's offset. If we had that and something to say if TLS is
>> supported libdl would be easy to fix.
> 
> Why don't we add this interface if it simplifies things?

Yes please, that would be good. I do not know the TSL support well enough to do
a decent job of it.

Chris


More information about the devel mailing list