Merge "Fix bug with 1D arrays and threading. Some elements got launched multiple times."