[Question] Parallel for missing iterations? - Printable Version + open.mp forum (https://forum.open.mp) -- Forum: open.mp (https://forum.open.mp/forumdisplay.php?fid=40) --- Forum: Questions and Suggestions (https://forum.open.mp/forumdisplay.php?fid=42) --- Thread: [Question] Parallel for missing iterations? (/showthread.php?tid=2553) |
Parallel for missing iterations? - visibleonbush1 - 2024-01-18 Hi, I'm working on optimizing a piece of code, the code performs well for smaller values of 'n' (e.g., 10,000), but when 'n' is significantly larger (e.g., 100,000), it seems to skip a considerable number of iterations. Specifically, I've tested it with 'n' set to 100,000, and it only executes 1,410,065,408 iterations out of the expected 10,000,000,000., im asking here because if n is not so big (10k) he is perfectly fine, am i missing anything (thank you in advance). Code: int compute_forces( void ) RE: Parallel for missing iterations? - Threshold - 2024-01-19 Would this line be causing any grief? Code: if (j <= i) { RE: Parallel for missing iterations? - visibleonbush1 - 2024-01-20 (2024-01-19, 03:52 AM)Threshold Wrote: Would this line be causing any grief? No, because i put the the counter before the if clause (its the variable "asdf", yeah i know, not a good name). |