- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I have a very large amount of code in a multi-body simulator that I have made parallel. All the subroutines in the parallel section are pure, and all the data passed into the top level of this section iscleanly divided by body. So each entry into the per bodypropagation is split off into a parallel task by an OMP Parallel Do statement.
My concern is will the local data in the pure subroutines ever "cross wires" due to parallel read-modify-write?
Do I need to use mutexes or critical sections in the pure subroutines?
Link Copied
3 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
It doesn't sound like you have a problem, if you have enabled these data to be thread local. You might want to try Intel Thread Checker.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Does thread local mean that every subroutine must have all of its local data specified as a thread variable?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
tim18:
if you have enabled these data to be thread local
Does that apply to every variable in every subroutine individually?

Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page