-$ echo $? 139

139 - 128 = 11, which is SIGSEGV on my system (kill -l will identify). So we know it really was a segfault.

i am not aware of debugging perl core using GDB

Same way as any other program.

$ gdb --args perl -e'dump' GNU gdb 6.8-debian Copyright (C) 2008 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gp +l.html> This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Type "show copy +ing" and "show warranty" for details. This GDB was configured as "i486-linux-gnu"... (no debugging symbols found) (gdb) run Starting program: /usr/bin/perl -edump (no debugging symbols found) (no debugging symbols found) (no debugging symbols found) (no debugging symbols found) (no debugging symbols found) [Thread debugging using libthread_db enabled] (no debugging symbols found) (no debugging symbols found) [New Thread 0xb7cfd8c0 (LWP 7206)] Program received signal SIGABRT, Aborted. [Switching to Thread 0xb7cfd8c0 (LWP 7206)] 0xb7eea424 in __kernel_vsyscall () (gdb) bt #0 0xb7eea424 in __kernel_vsyscall () #1 0xb7d5b956 in kill () from /lib/i686/cmov/libc.so.6 #2 0x080a9e3b in Perl_my_unexec () #3 0x080ec065 in Perl_pp_goto () #4 0x080b1879 in Perl_runops_standard () #5 0x080ac6a0 in perl_run () #6 0x08063ddd in main () (gdb) q The program is running. Exit anyway? (y or n) y

not yet. but installing a new version in professional env is very difficult as i need to get sign off from lot of people.

You don't need to replace the system Perl. You can install it in a temporary directory somewhere.

Unzip Perl in a clean directory and run the following:

sh Configure -des -Doptimize="-g" -Dprefix=$HOME/tmp_perl make make test make install

-Doptimize="-g" makes it a debug build, which isn't good for production, but good for finding problems inside of Perl itself.

-$ perl -v This is perl, v5.8.0 built for aix

Hum, I hear that 5.8.0 was a pretty bad version. 5.8.1 was better, and so much has been fixed since then.

#!/usr/local/perl-5.6.1/bin/perl

Wait, no, you're not using 5.8.0, you're using something even older!

And the 64-bit version appears to use 5.8.2. That could explain the difference. Or maybe not.


In reply to Re^3: 32 Bit Perl causing segmentation fault if data is big by ikegami
in thread 32 Bit Perl causing segmentation fault if data is big by peacelover1976

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.