Switching run-time contexts
mark at umcp-cs.UUCP
mark at umcp-cs.UUCP
Sat Feb 11 12:40:05 AEST 1984
You can look at the code C itself uses to set up the environment
it wants before calling the users "main" routine in
/usr/src/libc/csu/crt.s (at least on our 4.1bsd system).
10 lines of assembler does it.
Generally you won't have to do even this much--C carries around
no assumptions about the environment it is in except that there be a
stack.
--
Mark Weiser
UUCP: {seismo,allegra,brl-bmd}!umcp-cs!mark
CSNet: mark at umcp-cs ARPA: mark at maryland
More information about the Comp.unix.wizards
mailing list