[Pw_forum] segmentation fault in local.f90 line 228 PWCOND version 4.3.2

Xiaoguang Zhang xgz at ornl.gov
Fri Feb 3 20:28:39 CET 2012

pwcond.x crashes when it is trying to access vppot(1,2161,1,1) while 
calculating the eigenvalues for the left lead. I inserted a print 
statement in local.f90 and verified that this is the element that caused 
the crash. After inserting these lines:
*** 213,218 ****
--- 213,220 ----
   ! set and solve the eigenvalue equation for each slab
+   print *, nrz,nrx*nry,npol
+   print *, vppot(1,2161,1,1)
     DO WHILE(kin.LE.kfin)

the program crashed at the print statement with the last output
20        2916           1
which are nrz, nrx*nry, npol. There is no reason for it to crash.

Full error message below:
../../espresso-4.3.2/bin/pwcond.x < Alwirebig.cond.in > Alwirebig.cond.out
forrtl: severe (174): SIGSEGV, segmentation fault occurred
Image              PC                Routine            Line 
pwcond.x           0000000000432BEF  local_1_                  228 
pwcond.x           000000000042FAA9  local_                     71 
pwcond.x           00000000004161FC  do_cond_                  421 
pwcond.x           000000000041130C  MAIN__                     20 
pwcond.x           0000000000403922  Unknown               Unknown  Unknown
libc.so.6          0000002A9580F4CB  Unknown               Unknown  Unknown
pwcond.x           000000000040386A  Unknown               Unknown  Unknown

More information about the users mailing list