Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Survey Question on the For loop in source file https:/github.com/AMDComputeLibraries/OpenMPApps/blob/master/xsbench-mp4/src/GridInit.c line 168 #7

Open
quazirafi opened this issue Jun 26, 2022 · 0 comments

Comments

@quazirafi
Copy link

Hello Sir/ Madam
We are from a research group at Iowa State University, USA. We want to do a survey on Github developers on the methods they used for paralleling their code. To do the survey, We want to ask three questions about this for loop:

Can you briefly explain the purpose of using pragma for this case? If the pragma contained reduction and private clauses, can you briefly mention the purposes of variables in those clauses?

How much confidence do you have about the correctness of this implementation? You can choose from 1-5 with 1 as the lowest confidence score and 5 as the highest confidence score.

(Optional) Do you actually run (interpret the code with compilation and pass input/get output) the code and see the optimization of parallelization? Yes/No

If yes, can you provide the information of what are the input and expected output of this program (the input that caused the program to run through this for-loop).
The for loop is from line 168 of file https:/github.com/AMDComputeLibraries/OpenMPApps/blob/master/xsbench-mp4/src/GridInit.c
Here is a part of the code:

#pragma omp parallel for default(none)
shared( energy_grid, nuclide_grids, grid_ptrs, n_isotopes, n_gridpoints, mype )
for( long i = 0; i < n_isotopes * n_gridpoints ; i++ ){
double quarry = energy_grid[i].energy;
if( INFO && mype == 0 && omp_get_thread_num() == 0 && i % 200 == 0 )
printf("\rAligning Unionized Grid...(%.0lf%% complete)",
100.0 * (double) i / (n_isotopes*n_gridpoints /
omp_get_num_threads()) );
for( long j = 0; j < n_isotopes; j++ ){
// j is the nuclide i.d.
// log n binary search
grid_ptrs[energy_grid[i].xs_ptrs + j] =
binary_search( nuclide_grids[j], quarry, (uint)n_gridpoints );
}
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant