astrofrog/fast-histogram

Add OpenMP

Open

#32 opened on 2018年11月1日

GitHub で見る
 (2 comments) (0 reactions) (0 assignees)C (28 forks)github user discovery
help wantedperformance

Repository metrics

Stars
 (279 stars)
PR merge metrics
 (PR metrics pending)

説明

I think it should be possible to rewrite the loops to include OpenMP pragmas. The final update could be protected with #pragma omp atomic and you can use default(shared) private(tx ty ix iy) firstprivate(dataptr) or something similar. You'll need to redo the loops, however, you'll need for loops instead of the inner while (or maybe the outer do while), and the stride part might need to be precalculated in some way.

コントリビューターガイド