OpenACC Tutorial - Adding directives/fr: Difference between revisions

Jump to navigation Jump to search
Created page with "Description ou prescription"
(Created page with "Il est rare que du code soit aussi simple et il faut se baser sur la rétroaction du compilateur pour trouver les portions qu'il a négligé de paralléliser.")
(Created page with "Description ou prescription")
Line 95: Line 95:
Il est rare que du code soit aussi simple  et il faut se baser sur la rétroaction du compilateur pour trouver les portions qu'il a négligé de paralléliser.  
Il est rare que du code soit aussi simple  et il faut se baser sur la rétroaction du compilateur pour trouver les portions qu'il a négligé de paralléliser.  
{{Callout
{{Callout
|title=Descriptive vs prescriptive
|title=Description ou prescription
|content=
|content=
Those who have used [[OpenMP]] before will be familiar with the directive based nature of OpenACC. There is however one major difference between OpenMP and OpenACC directives. OpenMP directives are by design ''prescriptive'' in nature. This means that the compiler is required to perform the requested parallelization, no matter whether this is good from a performance stand point or not. This yields very reproducible results from one compiler to the next. This also means that parallelization will be performed the same way, whatever the hardware the code runs on. However, not every architecture performs best with code written the same way. Sometimes, it may be beneficial to switch the order of loops for example. If one were to parallelize a code with OpenMP and wanted it to perform optimally on multiple different architectures, they would have to write different sets of directives for different architectures.  
Those who have used [[OpenMP]] before will be familiar with the directive based nature of OpenACC. There is however one major difference between OpenMP and OpenACC directives. OpenMP directives are by design ''prescriptive'' in nature. This means that the compiler is required to perform the requested parallelization, no matter whether this is good from a performance stand point or not. This yields very reproducible results from one compiler to the next. This also means that parallelization will be performed the same way, whatever the hardware the code runs on. However, not every architecture performs best with code written the same way. Sometimes, it may be beneficial to switch the order of loops for example. If one were to parallelize a code with OpenMP and wanted it to perform optimally on multiple different architectures, they would have to write different sets of directives for different architectures.  
rsnt_translations
56,430

edits

Navigation menu