PGI User Forum
 SearchSearch   MemberlistMemberlist     RegisterRegister   ProfileProfile    Log inLog in 

Free OpenACC Webinar

Command exit code: 2

 
Post new topic   Reply to topic    PGI User Forum Forum Index -> Programming and Compiling
View previous topic :: View next topic  
Author Message
MetStar



Joined: 31 May 2012
Posts: 2

PostPosted: Tue Jun 05, 2012 8:30 am    Post subject: Command exit code: 2 Reply with quote

Hello,

I have been trying to compile some Fortran files that I have been given. Most of them build fine however one is failing. I am using PGI Visual Fortran and the only error message I am receiving is:

Command exit code: 2

I can't seem to find any information on this code. Can anyone provide any insight?

Thanks,
John
Back to top
View user's profile
mkcolg



Joined: 30 Jun 2004
Posts: 6205
Location: The Portland Group Inc.

PostPosted: Tue Jun 05, 2012 9:37 am    Post subject: Reply with quote

Hi John,

Unfortunately, there's not enough to go on here. Without context it's unknown if the "2" is Signal 2, user interrupt, or a specific error code coming from a program.

Does the error occur when compiling a specific file? Can you try compiling the file from the DOS shell and add the verbose (-v) flag?

- Mat
Back to top
View user's profile
MetStar



Joined: 31 May 2012
Posts: 2

PostPosted: Tue Jun 05, 2012 11:58 am    Post subject: Reply with quote

Thanks for the reply,

Inside of Visual Studios all of the files seem to build fine using the default output/intermediate directories, however, when I change these, one of my files fails to compile. The build log is as follows:

Code:
Compiling Project ...

src\terrain_cell_class.f90

c:\program files (x86)\pgi\win32\12.5\bin\pgfortran.exe -Hx,123,8 -Hx,123,0x40000 -Hx,0,0x40000000 -Mx,0,0x40000000 -Hx,0,0x20000000 -g -Bstatic -Mbackslash -Mfree -I"c:\program files (x86)\pgi\win32\12.5\include" -I"C:\Program Files\PGI\Microsoft Open Tools 10\include" -I"C:\Program Files\PGI\Microsoft Open Tools 10\PlatformSDK\include" -Minform=warn -module "C:\Users\testUser\Documents\Visual Studio 2010\Projects\RRT-Build\BuildDir\lib" -o "C:\Users\testUser\Documents\Visual Studio 2010\Projects\RRT-Build\BuildDir\lib\terrain_cell_class.obj" -c "C:\Users\testUser\Documents\Visual Studio 2010\Projects\RRT-Build\futils\src\terrain_cell_class.f90"

Command exit code: 2


So I decided to try running this from a command prompt using:

Code:
pgfortran -Hx,123,8 -Hx,123,0x40000 -Hx,0,0x40000000 -Mx,0,0x40000000 -Hx,0,0x20000000 -g -Bstatic -Mbackslash -Mfree -I"c:\program files (x86)\pgi\win32\12.5\include" -I"C:\Program Files\PGI\Microsoft Open Tools 10\include" -I"C:\Program Files\PGI\Microsoft Open Tools 10\PlatformSDK\include" -Minform=warn -module "C:\Users\testUser\Documents\Visual Studio 2010\Projects\RRT-Build\BuildDir\lib" -o "C:\Users\testUser\Documents\Visual Studio 2010\Projects\RRT-Build\BuildDir\lib\terrain_cell_class.obj" -c "C:\Users\testUser\Documents\Visual Studio 2010\Projects\RRT-Build\futils\src\terrain_cell_class.f90"


This failed to execute so I tried:

Code:
pgfortran -g -Bstatic -Mbackslash -Mfree -Minform=warn -module "C:\Users\testUser\Documents\Visual Studio 2010\Projects\RRT-Build\BuildDir\lib" -o "C:\Users\testUser\Documents\Visual Studio 2010\Projects\RRT-Build\BuildDir\lib\terrain_cell_class.obj" -c "C:\Users\testUser\Documents\Visual Studio 2010\Projects\RRT-Build\futils\src\terrain_cell_class.f90"


This command caused windows to report that 'pgf901.exe' had stopped working. When I added the -v flag, however, the command executed and seemed to compile the file successfully.

Code:
pgfortran -g -Bstatic -Mbackslash -Mfree -Minform=warn -module "C:\Users\testUser\Documents\Visual Studio 2010\Projects\RRT-Build\BuildDir\lib" -o "C:\Users\testUser\Documents\Visual Studio 2010\Projects\RRT-Build\BuildDir\lib\terrain_cell_class.obj" -c -v "C:\Users\testUser\Documents\Visual Studio 2010\Projects\RRT-Build\futils\src\terrain_cell_class.f90"


Output:

Code:
"C:\Program Files (x86)\PGI/win32/12.5/bin\pgf901.EXE" "C:\Users\testUser\Documents\Visual Studio 2010\Projects\RRT-Build\futils\src\terrain_cell_class.f90" -debug -x 120 0x200 -opt 0 -inform warn -nohpf -nostatic -x 15 2 -x 49 0x400004 -x 51 0x20 -x 57 0x4c -x 58 0x10000 -x 124 0x1000 -x 120 0x80000000 -x 59 4 -x 51 0x20 -x 119 0x1000 -x 121 0x10000 -x 124 0x401 -x 19 0x400000 -x 119 0x9900000 -x 57 0x7b0000 -x 58 0x78031040 -x 119 0x610400 -x 120 0x80000000 -x 59 4 -x 15 2 -x 48 5375 -stdinc "C:\Program Files (x86)\PGI/win32/12.5/include;C:/Program Files/PGI/Microsoft Open Tools 10/include/sys;C:/Program Files/PGI/Microsoft Open Tools 10/include;C:/Program Files/PGI/Microsoft Open Tools 10/PlatformSDK/include" -def __extension__= -def _MT -def _M_IX86=600 -def _M_IX86_FP=0 -def _WIN32 -def __WIN32 -def __WIN32__ -def i386 -def__i386 -def __i386__ -def __unaligned= -def _INTEGRAL_MAX_BITS=64 -def __amd64__ -def __SSE__ -def __MMX__ -def __SSE2__ -def __SSE3__ -def __SSSE3__ -def fastcall= -def __PGI_TOOLS10 -freeform -vect 48 -y 54 1 -x 49 0x1000 -x 124 0x40 -freeform -moddir  C:\Users\testUser\Documents\Visual Studio 2010\Projects\RRT-Build\BuildDir\lib" -modexport C:\Users\testUser\AppData\Local\Temp\pgfortran3bzGwlNms5qlO.cmod -modindex C:\Users\testUser\AppData\Local\Temp\pgfortran4cHGwJGruWe6e.cmdx -output C:\Users\testUser\AppData\Local\Temp\pgfortran2arGwZGOakh3p.ilm
NOTE: your trial license will expire in 14 days, 9.28 hours.
  0 inform,   0 warnings,   0 severes, 0 fatal for terrain_cell_class
  0 inform,   0 warnings,   0 severes, 0 fatal for new_terrain_cell
  0 inform,   0 warnings,   0 severes, 0 fatal for delete_terrain_cell
  0 inform,   0 warnings,   0 severes, 0 fatal for init_terrain_cell
  0 inform,   0 warnings,   0 severes, 0 fatal for set_os_type
  0 inform,   0 warnings,   0 severes, 0 fatal for get_filename
  0 inform,   0 warnings,   0 severes, 0 fatal for read_dted_file
  0 inform,   0 warnings,   0 severes, 0 fatal for read_dted_headers
  0 inform,   0 warnings,   0 severes, 0 fatal for get_cell_height_deg
  0 inform,   0 warnings,   0 severes, 0 fatal for cached_height
  0 inform,   0 warnings,   0 severes, 0 fatal for readinto_height
  0 inform,   0 warnings,   0 severes, 0 fatal for get_ground_range_incr
  0 inform,   0 warnings,   0 severes, 0 fatal for rms_path
  0 inform,   0 warnings,   0 severes, 0 fatal for rms_area
  0 inform,   0 warnings,   0 severes, 0 fatal for rms_area_cell
  0 inform,   0 warnings,   0 severes, 0 fatal for read_into_dted_file
  0 inform,   0 warnings,   0 severes, 0 fatal for clear_cell_cache
  0 inform,   0 warnings,   0 severes, 0 fatal for not_found
  0 inform,   0 warnings,   0 severes, 0 fatal for get_indexes
  0 inform,   0 warnings,   0 severes, 0 fatal for bytes2height
PGF90/x86 Windows 12.5-0: compilation successful

"C:\Program Files (x86)\PGI/win32/12.5/bin\pgf902.EXE" C:\Users\testUser\AppData\Local\Temp\pgfortran2arGwZGOakh3p.ilm -fn "C:\Users\testUser\Documents\Visual Studio 2010\Projects\RRT-Build\futils\src\terrain_cell_class.f90" -debug -x 120 0x200 -opt 0 -inform warn -x 51 0x20 -x 120 0x80000000 -x 59 4 -x 119 0xa11400 -x 119 0x8900000 -x 122 0x44 -x 19 0x400000-x 28 0x40000 -x 123 0x1000 -x 127 4 -x 127 17 -x 119 0x1610400 -x 92 1 -y 80 0x1000 -y 124 0x1000 -tp sandybridge -x 70 0x8000 -x 122 1 -x 120 0x200 -x 51 0x20 -x 119 0x1000 -x 121 0x10000 -x 124 0x401 -x 119 0x1400000 -y 15 2 -x 57 0x3b0000 -x 58 0x48000000 -x 15 2 -astype 0 -x 124 1 -x 124 0x40 -cmdline "+pgfortran C:\Users\testUser\Documents\Visual Studio 2010\Projects\RRT-Build\futils\src\terrain_cell_class.f90 -g -Bstatic -Mbackslash -Mfree -Minform=warn -module C:\Users\testUser\Documents\Visual Studio 2010\Projects\RRT-Build\BuildDir\lib -o C:\Users\testUser\Documents\Visual Studio 2010\Projects\RRT-Build\BuildDir\lib\terrain_cell_class.obj -c -v" -asm C:\Users\testUser\AppData\Local\Temp\pgfortran5dPGw7K9QTf2o.s
NOTE: your trial license will expire in 14 days, 9.28 hours.
  0 inform,   0 warnings,   0 severes, 0 fatal for terrain_cell_class
  0 inform,   0 warnings,   0 severes, 0 fatal for new_terrain_cell
  0 inform,   0 warnings,   0 severes, 0 fatal for delete_terrain_cell
  0 inform,   0 warnings,   0 severes, 0 fatal for init_terrain_cell
  0 inform,   0 warnings,   0 severes, 0 fatal for set_os_type
  0 inform,   0 warnings,   0 severes, 0 fatal for get_filename
  0 inform,   0 warnings,   0 severes, 0 fatal for read_dted_file
  0 inform,   0 warnings,   0 severes, 0 fatal for read_dted_headers
  0 inform,   0 warnings,   0 severes, 0 fatal for get_cell_height_deg
  0 inform,   0 warnings,   0 severes, 0 fatal for cached_height
  0 inform,   0 warnings,   0 severes, 0 fatal for readinto_height
  0 inform,   0 warnings,   0 severes, 0 fatal for get_ground_range_incr
  0 inform,   0 warnings,   0 severes, 0 fatal for rms_path
  0 inform,   0 warnings,   0 severes, 0 fatal for rms_area
  0 inform,   0 warnings,   0 severes, 0 fatal for rms_area_cell
  0 inform,   0 warnings,   0 severes, 0 fatal for read_into_dted_file
  0 inform,   0 warnings,   0 severes, 0 fatal for clear_cell_cache
  0 inform,   0 warnings,   0 severes, 0 fatal for not_found
  0 inform,   0 warnings,   0 severes, 0 fatal for get_indexes
  0 inform,   0 warnings,   0 severes, 0 fatal for bytes2height
PGF90/x86 Windows 12.5-0: compilation successful

"C:\Program Files (x86)\PGI/win32/12.5/bin\as32.EXE" C:\Users\testUser\AppData\Local\Temp\pgfortran5dPGw7K9QTf2o.s -o C:\Users\testUser\AppData\Local\Temp\pgfortran6eXGwtmkBStqx.obj

"C:\Program Files (x86)\PGI/win32/12.5/bin\pgcnv.EXE" C:\Users\testUser\AppData\Local\Temp\pgfortran6eXGwtmkBStqx.obj "C:\Users\testUser\Documents\Visual Studio 2010\Projects\RRT-Build\BuildDir\lib\terrain_cell_class.obj"

"C:\Program Files (x86)\PGI/win32/12.5/bin\pgappend.EXE" -noerror "C:\Users\testUser\Documents\Visual Studio 2010\Projects\RRT-Build\BuildDir\lib\terrain_cell_class.obj" -name .IPDINFO C:\Users\testUser\AppData\Local\Temp\pgfortran3bzGwlNms5qlO.cmod -name .IPEINFO C:\Users\testUser\AppData\Local\Temp\pgfortran4cHGwJGruWe6e.cmdx
Unlinking C:\Users\testUser\AppData\Local\Temp\pgfortran2arGwZGOakh3p.ilm
Unlinking C:\Users\testUser\AppData\Local\Temp/pgfortran2arGwZGOakh3p.dbg
Unlinking C:\Users\testUser\AppData\Local\Temp\pgfortran3bzGwlNms5qlO.cmod
Unlinking C:\Users\testUser\AppData\Local\Temp\pgfortran4cHGwJGruWe6e.cmdx
Unlinking C:\Users\testUser\AppData\Local\Temp\pgfortran5dPGw7K9QTf2o.s
Unlinking C:\Users\testUser\AppData\Local\Temp\pgfortran6eXGwtmkBStqx.obj


Thanks,
John
Back to top
View user's profile
mkcolg



Joined: 30 Jun 2004
Posts: 6205
Location: The Portland Group Inc.

PostPosted: Tue Jun 05, 2012 1:23 pm    Post subject: Reply with quote

Hi John,

Quote:
This command caused windows to report that 'pgf901.exe' had stopped working. When I added the -v flag, however, the command executed and seemed to compile the file successfully.
The "-v" flag shouldn't effect the behavior of pgf901. The most likely cause is that we've got an uninitialized memory issue in the front-end compiler where small perpetuation in the environment will change the behavior.

Can you please send us (trs@pgroup,com) a reproducing example so we can investigate this issue?

Thanks,
Mat
Back to top
View user's profile
Display posts from previous:   
Post new topic   Reply to topic    PGI User Forum Forum Index -> Programming and Compiling All times are GMT - 7 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © phpBB Group