G'day hv,

++ Thanks for your response.

"What happens if you try to call it?"

A common alias of mine:

$ alias perle alias perle='perl -Mstrict -Mwarnings -Mautodie=:all -MCarp::Always -E +'

I originally just tried to import it. My code crashed at that point; like this:

$ perle 'use Judy::HS "MemUsed"'; "MemUsed" is not exported by the Judy::HS module at /home/ken/perl5/pe +rlbrew/perls/perl-5.36.0/lib/site_perl/5.36.0/Sub/Exporter.pm line 77 +8. Sub::Exporter::_do_import(HASH(0xa003f6ab8), ARRAY(0xa005d7d00 +)) called at /home/ken/perl5/perlbrew/perls/perl-5.36.0/lib/site_perl +/5.36.0/Sub/Exporter.pm line 744 Sub::Exporter::__ANON__("Judy::HS", "MemUsed") called at -e li +ne 1 main::BEGIN() called at -e line 1 eval {...} called at -e line 1 BEGIN failed--compilation aborted at -e line 1.

I basically took the documentation at face value and assumed that I needed something in addition to libJudy. However, I now see that a fully-qualified name will access it:

$ perle 'use Judy::HS "Set"; my $judy; Set($judy, Key => 42); say Judy +::HS::MemUsed($judy);' 59
"I took a brief look at the code, and it looks buggy ... If you're happy to run a patched version, I can provide a one-line fix for the obviously buggy case."

I've just been tinkering with it; comparing $judy with %hash. I've written some basic benchmarks to test speed; I looked into some of the Unicode issues raised in Judy::Mem; and was planning to do a size comparison as well. Depending on how all of that panned out, I had some tentative thoughts on other aspects to investigate.

Some of my $work involves biological data which, as I'm sure you're aware, can be huge and require long processing times. I'm always on the lookout for more bang-for-your-buck in this area. Having said that, given your comment that "it looks buggy", and the fact that it appears to be abandonware, I'm wondering if this is worth pursuing. In light of that, while I very much appreciate your offer of supplying a patch, I think I need to give some serious consideration as to whether I'll continue with Judy & Co. before taking you up on that.

— Ken


In reply to Re^2: Size of Judy::HS array: where is MemUsed()? by kcott
in thread Size of Judy::HS array: where is MemUsed()? by kcott

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.