Split the result mesh generation to work into two loops. The first loop
builds topology maps used for propagating attribute values, and the next
loop mixes attribute values with those maps. This has a few benefits:
The propagation can be done in parallel, and the topology mapping code
can get simpler. Also, we reduce the overhead that comes with iterating
over all attributes for every single element. Overall I didn't measure
a large performance difference though, because the new code has the
downside of needing to allocate two more arrays.
There is a small difference of a propagated byte color (250 vs. 251) in
the geometry nodes test due to a subtle difference in the mixing
implementation.
Part of #122398.
Pull Request: https://projects.blender.org/blender/blender/pulls/147367