Intel® Advisor

Data Sharing Problems

In a serial program, the order of the operations during program execution are known. However, when code executes as multiple parallel tasks, an operation can execute before, after, or simultaneously with an operation in the other task. For example, when parallel tasks access or modify a shared memory location, data sharing problems can occur.

Difficult Problems: Choosing a Different Set of Tasks

If you find a conflict that cannot be resolved using the above techniques, you should consider the following alternatives.

  • Merge the two tasks involved in the conflict into a single task.

  • Divide the tasks into smaller tasks and do the work preceding the conflict in parallel, the work involving the conflict serially, and the work after the conflict in parallel.

  • Find a different site to introduce parallelism.

Using Intel® Inspector and Intel® VTune™ Amplifier

Intel® Advisor helps you:

  • Discover where to add parallelism to your program by identifying where your program spends its time. You propose parallel code regions when you annotate the parallel sites and tasks.

  • Predict the performance you might achieve with the proposed parallel code regions.

  • Predict the data sharing problems that could occur in the proposed parallel code regions.

Subscribe to Intel® Advisor