- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi all,
we are facing a problem with a call to MATMUL. The setup is similar to the following:
REAL*8, ALLOCATABLE, DIMENSION (:,:) :: v
REAL*8, ALLOCATABLE, DIMENSION (:) :: rs,temp
ALLOCATE(v(n,m), temp(n), rs(m+1))
...
DO i=1,m
temp = MATMUL(v(:,1:i), rs(1:i))
ENDDO
...
If the above code snippet is compiled with -i8 -O3 -xW -parallel -heap-arrays, the line with MATMUL is parallelized, but the result is wrong. It is correct if the single line is broken up into a DO-loop in the form
temp = temp + v(:,j)*rs(j)
It is also correct, if -parallel is omitted. And, ifanother twoallocatable arrays are introduced and the critical code is replaced according to
ALLOCATE (v2(n,i),rs2(i))
temp = MATMUL(v2,rs2)
DEALLOCATE(v2,rs2)
everthing works fine - incl. parallelization.
I also included some debug output to check arrays just before and after the MATMUL opperation. These show that up to the MATMUL call everything is as it should be; however, directly after MATMUL the temp arrays are different. So, there seems to be a problem with the array sections, MATMUL, and parallelization. Has anybody encountered a problem like this?
Best,
Hermann
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

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