mirror of
https://github.com/gcc-mirror/gcc.git
synced 2026-05-06 14:59:39 +02:00
efb497c23a6f4109bf8794342617cbc161c08301
Cygwin's libc's pthread implementation does not support setting pshared on mutexes and condition variables. Therefore Windows synchronisation primitives needed to be used directly. On MSYS2/UCRT64 fork and mmap are not available and Windows core functionality needs to be used. libgfortran/ChangeLog: * caf/shmem.c (_gfortran_caf_init): Cleanup thread helper after use. (_gfortran_caf_finalize): Same. (_gfortran_caf_register): Handle lock_t correctly on Windows. (GEN_OP): Prevent warnings on non-initialized. (_gfortran_caf_lock): Handle lock_t correctly on Windows. (_gfortran_caf_unlock): Same. (_gfortran_caf_random_init): Fix formatting. (_gfortran_caf_form_team): Add more images to counter_barrier. * caf/shmem/alloc.c: Use routines from thread_support. * caf/shmem/allocator.c (allocator_lock): Same. (allocator_unlock): Same. * caf/shmem/allocator.h: Same. * caf/shmem/collective_subroutine.c (get_collsub_buf): Same. * caf/shmem/collective_subroutine.h: Same. * caf/shmem/counter_barrier.c (lock_counter_barrier): Same. (unlock_counter_barrier): Same. (counter_barrier_init): Same. (counter_barrier_wait): Same. (change_internal_barrier_count): Same. (counter_barrier_add): Same. (counter_barrier_init_add): Only increase value w/o signaling. (counter_barrier_get_count): Use routines from thread_support. * caf/shmem/counter_barrier.h: Same. (counter_barrier_init_add): New routine. * caf/shmem/shared_memory.c: Use windows routines where applicable. (shared_memory_set_env): Same. (shared_memory_get_master): Same. (shared_memory_init): Same. (shared_memory_cleanup): Same. * caf/shmem/shared_memory.h: Use types from thread_support. * caf/shmem/supervisor.c: Use windows routines where applicable. (get_memory_size_from_envvar): Same. (ensure_shmem_initialization): Same. (supervisor_main_loop): Use windows process start on windows without fork(). * caf/shmem/supervisor.h: Use types from thread_support. * caf/shmem/sync.c (lock_table): Use routines from thread_support. (unlock_table): Same. (sync_init): Same. (sync_init_supervisor): Same. (sync_table): Same. (lock_event): Same. (unlock_event): Same. (event_post): Same. (event_wait): Same. * caf/shmem/sync.h: Use types from thread_support. * caf/shmem/teams_mgmt.c (update_teams_images): Use routines from thread_support. * caf/shmem/thread_support.c: Add synchronisation primitives for windows. (smax): Windows only: Max for size_t. (get_handle): Windows only: Get the windows handle for a given id or create a new one, if it does not exist. (get_mutex): Windows only: Shortcut for getting a windows mutex handle. (get_condvar): Windows only: Same, but for condition variable. (thread_support_init_supervisor): Windows only: Clear tracker of allocated handle ids. (caf_shmem_mutex_lock): Windows only: Implememtation of lock, (caf_shmem_mutex_trylock): Windows only: trylock, and (caf_shmem_mutex_unlock): Windows only: unlock for Windows. (bm_is_set): Windows only: Check a bit is set in a mask. (bm_clear_bit): Windows only: Clear a bit in a mask. (bm_set_mask): Windows only: Set all bits in a mask. (bm_is_none): Windows only: Check if all bits are cleared. (caf_shmem_cond_wait): Windows only: Condition variable implemenation fro wait, (caf_shmem_cond_broadcast): Windows only: broadcast, and (caf_shmem_cond_signal): Windows only: signal on Windows. (caf_shmem_cond_update_count): Windows only: Need to know the images participating in a condition variable. (thread_support_cleanup): Windows only: Clean up the handles on exit. * caf/shmem/thread_support.h: Conditionally compile the types as required for Windows and other OSes.
…
…
…
…
…
…
…
…
…
…
…
…
…
This directory contains the GNU Compiler Collection (GCC). The GNU Compiler Collection is free software. See the files whose names start with COPYING for copying permission. The manuals, and some of the runtime libraries, are under different terms; see the individual source files for details. The directory INSTALL contains copies of the installation information as HTML and plain text. The source of this information is gcc/doc/install.texi. The installation information includes details of what is included in the GCC sources and what files GCC installs. See the file gcc/doc/gcc.texi (together with other files that it includes) for usage and porting information. An online readable version of the manual is in the files gcc/doc/gcc.info*. See http://gcc.gnu.org/bugs/ for how to report bugs usefully. Copyright years on GCC source files may be listed using range notation, e.g., 1987-2012, indicating that every year in the range, inclusive, is a copyrightable year that could otherwise be listed individually.
Description
Languages
C++
30.7%
C
30.2%
Ada
14.4%
D
6.1%
Go
5.7%
Other
12.4%