perl 10^9 long strings of packed floats, getting 'panic: memory wrap'that didn't use to happen befor

Discussion in 'Perl Misc' started by pkoniusz@gmail.com, Dec 7, 2012.

  1. Guest

    Dear all.

    I've had a simple way of creating array of floats:
    my $xfArray=((pack "f1", 0.0) x $nSize);

    I was able to create up to 10^9 long arrays of floats and pass them to perl inline c for further processing.

    One beautiful day, I started getting message:
    panic: memory wrap at prepare_chisqr_fastG3.pl line 917.

    I thought this is due to fragmented memory on servers as some of them aren't rising this error. Then I tried ordinary MALLOC in C which was able always allocate the desired amount of memory.

    My question is what could have happened? I've been trying to allocate less than 10% of overall RAM available on my machine (148GB RAM) ... It works with MALLOC, does not with the above code any more ...

    This is the version of perl used:
    This is perl, v5.10.1 (*) built for x86_64-linux-gnu-thread-multi


    Any sugestions?

    Bests,
    P.
     
    , Dec 7, 2012
    #1
    1. Advertising

  2. Guest

    Re: perl 10^9 long strings of packed floats, getting 'panic: memorywrap' that didn't use to happen before

    I have no admin rights to compile perl and I guess I'd need them. What do you mean by getting function names? I'm not sure how this whole backtracing works in perl.

    > Are you able to get a backtrace? Ideally from a perl built with
    >
    > -DDEBUGGING, but if not you should at least be able to get function
    >
    > names.
    >
    >
    >
    > Ben
     
    , Dec 12, 2012
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Rolf Kemper
    Replies:
    1
    Views:
    739
    Dimitre Novatchev
    Oct 15, 2004
  2. Ti-Gui
    Replies:
    3
    Views:
    367
    Alexey Rusakov
    Oct 25, 2004
  3. Kosio

    Floats to chars and chars to floats

    Kosio, Sep 16, 2005, in forum: C Programming
    Replies:
    44
    Views:
    1,291
    Tim Rentsch
    Sep 23, 2005
  4. Anish Chapagain

    Parse error befor % token

    Anish Chapagain, Aug 13, 2008, in forum: Python
    Replies:
    0
    Views:
    292
    Anish Chapagain
    Aug 13, 2008
  5. jutta
    Replies:
    3
    Views:
    109
    jutta
    May 16, 2006
Loading...

Share This Page