Re: ideas

From: Andres Kroonmaa <andre@dont-contact.us>
Date: Tue, 13 Jun 2000 00:56:19 +0200

On 12 Jun 2000, at 22:53, Henrik Nordstrom <hno@hem.passagen.se> wrote:

> > As the benefit, compared to fully threaded design, Squid current code
> > has absolutely predictable execution order, vs. absolutely unpredictable
> > with threads (unless you enforce order by other means).
>
> If you count filedescriptor number as predictable then yes.

 I meant execution order only.

> Most user-level threads implementations are also quite predictable with
> very simple schedulers (usually plain round-robin or FIFO).

 This has very little to do with predictable execution order, after first
 few mutex contentions this ordering is totally unpredictable.
 but thats unimportant. My point was more like you'd eventually need to
 enforce execution order you want yourself, which adds overhead. Current
 design has the only possible execution order "for free".

> > In general, it isn't very useful to split such task into separate
> > thread if execution of that task takes very little time and/or
> > overhead of scheduling that task is comparable to execution time.
> > Using async-io to read/write network sockets makes very little sense.
>
> No it doesn't.

 including how async-io is used now? hmm.

> Ok. Maybe I should repeat the process split suggestion I made:
>
> The idea behind this multi-process design is that each unit is self
> contained for the operations it performs. If a network I/O process dies
> and restarts then only the requests currently being processed by that
> process gets affected.

 Well, this reminds me lots of thought I've put into this matter back
 in '97. Today its of course outdated and at times funny to read, but
 I'd still back it. My version of multi-process design proposal was
 not very commented, so I'd risk to bring it up again:
   http://www.online.ee/~andre/squid/Devel/design.txt
 Not much details of course...

------------------------------------
 Andres Kroonmaa <andre@online.ee>
 Network Development Manager
 Delfi Online
 Tel: 6501 731, Fax: 6501 708
 Pärnu mnt. 158, Tallinn,
 11317 Estonia
Received on Mon Jun 12 2000 - 16:58:31 MDT

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:12:29 MST