I have a C parallel for loop which includes a line like
b[i] = b[0];
so I need to complete the first iteration before starting any other iteration. Is there a clause which enforces such behavior?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Just pull the first iteration out of the loop and start the loop at index 1. That’s by far the easiest and cheapest way. Other ways involve waiting, which is inefficient.