[so] [Tema4] Operatii asincrone

cosminratiu at gmail.com cosminratiu at gmail.com
Wed Dec 12 00:05:36 EET 2007


Evident, sincrone. Clientul nu are motiv sa multiplexeze nimic.

On Dec 12, 2007 12:02 AM, Silviu-Ionut Ganceanu <silviug at gmail.com> wrote:

> E ok daca operatiile I/O din client sunt sincrone (blocante)? Personal nu
> vad niciun motiv pentru care ar fi altcumva...
>
>
> On Dec 10, 2007 8:49 PM, Dragos Sbarlea < sbarlead at yahoo.com> wrote:
>
> > Yup, dar, din ce am citit POSIX spune ca fcntl se foloseste pentru
> > asta...
> >
> > Dragos Dumitru Sbîrlea
> > Facultatea de Automatica si Calculatoare
> > Universitatea Politehnica din Bucuresti
> >
> >
> > ----- Original Message ----
> > From: "cosminratiu at gmail.com" <cosminratiu at gmail.com >
> > To: Sisteme de Operare <so at cursuri.cs.pub.ro>
> > Sent: Monday, 10 December, 2007 8:31:14 PM
> > Subject: Re: [so] [Tema4] Operatii asincrone
> >
> > Mai simplu este cu ioctl cu FIONBIO, asa cum e in laborator.
> >
> > //puts a socket in nonblocking mode
> > void set_nonblocking(int s)
> > {
> > 	int m = 1;
> > 	ioctl(s, FIONBIO, &m);
> > }
> >
> >
> >
> > On Dec 10, 2007 7:19 PM, Dragos Sbarlea <sbarlead at yahoo.com> wrote:
> >
> > > Ca sa fim chitibusari  (sau iubitori de corectitudine) ar trebui mai
> > > intai sa luam flagurile curente (F_GETFL) pentru socket si apoi sa adaugam
> > > flagul O_NONBLOCK. :)
> > >
> > > Cum celelalte flaguri nu prea se pot folosi la socketi cred ca  e ok
> > > si asa, dar cine stie...
> > >
> > >  Dragos Dumitru Sbîrlea
> > > Facultatea de Automatica si Calculatoare
> > > Universitatea Politehnica din Bucuresti
> > >
> > > ----- Original Message ----
> > > From: Iulian Moraru <iulian at gmail.com>
> > > To: Sisteme de Operare <so at cursuri.cs.pub.ro>
> > > Sent: Monday, 10 December, 2007 2:00:58 PM
> > > Subject: Re: [so] [Tema4] Operatii asincrone
> > >
> > > On Dec 10, 2007 1:40 PM, Alexandru-Mihai Carp < carpalex at gmail.com>
> > > wrote:
> > > > Lucian Adrian Grijincu wrote:
> > > > >
> > > > > Pentru socketi trebuie folosite operatii non-blocante.
> > > > >
> > > > >
> > > > Pai read / write sau recv / send sunt blocante, daca nu stim cat
> > > avem de
> > > > trimis / primit.
> > > > Singura modalitatate de a fi non-blocante e sa ne asiguram ca nu
> > > citim
> > > > mai mult decat ni s-a trimis, nu?
> > >
> > > Faci ca socketul sa fie non-blocant cu fcntl, comanda F_SETFL si
> > > flagul O_NONBLOCK. Pe urma read, write, send si recv se vor comporta
> > > diferit (cauta EAGAIN in paginile lor de manual).
> > >
> > > Iulian
> > >
> > >
> > >
> > > > _______________________________________________
> > > > so mailing list
> > > > so at cursuri.cs.pub.ro
> > > > http://cursuri.cs.pub.ro/cgi-bin/mailman/listinfo/so
> > > >
> > > _______________________________________________
> > > so mailing list
> > > so at cursuri.cs.pub.ro
> > > http://cursuri.cs.pub.ro/cgi-bin/mailman/listinfo/so
> > >
> > >
> > > ------------------------------
> > > Support the World Aids Awareness campaign this month with Yahoo! for
> > > Good<http://us.rd.yahoo.com/mailuk/taglines/isp/control/*http://us.rd.yahoo.com/evt=51947/*http://uk.promotions.yahoo.com/forgood/>
> > >
> > > _______________________________________________
> > > so mailing list
> > > so at cursuri.cs.pub.ro
> > > http://cursuri.cs.pub.ro/cgi-bin/mailman/listinfo/so
> > >
> > >
> >
> >
> > ------------------------------
> > Support the World Aids Awareness campaign this month with Yahoo! for
> > Good<http://us.rd.yahoo.com/mailuk/taglines/isp/control/*http://us.rd.yahoo.com/evt=51947/*http://uk.promotions.yahoo.com/forgood/>
> >
> > _______________________________________________
> > so mailing list
> > so at cursuri.cs.pub.ro
> > http://cursuri.cs.pub.ro/cgi-bin/mailman/listinfo/so
> >
> >
>
> _______________________________________________
> so mailing list
> so at cursuri.cs.pub.ro
> http://cursuri.cs.pub.ro/cgi-bin/mailman/listinfo/so
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://cursuri.cs.pub.ro/pipermail/so/attachments/20071212/3e425e39/attachment.html


More information about the so mailing list