use 5.010; use strict; use warnings; use Benchmark; use Encode; use HTTP::Lite; use LWP::UserAgent; my $url = 'xxx.yyy.zzz/file.dat'; sub http_lite { my $r = HTTP::Lite->new; my $sts = $r->request($url); die "failed" if $sts != 200; my $decoded = Encode::decode('utf8', $r->body, Encode::FB_CROAK); } sub lwp_useragent{ my $ua = LWP::UserAgent->new; my $r = $ua->get($url); die "failed" if !$r->is_success; my $body = $r->decoded_content; } timethese(1000, { 'lite' => sub{http_lite()}, 'lwp' => sub{lwp_useragent()} }); Benchmark: timing 1000 iterations of lite, lwp... lite: 3 wallclock secs ( 1.53 usr + 0.60 sys = 2.13 CPU) @ 469.48/s (n=1000) lwp: 6 wallclock secs ( 4.19 usr + 0.58 sys = 4.77 CPU) @ 209.64/s (n=1000)