Epoll optimisations
First Claim
1. A method for managing I/O event notifications in a data processing system, the data processing system comprising a plurality of applications and an operating system having a kernel and an I/O event notification mechanism operable to maintain a plurality of I/O event notification objects each handling a set of file descriptors associated with one or more I/O resources, the method comprising:
- for each of a plurality of application-level configuration calls;
a user-level interface intercepting a configuration call from an application to the I/O event notification mechanism for configuring an I/O event notification object; and
storing a set of parameters of the configuration call at a data structure, each set of parameters representing an operation on the set of file descriptors handled by the I/O event notification object;
intercepting at the user-level interface a wait call from the application to the I/O event notification mechanism for causing the I/O event notification object to wait for an event associated with one or more of its file descriptors;
subsequently, on a predetermined criterion being met, the user-level interface causing the plurality of configuration calls to be effected by making a single system call from the user level to the kernel,wherein the predetermined criterion is reception of a wait call from the application at the user-level interface, and wherein the predetermined criterion is additionally met if no wait call is received at the user-level interface but one of the following occurs;
a predetermined time period expires;
orstorage space required at the data structure for storing the sets of parameters representing operations to be performed on the set of file descriptors handled by the I/O event notification object exceeds a predetermined size.
12 Assignments
0 Petitions
Accused Products
Abstract
A method for managing I/O event notifications in a data processing system, the data processing system comprising a plurality of applications and an operating system having a kernel and an I/O event notification mechanism operable to maintain a plurality of I/O event notification objects each handling a set of file descriptors associated with one or more I/O resources, the method comprising: for each of a plurality of application-level configuration calls: intercepting at a user-level interface a configuration call from an application to the I/O event notification mechanism for configuring an I/O event notification object; and storing a set of parameters of the configuration call at a data structure, each set of parameters representing an operation on the set of file descriptors handled by the I/O event notification object; and subsequently, on a predetermined criterion being met: the user-level interface causing the plurality of configuration calls to be effected by means of a first system call to the kernel.
149 Citations
23 Claims
-
1. A method for managing I/O event notifications in a data processing system, the data processing system comprising a plurality of applications and an operating system having a kernel and an I/O event notification mechanism operable to maintain a plurality of I/O event notification objects each handling a set of file descriptors associated with one or more I/O resources, the method comprising:
-
for each of a plurality of application-level configuration calls; a user-level interface intercepting a configuration call from an application to the I/O event notification mechanism for configuring an I/O event notification object; and storing a set of parameters of the configuration call at a data structure, each set of parameters representing an operation on the set of file descriptors handled by the I/O event notification object; intercepting at the user-level interface a wait call from the application to the I/O event notification mechanism for causing the I/O event notification object to wait for an event associated with one or more of its file descriptors; subsequently, on a predetermined criterion being met, the user-level interface causing the plurality of configuration calls to be effected by making a single system call from the user level to the kernel, wherein the predetermined criterion is reception of a wait call from the application at the user-level interface, and wherein the predetermined criterion is additionally met if no wait call is received at the user-level interface but one of the following occurs; a predetermined time period expires;
orstorage space required at the data structure for storing the sets of parameters representing operations to be performed on the set of file descriptors handled by the I/O event notification object exceeds a predetermined size. - View Dependent Claims (2)
-
-
3. A data processing system comprising a CPU and memory,
the CPU having a plurality of applications executing thereon; -
the CPU further having an operating system executing thereon, the operating system having a kernel and an I/O event notification mechanism operable to maintain a plurality of I/O event notification objects each handling a set of file descriptors associated with one or more I/O resources; the CPU further configured to store in a data structure parameters of application-level configuration calls, each set of parameters representing an operation on the set of file descriptors handled by the I/O event notification object to which the respective configuration call is directed; and the CPU having a user-level interface executing thereon, the user-level interface configured to intercept a plurality of configuration calls from an application to the I/O event notification mechanism for configuring an I/O event notification object and store parameters of the configuration calls at the data structure, the user-level interface being further configured to intercept a wait call from the application to the I/O event notification mechanism for causing the I/O event notification object to wait for an event associated with one or more of its file descriptors; wherein the user-level interface is configured to, on a predetermined criterion being met, cause the plurality of configuration calls to be effected by passing at least part of the data structure into the kernel context and making a system call from the user level to the kernel, wherein the predetermined criterion is the reception of a wait call from the application at the user-level interface, and wherein the predetermined criterion is additionally met if no wait call is received at the user-level interface but one of the following occurs; a predetermined time period expires;
orthe storage space required at the data structure for storing the sets of parameters representing operations to be performed on the set of file descriptors handled by the I/O event notification object exceeds a predetermined size.
-
-
4. A method for managing I/O event notifications in a data processing system, the data processing system comprising a plurality of applications and an operating system having a kernel and an I/O event notification mechanism operable to maintain a plurality of I/O event notification objects each handling a set of file descriptors associated with one or more I/O resources, the method comprising:
-
a user-level interface receiving a plurality of application-level configuration calls from one or more applications toward the I/O event notification mechanism, each of the configuration calls including a respective set of parameters representing an operation on a set of file descriptors handled by an I/O event notification object of the I/O event notification mechanism of the operating system; the user-level interface receiving a wait call sent from an application toward the I/O event notification mechanism for causing the I/O event notification object to wait for an event associated with one or more of its file descriptors; in response to receipt of each particular one of the application-level configuration calls in the plurality of application-level configuration calls, the user-level interface storing at a data structure in user address space the set of parameters of the particular configuration call; subsequently, on a predetermined criterion being met, the user-level interface making a single system call from the user level to the kernel so as to pass the data structure to a kernel module; and the kernel module invoking a configuration routine of the I/O event notification mechanism for the sets of parameters stored in the data structure so as to configure the I/O event notification object in accordance with the configuration calls, wherein the predetermined criterion is the reception of a wait call from the application at the user-level interface and wherein the predetermined criterion is additionally met if no wait call is received at the user-level interface but one of the following occurs; a predetermined time period expires;
orstorage space required at the data structure for storing the sets of parameters representing operations to be performed on the set of file descriptors handled by the I/O event notification object exceeds a predetermined size. - View Dependent Claims (5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22)
-
-
23. A data processing system comprising a CPU and memory, the CPU having a plurality of applications executing thereon;
-
the CPU further having an operating system executing thereon, the operating system having a kernel and an I/O event notification mechanism operable to maintain a plurality of I/O event notification objects each handling a set of file descriptors associated with one or more I/O resources; the CPU having a user-level interface executing thereon, the user-level interface configured to receive a plurality of application-level configuration calls from one or more applications toward the I/O event notification mechanism, each of the configuration calls including a respective set of parameters representing an operation on a set of file descriptors handled by an I/O event notification object of the I/O event notification mechanism of the operating system; the user-level interface further configured to store at a data structure in user address space the set of parameters of each of the configuration calls in the plurality of application-level configuration calls; the user-level interface being further configured to receive a wait call sent from an application toward the I/O event notification mechanism for causing the I/O event notification objection to wait for an event associated with one or more of its file descriptors; the user-level interface further configured to, on a predetermined criterion being met, make a single system call from the user level to the kernel so as to pass to a kernel module the data structure having stored therein the sets of parameters of each of the configuration calls in the plurality of application-level configuration calls; and the kernel module configured to invoke a configuration routine of the I/O event notification mechanism for the sets of parameters stored in the data structure so as to configure the I/O event notification object in accordance with the configuration calls, wherein the predetermined criterion is the reception of a wait call from the application at the user-level interface and wherein the predetermined criterion is additionally met if no wait call is received at the user-level interface but one of the following occurs; a predetermined time period expires;
orthe storage space required at the data structure for storing the sets of parameters representing operations to be performed on the set of file descriptors handled by the I/O event notification object exceeds a predetermined size.
-
Specification