| 1 | # If the AutoSplit module has been loaded before we got initialized | ||
| 2 | # (specifically before we redirected the opcodes used when compiling) | ||
| 3 | # then the profiler won't profile AutoSplit code so the test will fail | ||
| 4 | # because the results won't match. | ||
| 5 | # The tricky part is that we need to take care to avoid being tripped up | ||
| 6 | # by the fact that XSLoader will fallback to using DynaLoader in some cases | ||
| 7 | # and DynaLoader uses AutoSplit. | ||
| 8 | # See Makefile.PL for how we avoid XSLoader fallback to using DynaLoader. | ||
| 9 | |||
| 10 | 16 | ▶ | BEGIN { |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 11 | 16 | ▶ | use AutoSplit; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 12 | 16 | mkdir('./auto'); | |
| 13 | 16 | autosplit('test14', './auto', 1, 0, 0); | |
| 14 | } | ||
| 15 | |||
| 16 | 16 | ▶ | use test14; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 17 | 16 | test14::pre(); | |
| 18 | 16 | test14::foo(); | |
| 19 | 16 | test14::bar(); | |