public inbox for fortran@gcc.gnu.org
 help / color / mirror / Atom feed
From: "Thomas König" <tk@tkoenig.net>
To: "Andre Vieira (lists)" <Andre.SimoesDiasVieira@arm.com>
Cc: fortran@gcc.gnu.org, tkoenig@netcologne.de,
	Ulrich Weigand <uweigand@de.ibm.com>,
	dje.gcc@gmail.com
Subject: Re: Build fail on gthr-simple.h targets (Re: AsyncI/O patch committed)
Date: Tue, 31 Jul 2018 10:30:00 -0000	[thread overview]
Message-ID: <6E98A7F0-8E4A-4845-9501-FE014CDFC4CB@tkoenig.net> (raw)
In-Reply-To: <5B6021C0.5060507@arm.com>

Hi Andre,

sorry that it took so long for a fix. I am on holiday at the moment, so my hacking environment is somewhat restricted.

Expect a combined patch for async I/O which we expect to work for pthreads targets and which should not disturb others today or tomorrow.

I would appreciate testing on critical systems.

Regards

Thomas

> Am 31.07.2018 um 09:45 schrieb Andre Vieira (lists) <Andre.SimoesDiasVieira@arm.com>:
> 
>> On 27/07/18 13:25, David Edelsohn wrote:
>> Thomas,
>> 
>> Correct, the proposed patch does not fix the build failure on AIX.
>> 
>> Please see the information on the GCC Compile Farm wiki page for
>> instructions to bootstrap on gcc119.
>> https://gcc.gnu.org/wiki/CompileFarm#Projects_Ideas - at the bottom of
>> Project ideas.
>> 
>> Thanks, David
>>> On Fri, Jul 27, 2018 at 3:30 AM Thomas Koenig <tkoenig@netcologne.de> wrote:
>>> 
>>>> Am 26.07.2018 um 22:54 schrieb Thomas Koenig:
>>>> 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).
>>>> 
>>> 
>>> OK, this does not work.
>>> 
>>> We have found a method of checking on Linux, and this does not work.
>>> We have also found a way of working in the next couple of days, so
>>> expect an update in one or two days.
>>> 
>>> If that is too much time, feel free to revert the async patch
>>> in the meantime.
>>> 
>>> Regards
>>> 
>>>        Thomas
>> 
> Hi Thomas,
> 
> Sorry but I had to revert your patch as it has been breaking our
> bare-metal builds for over 5 days now.
> 
> Comitted as r263082.
> 
> 
> 2018-07-31  Andre Vieira  <andre.simoesdiasvieira@arm.com>
> 
>    Reverted 'AsyncI/O patch committed'
>    2018-07-25  Nicolas Koenig  <koenigni@gcc.gnu.org>
>        Thomas Koenig <tkoenig@gcc.gnu.org>
> 
>        PR fortran/25829
>        * gfortran.texi: Add description of asynchronous I/O.
>        * trans-decl.c (gfc_finish_var_decl): Treat asynchronous variables
>        as volatile.
>        * trans-io.c (gfc_build_io_library_fndecls): Rename st_wait to
>        st_wait_async and change argument spec from ".X" to ".w".
>        (gfc_trans_wait): Pass ID argument via reference.
> 
>    Reverted 'AsyncI/O patch committed'
>    2018-07-25  Nicolas Koenig  <koenigni@gcc.gnu.org>
>        Thomas Koenig <tkoenig@gcc.gnu.org>
> 
>        PR fortran/25829
>        * gfortran.dg/f2003_inquire_1.f03: Add write statement.
>        * gfortran.dg/f2003_io_1.f03: Add wait statement.
> 
>    Reverted 'AsyncI/O patch committed'
>    2018-07-25  Nicolas Koenig  <koenigni@gcc.gnu.org>
>        Thomas Koenig <tkoenig@gcc.gnu.org>
> 
>        PR fortran/25829
>        * Makefile.am: Add async.c to gfor_io_src.
>        Add async.h to gfor_io_headers.
>        * Makefile.in: Regenerated.
>        * gfortran.map: Add _gfortran_st_wait_async.
>        * io/async.c: New file.
>        * io/async.h: New file.
>        * io/close.c: Include async.h.
>        (st_close): Call async_wait for an asynchronous unit.
>        * io/file_pos.c (st_backspace): Likewise.
>        (st_endfile): Likewise.
>        (st_rewind): Likewise.
>        (st_flush): Likewise.
>        * io/inquire.c: Add handling for asynchronous PENDING
>        and ID arguments.
>        * io/io.h (st_parameter_dt): Add async bit.
>        (st_parameter_wait): Correct.
>        (gfc_unit): Add au pointer.
>        (st_wait_async): Add prototype.
>        (transfer_array_inner): Likewise.
>        (st_write_done_worker): Likewise.
>        * io/open.c: Include async.h.
>        (new_unit): Initialize asynchronous unit.
>        * io/transfer.c (async_opt): New struct.
>        (wrap_scalar_transfer): New function.
>        (transfer_integer): Call wrap_scalar_transfer to do the work.
>        (transfer_real): Likewise.
>        (transfer_real_write): Likewise.
>        (transfer_character): Likewise.
>        (transfer_character_wide): Likewise.
>        (transfer_complex): Likewise.
>        (transfer_array_inner): New function.
>        (transfer_array): Call transfer_array_inner.
>        (transfer_derived): Call wrap_scalar_transfer.
>        (data_transfer_init): Check for asynchronous I/O.
>        Perform a wait operation on any pending asynchronous I/O
>        if the data transfer is synchronous. Copy PDT and enqueue
>        thread for data transfer.
> 

  reply	other threads:[~2018-07-31 10:30 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-07-25 19:28 AsyncI/O patch committed Nicolas Koenig
2018-07-26 13:31 ` Build fail on gthr-simple.h targets (Re: AsyncI/O patch committed) Ulrich Weigand
2018-07-26 13:40   ` Build fail on gthr-single.h " Ulrich Weigand
2018-07-26 20:54   ` Build fail on gthr-simple.h " Thomas Koenig
2018-07-27  7:31     ` Thomas Koenig
2018-07-27 12:26       ` David Edelsohn
2018-07-31  8:45         ` Andre Vieira (lists)
2018-07-31 10:30           ` Thomas König [this message]
2018-08-02 11:35           ` Async I/O patch with compilation fix Nicolas Koenig
2018-08-02 15:43             ` Christophe Lyon
2018-08-02 17:08               ` Nicolas Koenig
2018-08-03  8:46                 ` Christophe Lyon
2018-08-03 22:43                   ` Thomas König
2018-08-06 11:33                     ` Christophe Lyon
2018-08-17 15:41                   ` Thomas Koenig
2018-08-18 22:44                     ` Christophe Lyon
2018-08-19 13:40                       ` Thomas Koenig
     [not found]                         ` <CAKdteObsx+RK2t-OteU_w6L_Pv7FGLpAcLrHaPY4NDAamV-z7g@mail.gmail.com>
2018-08-21 19:43                           ` Thomas Koenig
2018-08-21 20:08                             ` Fwd: " Thomas Koenig
2018-08-22 18:49                             ` David Edelsohn
2018-08-22 21:31                               ` Thomas Koenig
2018-08-23 12:25                                 ` David Edelsohn
2018-08-23 17:42                                   ` Thomas Koenig
2018-08-23 12:53                                 ` David Edelsohn
2018-07-26 15:18 Build fail on gthr-simple.h targets (Re: AsyncI/O patch committed) David Edelsohn

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=6E98A7F0-8E4A-4845-9501-FE014CDFC4CB@tkoenig.net \
    --to=tk@tkoenig.net \
    --cc=Andre.SimoesDiasVieira@arm.com \
    --cc=dje.gcc@gmail.com \
    --cc=fortran@gcc.gnu.org \
    --cc=tkoenig@netcologne.de \
    --cc=uweigand@de.ibm.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).