<div dir="ltr">Enjoyed this thread...<div><br></div><div>So passing $hash{key} is expensive because it does a copy of the hash but passing $hash_ref-&gt;{key} stops the expensive copy operation.</div><div class="gmail_extra">
<br><br><div class="gmail_quote">On 12 April 2013 06:40, Andrew Gould <span dir="ltr">&lt;<a href="mailto:andrewlylegould@gmail.com" target="_blank">andrewlylegould@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div dir="ltr"><div class="im">On Thu, Apr 11, 2013 at 3:37 PM, Lonni J Friedman <span dir="ltr">&lt;<a href="mailto:netllama@gmail.com" target="_blank">netllama@gmail.com</a>&gt;</span> wrote:<br></div><div class="gmail_extra">
<div class="gmail_quote"><div class="im">
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">I figured this out.  It was definitely the hash table lookups that<br>
were the problem.  Or more accurately, the fact that I was passing the<br>
entire hash table into the subroutine thousands of times, which meant<br>
it was being copied thousands of times.  I switched to using a<br>
hashref, and that cut the processing time from hours to a few minutes.<br>
<div><div><br></div></div></blockquote><div><br></div></div><div>Yeah! </div></div></div></div>
<br>_______________________________________________<br>
Linux-users mailing list<br>
<a href="mailto:Linux-users@linux-sxs.org">Linux-users@linux-sxs.org</a><br>
<a href="http://mailman.celestial.com/mailman/listinfo/linux-users" target="_blank">http://mailman.celestial.com/mailman/listinfo/linux-users</a><br>
<br></blockquote></div><br></div></div>