<div dir="ltr"><div class="gmail_default" style="font-family:arial,helvetica,sans-serif">To satisfy my curiosity and to provide further info for anyone viewing list archives, I benchmarked assigning a new table() vs. running clear_table() on tables of various sizes &amp; complexities.  Assigning a new table() was clearly the winner by a huge margin.</div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif"><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif">It should be noted that these two methods are not completely equivalent. I run a script where a current table is periodically moved to an old table, and the current table cleared for further use.  So, with A &amp; B being tables of the same type:</div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif"><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif">B = A;</div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif">A = table();</div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif"><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif">works as intended, as B now contains the prior contents of A, and A is a new empty table.<br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif"><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif">B = A;</div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif">clear_table(A);</div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif"><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif">clears both, as they both point to the same table.<br></div></div><br><div class="gmail_quote"><div dir="ltr">On Thu, Dec 6, 2018 at 4:17 PM Vern Paxson &lt;<a href="mailto:vern@corelight.com">vern@corelight.com</a>&gt; wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">&gt; I believe the clear_table() function still exists in zeek, as well...<br>
<br>
Hah^2!  Yeah, it does.  Well, glad I consulted the list before diving into<br>
some hacking :-P.<br>
<br>
                Vern<br>
</blockquote></div>