[openbeos] Kernel/app_server req #768 - suspend/resume

  • From: Zenja Solaja <solaja@xxxxxxxxxx>
  • To: openbeos@xxxxxxxxxxxxx
  • Date: Wed, 3 Apr 2002 08:05:59 +1000

Here is a suggestion for the Kernel and App_server teams.

Suggestion:
Allow the user to Suspend/Resume a process/team.  The Schedular does not
schedule a 'suspended' process.  Once the user sends a 'resume' signal, the
process changes state to 'Ready' which means that the schedular may schedule
the process.

Methodology:
a) via command line interface, and commands 'suspend pid' and 'resume pid'
(or team)
b) via an extra button on every windows title bar (green/yellow button).
Pressing this button sends a 'suspend' signal to the app_server/kernel, and
pressing it again sends a 'resume' signal.
c) via the deskbar.  Along with the entries 'show all', 'minimise all' etc
insert a mutually exclusive 'suspend/resume'.

Purpose:
In the everyday use of the machine, a user may activate two resource
intensive applications.  An example would be copying a large file from one
drive to another, while at the same time emptying over 1000 files in the
Trash.  We've all experienced hard disk thrashing due to 2 processes
competing for resources.  With the ability to suspend a task, we can
eliminate the disk thrashing.  CPU hogging apps can also temporarily be
suspended to allow for a more urgent tasks to be complete.  This allows the
user to have 'complete' control over their PC's.

Issues:
Scenario: user suspends task, then decides to quit.  Do we 'resume' then
'quit'?
Scenario: user resumes task.  System needs to keep track of thread states
prior to suspension (we dont want to set the state to 'ready' if the thread
was previously 'waiting' or 'suspended'.
Scenario: user suspends multimedia task.  An audio tone may continue playing
indefinately until the envelope drops.

Implementation:
I'm familiar with XINU and its processes can be 'suspended'.  I dont see a
reason why NewOS couldn't do it.  The App_server needs to attach a new
button to each windows title bar, and direct these messages to the kernel.
OpenDeskbar also needs to add a new menufield.  

R1 or R2 material?  Do you like it?  Discuss.


----------------------
CONFIDENTIALITY NOTICE
----------------------
This email is intended only to be read or used by the addressee.
The information contained in this e-mail message may be confidential
information. If you are not the intended recipient, any use, interference
with, distribution, disclosure or copying of this material is unauthorised
and prohibited. Confidentiality attached to this communication is not waived
or lost by reason of the mistaken delivery to you.

If you have received this message in error, please delete it and notify us
by return e-mail or telephone Aristocrat Technologies Australia Pty Limited
on +61 2 9413 6300.

Other related posts: