Thread overview
[Issue 20430] [Regression 2.089.0] DLL Runtime.terminate() hangs
Dec 04, 2019
Radu Racariu
Dec 12, 2019
Radu Racariu
Dec 14, 2019
Rainer Schuetze
Jun 04, 2023
Walter Bright
December 04, 2019
https://issues.dlang.org/show_bug.cgi?id=20430

--- Comment #1 from Radu Racariu <radu.racariu@gmail.com> ---
The bad output got truncated, looks like:

`
Start loading.
Start Dynamic Link...
DLL_PROCESS_ATTACH
End...
DLL_THREAD_ATTACH
DLL_THREAD_ATTACH
DLL_THREAD_ATTACH
DLL_THREAD_ATTACH
DLL_THREAD_ATTACH
DLL_THREAD_ATTACH
DLL_THREAD_ATTACH
DLL_THREAD_ATTACH
DLL_THREAD_ATTACH
DLL_THREAD_ATTACH
DLL_THREAD_ATTACH
DLL_THREAD_ATTACH
DLL_THREAD_DETACH
DLL_THREAD_DETACH
DLL_THREAD_DETACH
DLL_THREAD_DETACH
DLL_THREAD_DETACH
DLL_THREAD_DETACH
DLL_THREAD_DETACH
DLL_THREAD_DETACH
DLL_THREAD_DETACH
DLL_THREAD_DETACH
DLL_THREAD_DETACH
DLL_PROCESS_DETACH
`

--
December 12, 2019
https://issues.dlang.org/show_bug.cgi?id=20430

--- Comment #4 from Radu Racariu <radu.racariu@gmail.com> ---
That was using a sample form https://wiki.dlang.org/Win32_DLLs_in_D#D_code_calling_D_code_in_DLLs

Maybe that needs fixing.

--
December 14, 2019
https://issues.dlang.org/show_bug.cgi?id=20430

--- Comment #5 from Rainer Schuetze <r.sagitario@gmx.de> ---
> https://wiki.dlang.org/Win32_DLLs_in_D#D_code_calling_D_code_in_DLLs

IMO the gcProxy approach is so limited (no multi-threading, no sharing of other resources) that we should rather remove that section or add a large flashing warning at the top. We need something like https://dconf.org/2016/talks/thaut.html to support sharing the runtime across DLLs.

If someone actually uses the gcProxy, a simple fix should be to disable parallel marking by adding this line

extern (C) __gshared string[] rt_options = ["gcopt=parallel:0"];

--
June 04, 2023
https://issues.dlang.org/show_bug.cgi?id=20430

Walter Bright <bugzilla@digitalmars.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |dll
                 CC|                            |bugzilla@digitalmars.com

--