File1: #include <assert.h> \n#include <stdio.h>\n/* This is a program based on a test contributed by Yizi Gu@Rice Univ.\n * Proper user of ordered directive and clause, no data races\n * */\nint main()\n{\n  int x =0;\n#pragma omp parallel for ordered \n  for (int i = 0; i < 100; ++i) {\n#pragma omp ordered\n    {\n      x++;\n    }\n  }\n  assert (x==100);\n  printf ("x=%d\n",x);\n  return 0;\n} \n
File2: program DRB110_ordered_orig_no\n    use omp_lib\n    implicit none\n\n    integer x, i\n    x=0\n    \n    !$omp parallel do ordered\n    do i = 1, 100\n        !$omp ordered\n        x = x+1\n        !$omp end ordered\n    end do\n    !$omp end parallel do    \n\n    print*,'x =',x\nend program