------- Comment #20 from kargl at gcc dot gnu dot org  2007-02-08 16:18 -------
(In reply to comment #17)
> 
> Now, if Fortran2003 allows some recursive access to the same unit
> (under which conditions?),

Recursive IO to external units is simply not allowed by the Fortran
95 and Fortran 2003 standards.  You could wade through Brooks
posts in fortran@ to see where recursion is allowed.


> __gthread_recursive_mutex_t as well as the initializer, perhaps together with
> adding a recursion count (as the recursion count in 
> __gthread_recursive_mutex_t
> isn't portably accessible) to gfc_unit as well.  The question is how much is
> libgfortran prepared for changes happening to gfc_unit happening between
> say st_write and st_write_done calls (st_write normally calls get_unit and 
> thus
> acquires gfc_unit's lock, which is held until st_write_done calls 
> unlock_unit).
> 

This sound like a performance penalty imposed on anyone writing standard
conforming code to permit nonconforming code to run.  The fact 
remains that a fortran processor can do anything it wants with nonconforming
code.  It might "work" on some architecture and it may "fail" another for
some definition of "work" and "fail".  So be it.  


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=30617

Reply via email to