[Omp] (no subject)

chandrapal.kailasanathan at dpi.nsw.gov.au chandrapal.kailasanathan at dpi.nsw.gov.au
Tue Sep 4 22:56:42 PDT 2007


Hi Eugene,

Suppose header1_skip(1 - 3)  has 1500, 1, 2 and header2_skip_key(1 - 3) 
has 3000, 1, 2
and dim_header1_skip has 3 and dim_header2_skip has 3, I would expect 
flag1 to be
updated to 0 at i=j=2 and i=j=3 and com_field1 to be updated to 2 and 3, 
respectively,
in serial mode. My intention is to get the same behaviour in parallel 
mode. Unfortunately,
because of the parallelization com_field1 remains at 3 for i=j=2 and 
i=j=3. And most
of the time my program crashes with the message: 

C:\CK>merge
system error(8): __kmp_create_monitor: CreateThread: Not enough storage is 
avail
able to process this command.

OMP abort: fatal system error detected.

I have increased the stack size and it couldn't fix the problem either. 






Eugene Loh <Eugene.Loh at Sun.COM>
Sent by: Eugene.Loh at Sun.COM
05/09/2007 02:38 PM

 
        To:     chandrapal.kailasanathan at dpi.nsw.gov.au
        cc:     omp at openmp.org
        Subject:        Re: [Omp] (no subject)


Could you describe the intended behavior of this code, including the 
desired exit values of flag1 and com_field1 and what you're looking for in 
the printed output?

chandrapal.kailasanathan at dpi.nsw.gov.au wrote: 
Can anyone help me to parallelize the following piece of code? I know this 
is where it fails when i run in debug mode. 

integer :: dim_header1_skip, dim_header2_skip, i, j, flag1, com_field1 
integer, dimension(100) :: header1_skip_key, header2_skip_key 


!$OMP PARALLEL DO 
 
      do i=1,dim_header2_skip                                   ! for each column in header2_skip 
      flag1=1 
      
!$OMP PARALLEL DO 
  
      do j=1,dim_header1_skip                                   ! check if it is in header1_skip 
 
        !if (header2_skip(i)==header1_skip(j)) then 
        if  (header2_skip_key(i)==header1_skip_key(j)) then 
          flag1=0 
          com_field1=j 
          print *, flag1, com_field1 
        endif         
 
      enddo 
      
!$OMP END PARALLEL DO 

      enddo 

!$OMP END PARALLEL DO



This message is intended for the addressee named and may contain 
confidential information. If you are not the intended recipient or 
received it in error, please delete the message and notify sender. Views 
expressed are those of the individual sender and are not necessarily the 
views of their organisation.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://openmp.org/pipermail/omp/attachments/20070905/2cfe8d24/attachment.html 


More information about the Omp mailing list