Visible to Intel only — GUID: GUID-09D357EF-F6EA-4160-9A7A-CA9C7415B0B8
Visible to Intel only — GUID: GUID-09D357EF-F6EA-4160-9A7A-CA9C7415B0B8
GAP Message (Diagnostic ID 30526)
Message
To parallelize the loop at line %d, annotate the routine %s with %s.
Advice
If the loop contains a call to a function, the compiler cannot parallelize the loop without more information about the function being called.
However, if the function being called in the loop is an elemental function or a function specified with ATTRIBUTES CONCURRENCY_SAFE, then the call does not inhibit parallelization of the loop.
Example
Consider the following:
subroutine foo () integer, parameter :: N2 = 10000 real (8) :: A(N2), B(N2) interface function bar (k) integer :: bar, k end function bar end interface integer :: i do i =1, N2 A(i) = B(i) * bar(N2) end do end subroutine foo
If you determine it is safe to do so, an alternative way you can modify the program code is as follows:
subroutine foo () integer, parameter :: N2 = 10000 real (8) :: A(N2), B(N2) interface function bar (k) !dir$ attributes concurrency_safe : profitable :: bar integer :: bar, k end function bar end interface integer :: i do i =1, N2 A(i) = B(i) * bar(N2) end do end subroutine foo
Verify
Confirm the routine satisfies the semantics of this annotation. A weaker annotation able to achieve a similar effect is ATTRIBUTES CONCURRENCY_SAFE(PROFITABLE).