* [Linux-ia64] static registers during a context switch
@ 2000-10-25 2:47 riedel
2000-10-25 10:16 ` Doug Rabson
2000-10-25 14:28 ` Don Dugger
0 siblings, 2 replies; 3+ messages in thread
From: riedel @ 2000-10-25 2:47 UTC (permalink / raw)
To: linux-ia64
[-- Attachment #1: Type: text/plain, Size: 399 bytes --]
hi everybody,
does anybody know what happens to static registers (gr0-gr31) in case of a context switch.
in the manual, it says static registers are visible to all procedures(i guess it shouldn't otherwise on a context switch another process would have the same static registers) On the other hand, stacked registers are local to procedures and saved and restored by RSE which makes sense to me.
[-- Attachment #2: Type: text/html, Size: 795 bytes --]
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [Linux-ia64] static registers during a context switch
2000-10-25 2:47 [Linux-ia64] static registers during a context switch riedel
@ 2000-10-25 10:16 ` Doug Rabson
2000-10-25 14:28 ` Don Dugger
1 sibling, 0 replies; 3+ messages in thread
From: Doug Rabson @ 2000-10-25 10:16 UTC (permalink / raw)
To: linux-ia64
On Tue, 24 Oct 2000, riedel wrote:
> hi everybody, does anybody know what happens to static registers
> (gr0-gr31) in case of a context switch. in the manual, it says static
> registers are visible to all procedures(i guess it shouldn't otherwise
> on a context switch another process would have the same static
> registers) On the other hand, stacked registers are local to
> procedures and saved and restored by RSE which makes sense to me.
Normally on a context switch, only the callee saved registers are
preserved (since the context switch appears as a function call to the
process which initiates it). In the case of ia64, this means that gr4-gr7
are preserved from the static register set.
--
Doug Rabson Mail: dfr@nlsystems.com
Phone: +44 20 8348 6160
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [Linux-ia64] static registers during a context switch
2000-10-25 2:47 [Linux-ia64] static registers during a context switch riedel
2000-10-25 10:16 ` Doug Rabson
@ 2000-10-25 14:28 ` Don Dugger
1 sibling, 0 replies; 3+ messages in thread
From: Don Dugger @ 2000-10-25 14:28 UTC (permalink / raw)
To: linux-ia64
If you are thinking of a context switch in the sense of switching
from one process to another then ALL registers, static and stacked,
are saved and restored. If you are talking about making a subroutine
call then the uses of the static registers are covered by software
convention and registers R4-R7 are preserved across a function call.
Conceptually the static registers are similar to the X86 registers
EAX, EBX and so on. These registers are also saved and restored
across context switches and have software conventions that control
which ones are saved across subroutine calls.
On Tue, Oct 24, 2000 at 09:47:41PM -0500, riedel wrote:
> hi everybody,
> does anybody know what happens to static registers (gr0-gr31) in case of a context switch.
> in the manual, it says static registers are visible to all procedures(i guess it shouldn't otherwise on a context switch another process would have the same static registers) On the other hand, stacked registers are local to procedures and saved and restored by RSE which makes sense to me.
--
Don Dugger
"Censeo Toto nos in Kansa esse decisse." - D. Gale
n0ano@valinux.com
Ph: 303/938-9838
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2000-10-25 14:28 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2000-10-25 2:47 [Linux-ia64] static registers during a context switch riedel
2000-10-25 10:16 ` Doug Rabson
2000-10-25 14:28 ` Don Dugger
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox