发明授权
- 专利标题: Method and apparatus for an improved bulk read socket call
- 专利标题(中): 用于改进大容量读取套接字呼叫的方法和装置
-
申请号: US11375785申请日: 2006-03-15
-
公开(公告)号: US07469296B2公开(公告)日: 2008-12-23
- 发明人: Herman Dietrich Dierks, Jr. , Vinit Jain , Agustin Mena III , Venkat Venkatsubra
- 申请人: Herman Dietrich Dierks, Jr. , Vinit Jain , Agustin Mena III , Venkat Venkatsubra
- 申请人地址: US NY Armonk
- 专利权人: International Business Machines Corporation
- 当前专利权人: International Business Machines Corporation
- 当前专利权人地址: US NY Armonk
- 代理商 Duke W. Yee; Herman Rodriguez; Wayne P. Bailey
- 主分类号: G06F15/16
- IPC分类号: G06F15/16 ; G06F3/06 ; H04L12/28 ; H04L12/56
摘要:
An apparatus and method for an improved bulk read socket call are provided. With the apparatus and method, a new field, so_rcvlen, is added to the socket structure that identifies the bulk read size requested by the user. The kernel of the prior art recv( ) function is also modified so that it sets the so_rcvlen to the size requested by the user prior to the recv( ) function going to sleep and waiting for the full data size requested by the user. A new flag, SP_MSGWAITALL, is also provided in the socket structure. In the TCP input processing, when data is received for a particular socket, the current setting of the SP_MSGWAITALL is checked. If the SP_MSGWAITALL flag is set, it is determined whether the amount of data stored in the socket receive buffer is less than the value of so_rcvlen. If not, the TCP input processing does not wake up the recv( ) thread. However, for every alternate segment, the TCP input processing sends back an acknowledgment (ACK). In the TCP output processing, when the SP_MSGWAITALL flag is set and the amount of data in the socket receive buffer is less than so_rcvlen, the full window is advertised. Once the TCP input processing determines that there is at least an amount of data in the socket receive buffer equal to the value of so_rcvlen, the TCP input processing will wake up the recv( ) thread and the SP_MSGWAITALL flag is reset.
公开/授权文献
信息查询