[Qt-interest] readyRead() SIGNAL question
"Alexander Carôt"
alexander_carot at gmx.net
Thu May 20 10:31:16 CEST 2010
Hi Thiago,
thanks a lot for the response, which confirms my guess that there actually isn't any scheduling involved. However, the context is rather complex and I basically cannot get rid of the threads. I will further investigate the problem and will most likely get back later.
Thanks for you help so far.
Best regards
-- A l e x
-------- Original-Nachricht --------
> Datum: Wed, 19 May 2010 16:41:43 +0200
> Von: Thiago Macieira <thiago at kde.org>
> An: qt-interest at trolltech.com
> Betreff: Re: [Qt-interest] readyRead() SIGNAL question
> Em Quarta-feira 19 Maio 2010, às 16:24:46, Alexander Carôt escreveu:
> > Hi all,
> >
> > I have connected the readyRead() SIGNAL of a QUdpSocket to a respective
> > SLOT function:
> >
> > connect(dFC->send, SIGNAL( readyRead() ), rec, SLOT( receiverSlot() ) );
> >
> > In that context I discovered something strange: When running an
> application
> > with numerous threads I have the impression that receiverSlot is not
> > triggered as immediately anymore as without the threads. In that context
> I
> > am wondering if the network receiverSlot is triggered with realtime
> > scheduling priority or do I possibly need to apply additional calls in
> > order to achieve that ?
>
> There's no such thing as scheduling.
>
> The signal is emitted as soon as data is read from the network, which
> happens
> when the event loop runs. If the event loop is prevented from running, for
> whatever reason, the signal will not be emitted.
>
> You also mentioned threads, so it might be that you placed the object in
> the
> wrong thread, so you're facing two more problems: 1) the wrong event loop
> is
> doing the networking I/O and 2) the delivery of the signal goes through a
> queued connection.
>
> I recommend you remove the threads.
>
> --
> Thiago Macieira - thiago (AT) macieira.info - thiago (AT) kde.org
> Senior Product Manager - Nokia, Qt Development Frameworks
> PGP/GPG: 0x6EF45358; fingerprint:
> E067 918B B660 DBD1 105C 966C 33F5 F005 6EF4 5358
--
http://www.carot.de
http://www.triologue.de
Email : Alexander at Carot.de
Tel.: +49 (0)177 5719797
GRATIS für alle GMX-Mitglieder: Die maxdome Movie-FLAT!
Jetzt freischalten unter http://portal.gmx.net/de/go/maxdome01
More information about the Qt-interest-old
mailing list