in reply to How to find out, why my perl code is slow.
For finding the slow parts in your program, the best is probably to use a profiling tool such as Devel::NYTProf.
Otherwise, as a general comment, I would suspect that using the regex engine in a loop to fetch one byte at a time is probably quite inefficient. unpack is very likely to be significantly faster if you can use it. Even substr in a loop is quite probably going to run faster.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: How to find out, why my perl code is slow.
by Anonymous Monk on Nov 05, 2018 at 06:04 UTC |