Perl has special debugging hooks at compile-time and run-time used
to create debugging environments. These hooks are not to be confused
-with the I<perl -Dxxx> command described in L<perlrun>, which are
-usable only if a special Perl built per the instructions the
+with the I<perl -Dxxx> command described in L<perlrun>, which is
+usable only if a special Perl is built per the instructions in the
F<INSTALL> podpage in the Perl source tree.
For example, whenever you call Perl's built-in C<caller> function
from the package DB, the arguments that the corresponding stack
-frame was called with are copied to the the @DB::args array. The
+frame was called with are copied to the @DB::args array. The
general mechanisms is enabled by calling Perl with the B<-d> switch, the
following additional features are enabled (cf. L<perlvar/$^P>):
C<DB::parse_options(string)>. The function C<DB::dump_trace(skip[,
count])> skips the specified number of frames and returns a list
containing information about the calling frames (all of them, if
-C<count> is missing). Each entry is reference to a a hash with
+C<count> is missing). Each entry is reference to a hash with
keys C<context> (either C<.>, C<$>, or C<@>), C<sub> (subroutine
name, or info about C<eval>), C<args> (C<undef> or a reference to
an array), C<file>, and C<line>.
is a saying that to estimate memory usage of Perl, assume a reasonable
algorithm for memory allocation, multiply that estimate by 10, and
while you still may miss the mark, at least you won't be quite so
-astonished. This is not absolutely true, but may prvide a good
+astonished. This is not absolutely true, but may provide a good
grasp of what happens.
Assume that an integer cannot take less than 20 bytes of memory, a
If your perl is using Perl's malloc() and was compiled with the
necessary switches (this is the default), then it will print memory
-usage statistics after compiling your code hwen C<< $ENV{PERL_DEBUG_MSTATS}
+usage statistics after compiling your code when C<< $ENV{PERL_DEBUG_MSTATS}
> 1 >>, and before termination of the program when C<<
$ENV{PERL_DEBUG_MSTATS} >= 1 >>. The report format is similar to
the following example:
the memory footprints of the buckets are between the memory footprints
of two buckets "above".
-For example, suppose under the pervious example, the memory footprints
+For example, suppose under the previous example, the memory footprints
were
free: 8 16 32 64 128 256 512 1024 2048 4096 8192
do 'lib/auto/POSIX/autosplit.ix';
warn('!!! "after"');
-and run it with PErl's B<-DL> option. The first warn() will print
+and run it with Perl's B<-DL> option. The first warn() will print
memory allocation info before parsing the file and will memorize
the statistics at this point (we ignore what it prints). The second
warn() prints increments with respect to these memorized data. This
=item C<717>
-CReates bigger C<XPV*> structures. In the case above, it
+Creates bigger C<XPV*> structures. In the case above, it
creates 3 C<AV>s per subroutine, one for a list of lexical variable
names, one for a scratchpad (which contains lexical variables and
C<targets>), and one for the array of scratchpads needed for