package junk;
use strict;
use warnings;
use Exporter qw[ import ];
our @ISA = 'Exporter';
our @EXPORT_OK = qw[ test test2 ];
sub test{ print 'test' }
sub test2{ print 'test2'; goto &test; }
1;
####
#! perl -slw
use strict;
use junk qw[ test test2 ];
test;
test2;
####
C:\test>perl -d:DProf junk.pl
test
test2
test
C:\test>dprofpp tmon.out
junk::test has 1 unstacked calls in outer
junk::test2 has -1 unstacked calls in outer
Total Elapsed Time = 0.014928 Seconds
User+System Time = 0.015928 Seconds
Exclusive Times
%Time ExclSec CumulS #Calls sec/call Csec/c Name
0.00 - -0.000 1 - - strict::bits
0.00 - -0.000 1 - - warnings::BEGIN
0.00 - -0.000 1 - - warnings::import
0.00 - -0.000 2 - - junk::test
0.00 - -0.000 2 - - strict::import
0.00 - -0.000 2 - - Exporter::import
0.00 - -0.000 1 - - junk::test2
0.00 - -0.000 3 - - junk::BEGIN
0.00 - -0.000 2 - - main::BEGIN