octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Yet another GUI releated thought


From: Przemek Klosowski
Subject: Re: Yet another GUI releated thought
Date: Fri, 9 May 2008 11:28:41 -0400 (EDT)

   > > If the GUI runs in a separate thread and Octave is not thread safe,
   >  > then how do you make the GUI responsive while Octave is off doing some
   >  > calculation?
   >
   >  What would you want a GUI to do while Octave is calculating? Start
   >  another parallel calculation? The GUI just needs to know that it Octave
   >  is busy, such that it doesn't start any new calculations.

One really useful function of the GUI is the variable watch window,
i.e. the ability to select ad-hoc and display the values of Octave
variables in real time during a calculation. Of course it's not a
deal-breaker, because one can always put some print statements in the
code---and even simulate the 'watch' window, e.g. via a function that
takes a bunch of variable names and prints their values in a fixed
layout so that one doesn't need to do saccades to track any specific
value.

If we agree that it's worth to have async peeking at values, I think
it already requires thread safety because octave variables don't have
to have constant memory addresses across their lifetime---right?
If so, then we might as well allow running arbitrary Octave code to
process the values for display. 

Now, a somehow ugly compromise might be to introduce synchronization
points, either implicit in the octave eval loop or explicit in user
code (process_gui_callbacks())



reply via email to

[Prev in Thread] Current Thread [Next in Thread]