This is the mail archive of the
ecos-discuss@sources.redhat.com
mailing list for the eCos project.
TCP/IP write() buffering question
- To: ecos-discuss at sources dot redhat dot com
- Subject: [ECOS] TCP/IP write() buffering question
- From: Grant Edwards <grante at visi dot com>
- Date: Thu, 21 Sep 2000 07:52:01 -0500
I'm using the GoAhead web server under eCos and am using a
series of for loops in server-side JavaScript to fill in the
contents of a table.
The problem is that each JavaScript write() causes a write() on
the socket, and the web page data is sent as a large number of
Ethernet packets containing a small number of bytes of data
each: 50+ packets for a total of about 1500 bytes. This is
really killing the performance and results in a load time of 2
seconds for a page that's less than 2K of HTML.
Is there a way to get the stack to do more buffering of write()
data so that the page goes out as fewer packets?
I can re-write the JavaScript to do build up each row in the
table as a single string rather than writeing each cell
individually, but a more general solution would be better.
--
Grant Edwards
grante@visi.com