Provided you don't run out of extra static TLS space this should work,
but it's wholly unnecessary and not how things are supposed to be done.
Fixes: 4b1859c0e943 ("Add support for RISC-V architecture.")
MFC after: 1 week
Differential D50563
rtld-elf/riscv: Don't allocate static TLS for dynamic TLS jrtc27 on May 28 2025, 1:21 AM. Authored by Tags None Referenced Files
Details
Provided you don't run out of extra static TLS space this should work, Fixes: 4b1859c0e943 ("Add support for RISC-V architecture.")
Diff Detail
Event TimelineComment Actions Indeed this is not how things are supposed to work. At least on x86, this is how things are. There are vendor libs linked with static TLS model, which happens to be dynamically loaded, and people really want that to work. The libs cannot be recompiled (they come from nvidia). If you want to keep risc-v "pure", it is up to you. Comment Actions It'd be nice if we hadn't gone down that road, but every arch seems to be supporting the extra static TLS space, RISC-V included, so I'm leaving that in for TPREL64, it's not that big a deal (though the infrastructure to support distributing static TLS out to other threads is quite horrifying) |