From: kuznet@ms2.inr.ac.ru
To: dyp@perchine.com (Denis Perchine)
Cc: linux-kernel@vger.kernel.org
Subject: Re: Problems with kernel-2.2.19-6.2.7 from RH update for 6.2
Date: Thu, 23 Aug 2001 20:29:50 +0400 (MSK DST) [thread overview]
Message-ID: <200108231629.UAA06901@ms2.inr.ac.ru> (raw)
In-Reply-To: <20010823014559.38E6D1FD74@mx.webmailstation.com> from "Denis Perchine" at Aug 23, 1 11:32:47 am
Hello!
> > Where? httpd does not connect().
>
> For read/write. Although it is incorrect to compare as thttpd is serving =
> more=20
> than one connect.
It is even worse. Useless operation in data path. read/write will return
the error, if connection died in any case.
> > I see. If tuning is goal, it is right way. Amount of syscalls is the sa=
> me
> > as with alarm, but logic is cleaner.
>
> Logic with alarms will not work in multithreaded case.
I meaned _your_ logic is cleaner . :-)
> I assume that using SO_RCVTIME/SO_SNDTIME would be better in terms of=20
> performance.
Not very much. But code becomes simpler.
Select() is better sometimes, f.e. when program uses signals
(and glibc uses signals _internally_ when multithreaded, breaking lots
of things, do you know this? :-)). In this case you need to raclulate
remaining time to restart poll/read/write, linux select returns it.
> layer to use sync IP...
What is "sync"?
> be (approximately)? if we assume that I have lots of connects which trans=
> fers=20
> small amount of data in each (1-2K).
It depends. The advantage of read/write with SO_*TIMEO is that
in all 100% of cases data arrive in time or you send immeadiately
and appear in right place and do not waste cache and cycles to exit from
select and to enter to read/write. Also, select() is pretty
suboptimal.
Alexey
prev parent reply other threads:[~2001-08-23 16:30 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-08-19 18:01 Denis Perchine
2001-08-20 2:11 ` Alexey Kuznetsov
2001-08-20 18:52 ` Denis Perchine
2001-08-22 0:53 ` Alexey Kuznetsov
2001-08-23 4:32 ` Denis Perchine
2001-08-23 16:29 ` kuznet [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200108231629.UAA06901@ms2.inr.ac.ru \
--to=kuznet@ms2.inr.ac.ru \
--cc=dyp@perchine.com \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®