For the intrinsic sum
at least I don’t believe there are many guarantees. There’s been a lengthy discussion before here: Some Intrinsic SUMS
The standard appears to wash it’s hands by stating the result is processor-dependent:
The result of SUM (ARRAY) has a value equal to a processor-dependent approximation to the sum of all the elements of ARRAY or has the value zero if ARRAY has size zero
(Processor being jargon for the Fortran compiler in typical scenarios.)
Especially for global sums across multiple ranks (MPI) or images (coarrays), enhanced accurary is needed to get consistent results. The following paper discusses the issue: Redirecting