Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 12 Aug 2004 19:06:05 -0700 (PDT)
From:      Matthew Dillon <dillon@apollo.backplane.com>
To:        gerarra@tin.it
Cc:        freebsd-hackers@freebsd.org
Subject:   Re: Interrupt 0x80 handling
Message-ID:  <200408130206.i7D265rq005367@apollo.backplane.com>
References:  <4119722900001B0D@ims3a.cp.tin.it>

next in thread | previous in thread | raw e-mail | index | archive | help

:Hi,
:giving a look to interrupt 0x80 handling code (i386/i386/exception.s), I've
:met FAKE_MCOUNT/MEXITCOUNT system. FAKE_MCOUNT in the end calls _mcount
:(libkern/mcount.c) function which seems to be used for profiling purposes
:IMHO. It seems (reading comments in sys/gmon.h) that sysctl could be used
:to manage syscall profiling (kernel profiling?): Somebody can confirm that
:or I've misunderstood? I would like to know another thing too: why interrupt
:0x80 handler is implemented through a trap gate? An interrupt gate could
:not be more logical?
:
:thanks for answers,
:cheers
:
:rookie

    An interrupt gate will disable interrupts on entry (cli equivalent),
    while a trap gate does not.  There is no reason to disable interrupts
    in a system call so a trap gate is used. 

						-Matt



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200408130206.i7D265rq005367>