Re: What is the cost of a system call(send the 2nd time)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Could you be a little more specific?

Do you want the cost of the entire call or just the time it takes to setup
the system call?

In the first case it will vary greatly. The fork() call will take much
longer than getpid() will. In the second you could look at system_call for
i386 and the equivalant on each platform.

Of course the system call itself probably isn't all you need to worry
about. The library being used to call the system call will also have its
own overhead and you will need to determine that as well. Librarys add
error checking, thread support, etc... So yes you could write your own
library with little overhead, but at the price of trusting that it will
be used properly and always receive valued parameters.



On Mon, 29 Apr 2002, Huo Zhigang wrote:

>  Howdy,
>
>  Now, I am trying to estimate what the cost of a system call, To be more accurate,
> how many instructions have to be executed in average.
>
>  To what extent dose the cost diff  among different platforms?
>
>  So many high-perf communication systems are implemented in user space, just to bypass
> all kinds of system calls. Could we make a thin system-call-layer to ease the life of
> guys in these efforts?
>
>
>  TIA.
>
> ------------------------------------------------------------------
>
>   I18n of linux is necessary now. I want to contribute to it.
>
>
> --
> Kernelnewbies: Help each other learn about the Linux kernel.
> Archive:       http://mail.nl.linux.org/kernelnewbies/
> FAQ:           http://kernelnewbies.org/faq/
>



--
Kernelnewbies: Help each other learn about the Linux kernel.
Archive:       http://mail.nl.linux.org/kernelnewbies/
FAQ:           http://kernelnewbies.org/faq/


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux