Don't forget to set `runtime' in fork_trampoline(). The time slice before
switching to a child for the first time was being counted twice. I think this only affected unimportant statistics. Simplified arg handling in fork_trampoline(). splz() doesn't actually smash the registers of interest.
This commit is contained in:
parent
5afcddae37
commit
d12ee02d12
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=24900
@ -30,7 +30,7 @@
|
||||
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* $Id: exception.s,v 1.22 1997/04/07 07:15:48 peter Exp $
|
||||
* $Id: exception.s,v 1.23 1997/04/07 11:42:09 peter Exp $
|
||||
*/
|
||||
|
||||
#include "npx.h" /* NNPX */
|
||||
@ -251,14 +251,14 @@ IDTVEC(int0x80_syscall)
|
||||
jmp _doreti
|
||||
|
||||
ENTRY(fork_trampoline)
|
||||
pushl %ebx /* splz smashes regs */
|
||||
pushl %esi
|
||||
|
||||
movl $SWI_AST_MASK,%eax /* spl0() */
|
||||
movl %eax,_cpl
|
||||
movl $SWI_AST_MASK,_cpl
|
||||
call _splz
|
||||
|
||||
popl %esi /* arg1 */
|
||||
pushl $_runtime
|
||||
call _microtime
|
||||
popl %eax
|
||||
|
||||
pushl %ebx /* arg1 */
|
||||
call %esi /* function */
|
||||
addl $4,%esp
|
||||
/* cut from syscall */
|
||||
|
@ -30,7 +30,7 @@
|
||||
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* $Id: exception.s,v 1.22 1997/04/07 07:15:48 peter Exp $
|
||||
* $Id: exception.s,v 1.23 1997/04/07 11:42:09 peter Exp $
|
||||
*/
|
||||
|
||||
#include "npx.h" /* NNPX */
|
||||
@ -251,14 +251,14 @@ IDTVEC(int0x80_syscall)
|
||||
jmp _doreti
|
||||
|
||||
ENTRY(fork_trampoline)
|
||||
pushl %ebx /* splz smashes regs */
|
||||
pushl %esi
|
||||
|
||||
movl $SWI_AST_MASK,%eax /* spl0() */
|
||||
movl %eax,_cpl
|
||||
movl $SWI_AST_MASK,_cpl
|
||||
call _splz
|
||||
|
||||
popl %esi /* arg1 */
|
||||
pushl $_runtime
|
||||
call _microtime
|
||||
popl %eax
|
||||
|
||||
pushl %ebx /* arg1 */
|
||||
call %esi /* function */
|
||||
addl $4,%esp
|
||||
/* cut from syscall */
|
||||
|
@ -30,7 +30,7 @@
|
||||
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* $Id: exception.s,v 1.22 1997/04/07 07:15:48 peter Exp $
|
||||
* $Id: exception.s,v 1.23 1997/04/07 11:42:09 peter Exp $
|
||||
*/
|
||||
|
||||
#include "npx.h" /* NNPX */
|
||||
@ -251,14 +251,14 @@ IDTVEC(int0x80_syscall)
|
||||
jmp _doreti
|
||||
|
||||
ENTRY(fork_trampoline)
|
||||
pushl %ebx /* splz smashes regs */
|
||||
pushl %esi
|
||||
|
||||
movl $SWI_AST_MASK,%eax /* spl0() */
|
||||
movl %eax,_cpl
|
||||
movl $SWI_AST_MASK,_cpl
|
||||
call _splz
|
||||
|
||||
popl %esi /* arg1 */
|
||||
pushl $_runtime
|
||||
call _microtime
|
||||
popl %eax
|
||||
|
||||
pushl %ebx /* arg1 */
|
||||
call %esi /* function */
|
||||
addl $4,%esp
|
||||
/* cut from syscall */
|
||||
|
Loading…
Reference in New Issue
Block a user