Bug 10986 – thread_attachThis doesn't initialize shared libraries

Status
NEW
Severity
normal
Priority
P3
Component
druntime
Product
D
Version
D2
Platform
All
OS
All
Creation time
2013-09-07T10:00:47Z
Last change time
2024-12-07T13:32:55Z
Keywords
dll
Assigned to
No Owner
Creator
Martin Nowak
Moved to GitHub: dmd#17260 →

Comments

Comment #0 by code — 2013-09-07T10:00:47Z
I didn't tested this, but I just realized, that a foreign thread added through thread_attachThis has currently no way of knowing which DSOs it needs to initialize. So it'll likely end up not calling any thread ctors (static this();) at all.
Comment #1 by code — 2013-09-08T23:23:14Z
I thought about this and I think inheriting the loaded libraries of the main thread would be a sane behavior. The main thread is the one that runs D main or the one that dlopened druntime.
Comment #2 by robert.schadek — 2024-12-07T13:32:55Z
THIS ISSUE HAS BEEN MOVED TO GITHUB https://github.com/dlang/dmd/issues/17260 DO NOT COMMENT HERE ANYMORE, NOBODY WILL SEE IT, THIS ISSUE HAS BEEN MOVED TO GITHUB