Question about context switching on SPARC
Shun Yan Cheung
cheung at mathcs.emory.edu
Wed Dec 5 13:00:00 AEST 1990
I have two questions about the Sparc assembly instructions:
1. When is the WIM updated ? It seems to me that SAVE and RESTORE should
mark and unmark a window as used and unused respectively. In Cypress
Sparc User's guide, it seems to imply that one can implement many
``windowing policies'', which means that the OS is responsible for
maintaining WIM on window over and underflow. Is this guess right ?
2. I want to save context myself to implement a process based simulation
system, but there do not seem to be any user instructions for doing that.
To save context, I have to know how many windows are used by reading the
CWP in PSR, but RDPSR is privileged. What the deal here ? Or is there a
trap that I can call to save my register windows ? If so, is that 0x3
(ST_FLUSH_WINDOWS) ? What exactly does this trap do ? Other the one line
in the Sun 4 assembly language manual, I can't find other reference to
this trap.
Thanks in advance for any help.
Shun Yan Cheung | cheung at mathcs.emory.edu Internet
Emory University | {rutgers,ogicse,gatech}!emory!cheung UUCP
Dept of Math and CS | cheung at emory.bitnet BITNET
Atlanta, GA 30322 | (404) 727-3823
More information about the Comp.sys.sun
mailing list