mIRC Home    About    Download    Register    News    Help

Print Thread
#200706 10/06/08 08:03 AM
Joined: Sep 2003
Posts: 84
T
Babel fish
OP Offline
Babel fish
T
Joined: Sep 2003
Posts: 84
Hello there,

Why not using threading to read data like sockets or for other
things that usage loops?

Turbo_boy #200716 10/06/08 12:26 PM
Joined: Oct 2004
Posts: 8,330
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,330
Because mIRC is a single threaded application. You can't just drop in multithreading for sockets. It would require enough work that you might as well do the entire thing at the same time, which may be done in the future at some point, but wouldn't happen anytime soon.


Invision Support
#Invision on irc.irchighway.net
Turbo_boy #200733 10/06/08 10:16 PM
Joined: Oct 2003
Posts: 3,918
A
Hoopy frood
Offline
Hoopy frood
A
Joined: Oct 2003
Posts: 3,918
Event loops are better, since you can emulate threading without the added programming complexity. If your data processing gets too heavy, you can always move it into /timers to lessen the load-- which would be similar to spawning threads.


- argv[0] on EFnet #mIRC
- "Life is a pointer to an integer without a cast"

Link Copied to Clipboard