Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical
 
PerlMonks  

Reduce CPU utilization time in reading file using perl

by madtoperl (Monk)
on Sep 27, 2013 at 16:07 UTC ( #1056015=perlquestion: print w/ replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    tie @lines, 'Tie::File', "testfile.dat" or die "Can't read file: $!\n"
    +;
    $linecount = $#lines+1;
    ...
            $hash{$No.$date} = $type."@".$No."@".$date;
    }
    untie @lines;
    
  2. or download this
    
    PROCESS TIME
    ...
    
    PID     COMMAND           %CPU  TIME      #TH   #WQ   #PORT #MREGS RPR
    +VT   RSHRD   RSIZE   VPRVT   VSIZE   PGRP   PPID   STATE     UID   FA
    +ULTS    COW      MSGSENT     MSGRECV     SYSBSD     SYSMACH     CSW  
    +     PAGEINS KPRVT   KSHRD   USER
    perl5.12          99.9  00:08.58  1/1   0     22    56+    99M+    124
    +4K 
    

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://1056015]
Front-paged by Corion
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (8)
As of 2014-11-24 22:01 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My preferred Perl binaries come from:














    Results (147 votes), past polls