Hi!
The order in which the elements arrive in an iteration HEAD is the order in which the last operator in the loop (the TAIL) produces them. If that is a deterministic ordering (because of a sorted reduce, for example), then you should be able to rely on the order.
Otherwise, the order of elements can always change every time elements are re-distributed across tasks (for example during a key-based shuffle, a broadcast, or a change of parallelism).
Greetings,
Stephan