Job Processing

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Job Processing

Thomas D. Dean-2
In sh,

   do_first &
   so_some_other_things_while_do_first_is_running
   wait

The wait blocks until do_first completes.

Is it possible to do this in octave?  I don't need to interact with
'do_first' or get any results from it.  I just need to do some I/O while
'do_first' is running.

Tom Dean

_______________________________________________
Help-octave mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/help-octave
Reply | Threaded
Open this post in threaded view
|

Re: Job Processing

Carlo de Falco-2

> On 28 Aug 2017, at 22:17, Thomas D. Dean <[hidden email]> wrote:
>
> In sh,
>
>  do_first &
>  so_some_other_things_while_do_first_is_running
>  wait
>
> The wait blocks until do_first completes.
>
> Is it possible to do this in octave?  I don't need to interact with 'do_first' or get any results from it.  I just need to do some I/O while 'do_first' is running.
>
> Tom Dean

hhhmmm ...
AFAIK there is no way to do that directly, but I think you could
emulate that behaviour to some extent with parcellfun, e.g.:

c = {@do_first, @so_some_other_things_while_do_first_is_running};
a = {{args_to_do_first}, {args_to_so_some_other_things_while_do_first_is_running}};

parcellfun (2, @(c, a) feval (c, a{:}), c, a)

HTH,
c.



_______________________________________________
Help-octave mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/help-octave