re PR libgomp/93065 (libgomp: destructor missing to delete goacc_cleanup_key)

PR libgomp/93065
	* oacc-init.c (goacc_runtime_deinitialize): New function.

From-SVN: r279803
This commit is contained in:
Ayush Mittal 2019-12-31 10:34:34 +00:00 committed by Jakub Jelinek
parent e3969868d6
commit 2c8297996a
2 changed files with 14 additions and 0 deletions

View File

@ -1,3 +1,8 @@
2019-12-31 Ayush Mittal <ayush.m@samsung.com>
PR libgomp/93065
* oacc-init.c (goacc_runtime_deinitialize): New function.
2019-12-28 Jakub Jelinek <jakub@redhat.com>
PR bootstrap/93074

View File

@ -858,6 +858,15 @@ goacc_runtime_initialize (void)
goacc_host_init ();
}
static void __attribute__((destructor))
goacc_runtime_deinitialize (void)
{
#if !(defined HAVE_TLS || defined USE_EMUTLS)
pthread_key_delete (goacc_tls_key);
#endif
pthread_key_delete (goacc_cleanup_key);
}
/* Compiler helper functions */
attribute_hidden void