forums.silverfrost.com Forum Index forums.silverfrost.com
Welcome to the Silverfrost forums
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

START_PROCESS@ and CISSUE@
Goto page Previous  1, 2
 
Post new topic   Reply to topic    forums.silverfrost.com Forum Index -> Support
View previous topic :: View next topic  
Author Message
PaulLaidler
Site Admin


Joined: 21 Feb 2005
Posts: 7916
Location: Salford, UK

PostPosted: Sun Oct 09, 2022 8:31 am    Post subject: Reply with quote

CISSUE is a very old FTN77 routine that was superceded by START_PROCESS@ and START_PPROCESS@.

These in turn were superceded by the Fortran Standard EXECUTE_COMMAND_LINE.

After a new process has been spawned you have no control over what happens (either it runs or it fails) unless you provide some mechanism for the process to interact and communicate with the host.

All of these routines end up calling the Microsoft API called CreateProcess. There are various approaches to inter-process communication but none of them are easy to implement. Fortran users should probably opt first for creating a new thread rather than a new process (see START_THREAD@).
Back to top
View user's profile Send private message AIM Address
DanRRight



Joined: 10 Mar 2008
Posts: 2813
Location: South Pole, Antarctica

PostPosted: Mon Oct 31, 2022 4:21 am    Post subject: Reply with quote

EXECUTE_COMMAND_LINE works ok.

All other variants like cissue@, start_process@ etc in Help have to be marked as potentially error-prone when used with newer codes.
Back to top
View user's profile Send private message
PaulLaidler
Site Admin


Joined: 21 Feb 2005
Posts: 7916
Location: Salford, UK

PostPosted: Mon Oct 31, 2022 8:22 am    Post subject: Reply with quote

EXECUTE_COMMAND_LINE is preferred because it is a Fortran Standard intrinsic. Otherwise the various routines are equally safe. Very little goes on interally before a call to the Microsoft API CreateProcess.

Sometimes we are too quick to blame our tools rather than our own workmanship.
Back to top
View user's profile Send private message AIM Address
DanRRight



Joined: 10 Mar 2008
Posts: 2813
Location: South Pole, Antarctica

PostPosted: Wed Nov 02, 2022 4:23 am    Post subject: Reply with quote

Paul,
The code where i do that SISSUE@, START_PROCESS@ etc is very small and simple, it is almost impossible to make any tricky error there. The only where it is large - it is large in allocated memory and file sizes it loads. With small files all look OK, but the devilry starts with files become of few GB in size. Due to that when loading that much data code may catch some zombie (denormal) number and the code may attract some not immediately noticeable schizophrenia.

So eventually EXECUTE_COMMAND_LINE also broke... The only way all works now is by your last suggestion when i start EXECUTE_COMMAND_LINE in the additional thread.

If you want to catch this tricky undercover error, then i can try to prepare as small as possible demo. Currently it would require for you to install HDF5, so to avoid that i need to find another way to force the bug to reveal itself.
Back to top
View user's profile Send private message
PaulLaidler
Site Admin


Joined: 21 Feb 2005
Posts: 7916
Location: Salford, UK

PostPosted: Wed Nov 02, 2022 8:33 am    Post subject: Reply with quote

Dan

If you can make it easy for me then I will aim to look at it but it's not something that we should necessarily support.
Back to top
View user's profile Send private message AIM Address
Display posts from previous:   
Post new topic   Reply to topic    forums.silverfrost.com Forum Index -> Support All times are GMT + 1 Hour
Goto page Previous  1, 2
Page 2 of 2

 
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 © 2001, 2005 phpBB Group