Renormalise bins 6..2 into (-2**P, 2**P), propagating the excess
into the next-more-significant bin, without changing the
represented value. Bin 1 is left untouched (unbounded by
construction; see the module docstring on EFP_MAX_RANKS).
Mirrors MOM6 carry_overflow, which loops
EFP_DIGITS..2 for the same reason.
Nodes of different colours represent the following:
Solid arrows point from a procedure to one which it calls. Dashed
arrows point from an interface to procedures which implement that interface.
This could include the module procedures in a generic interface or the
implementation in a submodule of an interface in a parent module.
Where possible, edges connecting nodes are
given different colours to make them easier to distinguish in
large graphs.
Variables
Type
Visibility
Attributes
Name
Initial
integer(kind=int64),
private
::
carry_amt
integer,
private
::
n
Source Code
pure subroutine efp_carry(e)!! Renormalise bins 6..2 into `(-2**P, 2**P)`, propagating the excess!! into the next-more-significant bin, without changing the!! represented value. Bin 1 is left untouched (unbounded by!! construction; see the module docstring on `EFP_MAX_RANKS`).!! Mirrors MOM6 `carry_overflow`, which loops!! `EFP_DIGITS..2` for the same reason.integer(int64),intent(inout)::e(EFP_DIGITS)integer::ninteger(int64)::carry_amtdo n=EFP_DIGITS,2,-1if(e(n)>=EFP_PREC_I64.or.e(n)<=-EFP_PREC_I64)thencarry_amt=e(n)/EFP_PREC_I64e(n)=e(n)-carry_amt*EFP_PREC_I64e(n-1)=e(n-1)+carry_amtend if end do end subroutine efp_carry