Build fail on gthr-simple.h targets (Re: AsyncI/O patch committed)

Thomas Koenig tkoenig@netcologne.de
Thu Jul 26 20:54:00 GMT 2018


Hi Ulrich,

> The problem is that io/asynch.h unconditionally uses a couple of
> features that are not provided by gthr-simplex, in particular
>    __gthread_cond_t
> and
>    __gthread_equal / __gthread_self
> 
> According to the documentation in gthr.h, the former is only available
> if __GTHREAD_HAS_COND is defined, and the latter are only available if
> __GTHREADS_CXX0X is defined.  Neither is true for gthr-simple.h.

Thanks for the analysis, and the pointer to the macros.

Because the functionality depends on these features, it is best to
remove them if it is not present. So, here is a patch which does
just that.

This was reg-tested on Linux, which showed that the functionality is
still there. I tried bootstrapping on AIX on gcc119, but this failed
due to an unrelated issue (problem with compiling the inline
libraries).

Would it be possible to check if this restores bootstrap in the next
10 hours or so? If so, I would like to commit this. Otherwise, Nicolas
and I will not be able to fix this for a week or so, and it would be
best to revert the async I/O patch :-(

Regards

	Thomas

2018-07-25  Thomas Koenig  <tkoenig@gcc.gnu.org>

         * io/async.h: Test for feature macros for __gthread_cond_t and
         __gthread_equal.  Define ASYNC_IO if both are present.
         (SIGNAL): Define as no-op if ASYNC_IO is not defined.
         (WAIT_SIGNAL_MUTEX): Likewise.
         (REVOLE_SIGNAL): Likewise.
         (transfer_args): Define as useless struct if ASYNC_IO is not
         defined.
         (adv_cond): Likewise.
         (async_unit): Likewise.
         * io/async.c (init_async_unit): If ASYNC_IO is not defined,
         define alternate function which does nothing.
         (enqueue_transfer): Likewise.
         (enqueue_done_id): Likewise.
         (enqueue_done): Likewise.
         (enqueue_close): Likewise.
         (enqueue_data_transfer_init): Likewise.
         (collect_async_errors): Likewise. 
 
 

         (async_wait_id): Likewise. 
 
 

         (async_wait): Likewise. 
 
 

         (async_close): Likewise.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: p-rep-1.diff
Type: text/x-patch
Size: 3551 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/fortran/attachments/20180726/73fb22ff/attachment.bin>


More information about the Fortran mailing list