thorpej 0585ce1489 Make insertion of data into socket buffers O(C):
* Keep pointers to the first and last mbufs of the last record in the
  socket buffer.
* Use the sb_lastrecord pointer in the sbappend*() family of functions
  to avoid traversing the packet chain to find the last record.
* Add a new sbappend_stream() function for stream protocols which
  guarantee that there will never be more than one record in the
  socket buffer.  This function uses the sb_mbtail pointer to perform
  the data insertion.  Make TCP use sbappend_stream().

On a profiling run, this makes sbappend of a TCP transmission using
a 1M socket buffer go from 50% of the time to .02% of the time.

Thanks to Bill Sommerfeld and YAMAMOTO Takashi for their debugging
assistance!
2002-07-03 19:06:47 +00:00
..

/*	$NetBSD: README.packet,v 1.4 1994/06/29 06:36:59 cgd Exp $	*/

/*
 * @(#)README.packet	8.1 (Berkeley) 6/10/93
 *
 *   X.25 NETWORK PACKET LEVEL:
 *
 *   This implementation is based on Recommentation X.25 as agreed at the 
 *   March 1976 and the February 1980  meetings of CCITT Study Group VII. 
 *   However, not all aspects are implemented. The following is a list of 
 *   features which are not yet or may never be implemented:
 *  
 *   1. D bit
 *   2. PVC
 *   3. fast select
 *  
 *
 *   Note: This implementation is for DTEs only.
 *
 *         Currently, only the 1976 verison is implemented.
 *
 *
 *   Date:          February, 1984
 *
 *   Author:        Gerald W. Neufeld
 *
 *   Installation:  Department of Computer Science
 *                  University of British Columbia
 *                  Vancouver, BC, CANADA
 *
 *   To Do:   	    Find some reasonable heuristic for piggybacking packet
 *		    level acks.
 *
 *   Bugs:	    Clear might be sent before data is all out.
 * 
 *   History:
 *
 */