Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Re^4: Does IO::Select work? Solution (busy loop)

by tye (Sage)
on Oct 25, 2012 at 13:16 UTC ( #1000862=note: print w/replies, xml ) Need Help??


in reply to Re^3: Does IO::Select work? Solution
in thread Does IO::Select work? Anywhere?

Just change the time-out, probably from 0 to "infinity" (which is likely represented by -1).

- tye        

  • Comment on Re^4: Does IO::Select work? Solution (busy loop)

Replies are listed 'Best First'.
Re^5: Does IO::Select work? Solution (busy loop)
by zentara (Archbishop) on Oct 25, 2012 at 15:42 UTC
    Tye, I didn't think you cared about anything I wrote!. :-) I tried -1 for infinity, and still 100% cpu. But I had the audacity to undefine infinity and it does the right thing. CPU usage is minimal.
    #Change: #my ($new_readable) = IO::Select->select($readable_handles, undef, und +ef, 0 ); # to my ($new_readable) = IO::Select->select($readable_handles, undef, unde +f, undef );
    and the server in Re: Does IO::Select work? Solution is the Holy Grail after all. No sysctl.ph needed. :-) Minimum cpu usage.

    I'm not really a human, but I play one on earth.
    Old Perl Programmer Haiku ................... flash japh

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1000862]
help
Chatterbox?
[Discipulus]: if you have a jpeg data: or as wise Corion said IM ca n read directly your handle
[Corion]: Meh. I get the feeling I should post a call-to-action for people to test their modules with the upcoming 5.26 (or 5.25.latest), as it seems that the smoke testers don't really weed out modules that fail without . in @INC
[Corion]: But without instructions on how to easily test things yourself, I don't think such a call to arms is helpful
[Corion]: (this post on nntp.perl.org / p5p makes it seem to me that smoke testers seem to have a blind spot there)

How do I use this? | Other CB clients
Other Users?
Others cooling their heels in the Monastery: (7)
As of 2017-03-27 08:02 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Should Pluto Get Its Planethood Back?



    Results (317 votes). Check out past polls.