[J3] Question about the maximum event count of EVENT_TYPE variables

Milan Curcic caomaco at gmail.com
Mon Jun 7 06:48:59 UTC 2021


Section 16.10.2.10, paragraph 2, line 16 of 18-007r1 states:

> The event count is of type integer with kind ATOMIC_INT_KIND from the
intrinsic module ISO_FORTRAN_ENV

and the ATOMIC_INT_KIND is defined as (16.10.2.2):

> The value of the default integer scalar constant ATOMIC_INT_KIND is the
kind type parameter value of type integer variables for which the processor
supports atomic operations specified by atomic subroutines.

My interpretation of this is that EVENT_TYPE variables have a maximum event
count that is processor-dependent. With GFortran and ifort,
that's 2147483647.

However, I can't find any text that describes what happens to the event
count when it exceeds its maximum value. With GFortran+OpenCoarrays, it
overflows (i.e. -2147483648 follows 2147483647).

Is this behavior:

* Processor-dependent?
* Undefined?
* Non-conforming?

I think that the Standard should at least say if the behavior is one of the
above, if not also what should happen to the event count value. Do you
agree? If yes, does this call for an interp?

Thanks,
Milan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mailman.j3-fortran.org/pipermail/j3/attachments/20210607/3ea794c1/attachment.htm>


More information about the J3 mailing list