Possible tls bug on arm / microblaze
Sam Price
thesamprice at gmail.com
Wed Aug 24 15:17:17 UTC 2022
I modified cpukit/score/cpu/microblaze/__tls_get_addr.c
and added a printf
printf("TLS OFFSET %x %p %p %d",(uintptr_t) _TLS_Alignment,
tls_block,executing->Start.tls_area, ti->offset);
and then ran the splts* tests on my hardware.
The __tls_get_addr in the splts* tests.
*** BEGIN OF TEST SPTLS 1 ***
*** TEST VERSION: 6.0.0.0cb37ce45e81a2b030cbd99678a42884bc864f84
*** TEST STATE: EXPECTED_PASS
*** TEST BUILD: RTEMS_POSIX_API
*** TEST TOOLS: 10.3.1 20220622 (RTEMS 6, RSB
5a19dda19ffaaa43305af1f34597fd4d8165029b, Newlib 27fd806)
TLS item = 123
TLS item = 123
TLS item = 5
*** END OF TEST SPTLS 1 ***
[ RTEMS shutdown ]
RTEMS version: 6.0.0.0cb37ce45e81a2b030cbd99678a42884bc864f84
RTEMS tools: 10.3.1 20220622 (RTEMS 6, RSB
5a19dda19ffaaa43305af1f34597fd4d8165029b, Newlib 27fd806)
executing thread ID: 0x08a010001
executing thread name: UI1
*** BEGIN OF TEST SPTLS 2 ***
*** TEST VERSION: 6.0.0.0cb37ce45e81a2b030cbd99678a42884bc864f84
*** TEST STATE: EXPECTED_PASS
*** TEST BUILD: RTEMS_POSIX_API
*** TEST TOOLS: 10.3.1 20220622 (RTEMS 6, RSB
5a19dda19ffaaa43305af1f34597fd4d8165029b, Newlib 27fd806)
A::globalCounter() = 0
../../../testsuites/sptests/sptls02/init.cc: 168 extern_int == 7
[ RTEMS shutdown ]
RTEMS version: 6.0.0.0cb37ce45e81a2b030cbd99678a42884bc864f84
RTEMS tools: 10.3.1 20220622 (RTEMS 6, RSB
5a19dda19ffaaa43305af1f34597fd4d8165029b, Newlib 27fd806)
executing thread ID: 0x08a010001
executing thread name: UI1
RTEMS version: 6.0.0.0cb37ce45e81a2b030cbd99678a42884bc864f84
RTEMS tools: 10.3.1 20220622 (RTEMS 6, RSB
5a19dda19ffaaa43305af1f34597fd4d8165029b, Newlib 27fd806)
executing thread ID: 0x08a010001
executing thread name: UI1
*** BEGIN OF TEST SPTLS 3 ***
*** TEST VERSION: 6.0.0.0cb37ce45e81a2b030cbd99678a42884bc864f84
*** TEST STATE: EXPECTED_PASS
*** TEST BUILD: RTEMS_POSIX_API
*** TEST TOOLS: 10.3.1 20220622 (RTEMS 6, RSB
5a19dda19ffaaa43305af1f34597fd4d8165029b, Newlib 27fd806)
*** END OF TEST SPTLS 3 ***
[ RTEMS shutdown ]
RTEMS version: 6.0.0.0cb37ce45e81a2b030cbd99678a42884bc864f84
RTEMS tools: 10.3.1 20220622 (RTEMS 6, RSB
5a19dda19ffaaa43305af1f34597fd4d8165029b, Newlib 27fd806)
executing thread ID: 0x08a010001
executing thread name: UI1
*** BEGIN OF TEST SPTLS 4 ***
*** TEST VERSION: 6.0.0.0cb37ce45e81a2b030cbd99678a42884bc864f84
*** TEST STATE: EXPECTED_PASS
*** TEST BUILD: RTEMS_POSIX_API
*** TEST TOOLS: 10.3.1 20220622 (RTEMS 6, RSB
5a19dda19ffaaa43305af1f34597fd4d8165029b, Newlib 27fd806)
*** END OF TEST SPTLS 4 ***
[ RTEMS shutdown ]
RTEMS version: 6.0.0.0cb37ce45e81a2b030cbd99678a42884bc864f84
RTEMS tools: 10.3.1 20220622 (RTEMS 6, RSB
5a19dda19ffaaa43305af1f34597fd4d8165029b, Newlib 27fd806)
executing thread ID: 0x08a010001
executing thread name: UI1
On Tue, Jul 19, 2022 at 2:25 PM Sebastian Huber <
sebastian.huber at embedded-brains.de> wrote:
> On 19/07/2022 20:10, Sam Price wrote:
> >
> > Where would the ti->offset member be updated / initialized at?
>
> The caller of __tls_get_addr() has to do this. On ARM, this is function
> is normally not used.
>
> --
> embedded brains GmbH
> Herr Sebastian HUBER
> Dornierstr. 4
> 82178 Puchheim
> Germany
> email: sebastian.huber at embedded-brains.de
> phone: +49-89-18 94 741 - 16
> fax: +49-89-18 94 741 - 08
>
> Registergericht: Amtsgericht München
> Registernummer: HRB 157899
> Vertretungsberechtigte Geschäftsführer: Peter Rasmussen, Thomas Dörfler
> Unsere Datenschutzerklärung finden Sie hier:
> https://embedded-brains.de/datenschutzerklaerung/
>
--
Sincerely,
Sam Price
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rtems.org/pipermail/devel/attachments/20220824/c50ff94e/attachment-0001.htm>
More information about the devel
mailing list