Help adding large array

What is the best way (as in the most efficient) to calculate the sum of a big array (>80000 cells)? In the problem I’m trying to solve I have at least 100 work-items, each one calculating the sum of a different array of that size.

100 work-items is very little. Instead of having one work-item for each of the 100 arrays it would be better if you launched many work-items in each array and perform what is called a “reduction”.

This link has an example of how to do it: