So, in the program I´m writting I have to make a really long for instruction, in this particular case to 2^15 (32768), it however freezes the screen for a few seconds, so it goes something like this:
function A(var start,var end)
{
var i;
for(i=start;i<end;i++)
{
//actions here
}
}
function main()
{
A(0,32768);
}
Is there anyway to call several instances of the A function at the same time, so it finishes faster:
function A(var start,var end)
{
var i;
for(i=start;i<end;i++)
{
//actions here
}
}
function main()
{
A(0,8192);
A(8192,16384);
A(16384,24576);
A(24576,32768);
}
If write it that way it will call one function after another, and what I want is to call them at the same time, any ideas how to?, or is there a better way?, thanks in advance.