aboutsummaryrefslogtreecommitdiff
path: root/libphobos/libdruntime/gcc
diff options
context:
space:
mode:
authorIain Buclaw <ibuclaw@gdcproject.org>2021-04-19 14:36:14 +0200
committerIain Buclaw <ibuclaw@gdcproject.org>2021-04-19 19:27:13 +0200
commitb66e72b43e1e8f402dc958ce3cca35f7c273340d (patch)
treef78d66de08d1529c625b16c2114ba42e4ef4d12e /libphobos/libdruntime/gcc
parentd86e60855f05a0e493f8362c12bfd40d5432d337 (diff)
downloadgcc-b66e72b43e1e8f402dc958ce3cca35f7c273340d.zip
gcc-b66e72b43e1e8f402dc958ce3cca35f7c273340d.tar.gz
gcc-b66e72b43e1e8f402dc958ce3cca35f7c273340d.tar.bz2
libphobos: Add D runtime support code for MinGW (PR99794)
libphobos/ChangeLog: PR d/99794 * libdruntime/Makefile.am (DRUNTIME_SOURCES_CONFIGURED): Add config/mingw/msvc.c on DRUNTIME_OS_MINGW. * libdruntime/Makefile.in: Regenerate. * libdruntime/config/mingw/msvc.c: New file. * libdruntime/config/mingw/switchcontext.S (fiber_switchContext): Fix function definition. * libdruntime/gcc/deh.d (__gdc_personality_seh0): Fix call to _GCC_specific_handler. * libdruntime/gcc/gthread.d (__gthread_once_t): Fix definition. * libdruntime/gcc/unwind/generic.d (_GCC_specific_handler): Fix declaration. * libdruntime/rt/dmain2.d (rt_loadLibrary): Remove function. (rt_loadLibraryW): Remove function. (initLibrary): Remove function. (rt_unloadLibrary): Remove function.
Diffstat (limited to 'libphobos/libdruntime/gcc')
-rw-r--r--libphobos/libdruntime/gcc/deh.d2
-rw-r--r--libphobos/libdruntime/gcc/gthread.d6
-rw-r--r--libphobos/libdruntime/gcc/unwind/generic.d2
3 files changed, 6 insertions, 4 deletions
diff --git a/libphobos/libdruntime/gcc/deh.d b/libphobos/libdruntime/gcc/deh.d
index 2e67932..5ce4869 100644
--- a/libphobos/libdruntime/gcc/deh.d
+++ b/libphobos/libdruntime/gcc/deh.d
@@ -805,7 +805,7 @@ version (GNU_SEH_Exceptions)
void* ms_orig_context, void* ms_disp)
{
return _GCC_specific_handler(ms_exc, this_frame, ms_orig_context,
- ms_disp, &__gdc_personality_imp);
+ ms_disp, &gdc_personality);
}
}
else version (GNU_SjLj_Exceptions)
diff --git a/libphobos/libdruntime/gcc/gthread.d b/libphobos/libdruntime/gcc/gthread.d
index ef35a3c27..5003637 100644
--- a/libphobos/libdruntime/gcc/gthread.d
+++ b/libphobos/libdruntime/gcc/gthread.d
@@ -86,10 +86,12 @@ else static if (GNU_Thread_Model == ThreadModel.Single)
}
else static if (GNU_Thread_Model == ThreadModel.Win32)
{
+ import core.stdc.config;
+
struct __gthread_once_t
{
- INT done;
- LONG started;
+ int done;
+ c_long started;
}
int __gthr_win32_key_create(__gthread_key_t* keyp, GthreadDestroyFn dtor);
diff --git a/libphobos/libdruntime/gcc/unwind/generic.d b/libphobos/libdruntime/gcc/unwind/generic.d
index 5315739..592b3af 100644
--- a/libphobos/libdruntime/gcc/unwind/generic.d
+++ b/libphobos/libdruntime/gcc/unwind/generic.d
@@ -269,6 +269,6 @@ version (GNU_SEH_Exceptions)
ExceptionCollidedUnwind
}
- extern(C) EXCEPTION_DISPOSITION _GCC_specific_handler(void*, void*, void*,
+ extern(C) EXCEPTION_DISPOSITION _GCC_specific_handler(void*, void*, void*, void*,
_Unwind_Personality_Fn);
}