aboutsummaryrefslogtreecommitdiff
path: root/libphobos/libdruntime/gcc/sections/elf.d
diff options
context:
space:
mode:
Diffstat (limited to 'libphobos/libdruntime/gcc/sections/elf.d')
-rw-r--r--libphobos/libdruntime/gcc/sections/elf.d12
1 files changed, 2 insertions, 10 deletions
diff --git a/libphobos/libdruntime/gcc/sections/elf.d b/libphobos/libdruntime/gcc/sections/elf.d
index 1a3ff40..bbebedf 100644
--- a/libphobos/libdruntime/gcc/sections/elf.d
+++ b/libphobos/libdruntime/gcc/sections/elf.d
@@ -162,17 +162,10 @@ private:
}
/****
- * Boolean flag set to true while the runtime is initialized.
- */
-__gshared bool _isRuntimeInitialized;
-
-
-/****
* Gets called on program startup just before GC is initialized.
*/
void initSections() nothrow @nogc
{
- _isRuntimeInitialized = true;
}
@@ -181,7 +174,6 @@ void initSections() nothrow @nogc
*/
void finiSections() nothrow @nogc
{
- _isRuntimeInitialized = false;
}
alias ScanDG = void delegate(void* pbeg, void* pend) nothrow;
@@ -482,7 +474,7 @@ extern(C) void _d_dso_registry(CompilerDSOData* data)
}
// don't initialize modules before rt_init was called (see Bugzilla 11378)
- if (_isRuntimeInitialized)
+ if (isRuntimeInitialized())
{
registerGCRanges(pdso);
// rt_loadLibrary will run tls ctors, so do this only for dlopen
@@ -497,7 +489,7 @@ extern(C) void _d_dso_registry(CompilerDSOData* data)
*data._slot = null;
// don't finalizes modules after rt_term was called (see Bugzilla 11378)
- if (_isRuntimeInitialized)
+ if (isRuntimeInitialized())
{
// rt_unloadLibrary already ran tls dtors, so do this only for dlclose
immutable runTlsDtors = !_rtLoading;