Multidimensional Array Initialization: Any benefit from Threading?

Posted by Alan on Stack Overflow See other posts from Stack Overflow or by Alan
Published on 2010-05-28T21:50:09Z Indexed on 2010/05/28 21:52 UTC
Read the original article Hit count: 215

say I have the following code:

char[5][5] array;

for(int i =0; i < 5; ++i)
{
   for(int j = 0; j < 5; ++i)
   { 
       array[i][j] = 'X';
   }
}

Would there be a benefit for initializing each row in this array in a separate thread?

Imagine instead of a 5 by 5 array, we have a 10 by 10? n x n?

Also, this is done once, during application startup.

© Stack Overflow or respective owner

Related posts about c++

Related posts about threading