9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
* [9fans] APE select(2)
@ 2004-04-02  9:54 lucio
  2004-04-02 11:56 ` Charles Forsyth
  0 siblings, 1 reply; 5+ messages in thread
From: lucio @ 2004-04-02  9:54 UTC (permalink / raw)
  To: 9fans

I can't quite get my head around all the twists and turns of the APE
select(2) implementation, I seem to miss the big picture altogether.
Is there a brief description somewhere that will make it easier for me
to understand the source?

++L



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [9fans] APE select(2)
  2004-04-02  9:54 [9fans] APE select(2) lucio
@ 2004-04-02 11:56 ` Charles Forsyth
  0 siblings, 0 replies; 5+ messages in thread
From: Charles Forsyth @ 2004-04-02 11:56 UTC (permalink / raw)
  To: 9fans

/sys/src/ape/lib/ap/plan9/buf.prom
might help, if it's reasonably consistent with
the current implementation.


^ permalink raw reply	[flat|nested] 5+ messages in thread

* RE: [9fans] APE select(2)
  2004-04-02 13:40 ` lucio
@ 2004-04-02 13:49   ` rog
  0 siblings, 0 replies; 5+ messages in thread
From: rog @ 2004-04-02 13:49 UTC (permalink / raw)
  To: 9fans

> Now to do a little more digging.  Promela, unfortunately, I am not at
> all familiar with, but this may be an occasion to catch up.

it's well worth it.



^ permalink raw reply	[flat|nested] 5+ messages in thread

* RE: [9fans] APE select(2)
  2004-04-02 13:27 Trickey, Howard W (Howard)
@ 2004-04-02 13:40 ` lucio
  2004-04-02 13:49   ` rog
  0 siblings, 1 reply; 5+ messages in thread
From: lucio @ 2004-04-02 13:40 UTC (permalink / raw)
  To: 9fans

> With regards to the nfds test in the code given earlier, I agree that it seems that:
> 
> 	if(nfds >= OPEN_MAX)
> 		nfds = OPEN_MAX-1;
> 	for(i = 0; i<= nfds; i++)
> 
> should change to
> 
> 	if(nfds > OPEN_MAX)
> 		nfds = OPEN_MAX;
> 	for(i = 0; i< nfds; i++)
> 
Thanks, Howard, this improves things a little, enough to show promise.
It also gives me the confidence that I'm not completely out of my
depths.

Now to do a little more digging.  Promela, unfortunately, I am not at
all familiar with, but this may be an occasion to catch up.

++L



^ permalink raw reply	[flat|nested] 5+ messages in thread

* RE: [9fans] APE select(2)
@ 2004-04-02 13:27 Trickey, Howard W (Howard)
  2004-04-02 13:40 ` lucio
  0 siblings, 1 reply; 5+ messages in thread
From: Trickey, Howard W (Howard) @ 2004-04-02 13:27 UTC (permalink / raw)
  To: '9fans@cse.psu.edu'

I wrote the original APE select implementation, and the promela model below, but others have had their hands in it since, so it is likely that the promela model is out of date.

With regards to the nfds test in the code given earlier, I agree that it seems that:

	if(nfds >= OPEN_MAX)
		nfds = OPEN_MAX-1;
	for(i = 0; i<= nfds; i++)

should change to

	if(nfds > OPEN_MAX)
		nfds = OPEN_MAX;
	for(i = 0; i< nfds; i++)

- Howard

-----Original Message-----
From: Charles Forsyth [mailto:forsyth@terzarima.net]
Sent: Friday, April 02, 2004 6:56 AM
To: 9fans@cse.psu.edu
Subject: Re: [9fans] APE select(2)


/sys/src/ape/lib/ap/plan9/buf.prom
might help, if it's reasonably consistent with
the current implementation.


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2004-04-02 13:49 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-04-02  9:54 [9fans] APE select(2) lucio
2004-04-02 11:56 ` Charles Forsyth
2004-04-02 13:27 Trickey, Howard W (Howard)
2004-04-02 13:40 ` lucio
2004-04-02 13:49   ` rog

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).