Bug#719835: Devel::FindRef broken on perl >= 5.17.4

Niko Tyni ntyni at debian.org
Fri Aug 16 10:44:15 UTC 2013


Hi Marc,

not sure if you're already aware of this, but Devel-FindRef is broken
on newer Perls. As it doesn't have much of a test suite, we only noticed
this because the Test-Refcount test suite is failing.

I bisected this to perl5 commit v5.17.3-43-gb70d555:
 http://perl5.git.perl.org/perl.git/commit/b70d55581aad461af858eb07a2e80ed5fcc653c1

 commit b70d55581aad461af858eb07a2e80ed5fcc653c1
 Author: Father Chrysostomos <sprout at cpan.org>
 Date:   Wed Aug 15 22:27:54 2012 -0700

    Use PADLIST in more places
    
    Much code relies on the fact that PADLIST is typedeffed as AV.
    PADLIST should be treated as a distinct type.

and there's a relevant entry in perl5180delta:

   "PADLIST"s are now longer "AV"s, but their own type instead.
     "PADLIST"s now contain a "PAD" and a "PADNAMELIST" of "PADNAME"s,
     rather than "AV"s for the pad and the list of pad names.  "PAD"s,
     "PADNAMELIST"s, and "PADNAME"s are to be accessed as such through
     the newly added pad API instead of the plain "AV" and "SV" APIs.
     See perlapi for details.

I can reduce the failure to just
 perl -MDevel::FindRef -le 'print Devel::FindRef::track {}'
 Segmentation fault (core dumped)

and the backtrace is

  Core was generated by `perl -Iblib/lib -Iblib/arch -MDevel::FindRef -le print Devel::FindRef::track {}'.
  Program terminated with signal 11, Segmentation fault.
  #0  0x00007f06c2c6a1f0 in XS_Devel__FindRef_find_ (my_perl=0xf8b010, cv=0x105caf8) at FindRef.xs:172
  172                                       if (AvARRAY (pad)[0] == targ)
  (gdb) bt
  #0  0x00007f06c2c6a1f0 in XS_Devel__FindRef_find_ (my_perl=0xf8b010, cv=0x105caf8) at FindRef.xs:172
  #1  0x00007f06c3e38066 in Perl_pp_entersub () from /usr/lib/libperl.so.5.18
  #2  0x00007f06c3e306b6 in Perl_runops_standard () from /usr/lib/libperl.so.5.18
  #3  0x00007f06c3dc8cd1 in perl_run () from /usr/lib/libperl.so.5.18
  #4  0x0000000000400e19 in main ()
  (gdb) print pad
  $1 = (AV *) 0x4000000b00000001
  (gdb) print *pad
  Cannot access memory at address 0x4000000b00000001
 
FWIW this is
 http://bugs.debian.org/719835 
 https://rt.cpan.org/Ticket/Display.html?id=85998

Thanks for all your work,
-- 
Niko Tyni   ntyni at debian.org



More information about the pkg-perl-maintainers mailing list