D::S also uses AvARRAY, AvALLOC and AvARYLEN.

use strict; use warnings; use Devel::Peek qw( Dump ); use Inline C => <<'__EOI__'; void call_AvMAX(AV* av) { AvMAX(av); } void call_AvARRAY(AV* av) { AvARRAY(av); } void call_AvALLOC(AV* av) { AvALLOC(av); } void call_AvARYLEN(AV* av) { AvARYLEN(av); } __EOI__ my @a = qw( a b c ); print("After init:\n"); Dump(\@a, 1); call_AvMAX(\@a); print("\nAfter AvMAX:\n"); Dump(\@a, 1); call_AvARRAY(\@a); print("\nAfter AvARRAY:\n"); Dump(\@a, 1); call_AvALLOC(\@a); print("\nAfter AvALLOC:\n"); Dump(\@a, 1); call_AvARYLEN(\@a); print("\nAfter AvARYLEN:\n"); Dump(\@a, 1);
After init: SV = RV(0x238c18) at 0x238c0c REFCNT = 1 FLAGS = (TEMP,ROK) RV = 0x182a68c SV = PVAV(0x2399f4) at 0x182a68c REFCNT = 2 FLAGS = (PADMY) ARRAY = 0x1824504 FILL = 2 MAX = 3 ARYLEN = 0x0 FLAGS = (REAL) After AvMAX: SV = RV(0x238c18) at 0x238c0c REFCNT = 1 FLAGS = (TEMP,ROK) RV = 0x182a68c SV = PVAV(0x2399f4) at 0x182a68c REFCNT = 2 FLAGS = (PADMY) ARRAY = 0x1824504 FILL = 2 MAX = 3 ARYLEN = 0x0 FLAGS = (REAL) After AvARRAY: SV = RV(0x238c18) at 0x238c0c REFCNT = 1 FLAGS = (TEMP,ROK) RV = 0x182a68c SV = PVAV(0x2399f4) at 0x182a68c REFCNT = 2 FLAGS = (PADMY) ARRAY = 0x1824504 FILL = 2 MAX = 3 ARYLEN = 0x0 FLAGS = (REAL) After AvALLOC: SV = RV(0x238c18) at 0x238c0c REFCNT = 1 FLAGS = (TEMP,ROK) RV = 0x182a68c SV = PVAV(0x2399f4) at 0x182a68c REFCNT = 2 FLAGS = (PADMY) ARRAY = 0x1824504 FILL = 2 MAX = 3 ARYLEN = 0x0 FLAGS = (REAL) After AvARYLEN: SV = RV(0x238c18) at 0x238c0c REFCNT = 1 FLAGS = (TEMP,ROK) RV = 0x182a68c SV = PVAV(0x2399f4) at 0x182a68c REFCNT = 2 FLAGS = (PADMY,RMG) MAGIC = 0x23fdbc MG_VIRTUAL = &PL_vtbl_arylen_p MG_TYPE = PERL_MAGIC_arylen_p(@) MG_FLAGS = 0x02 REFCOUNTED ARRAY = 0x1824504 FILL = 2 MAX = 3 ARYLEN = 0x0 FLAGS = (REAL)

So AvARYLEN is the culprit. In 5.10.1, AvARYLEN is defined as

#define AvARYLEN(av) (*Perl_av_arylen_p(aTHX_ MUTABLE_AV(av)))

Sounds familiar.


In reply to Re^7: perl5.10 Devel::Size behaviour changed? (bug report) by ikegami
in thread perl5.10 Devel::Size behaviour changed? by sang1986

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.