in reply to Performance optimization question

Other than the approaches suggested by Joost (probably the best), avoiding intermediate results might help.

@arr1 = grep /reg exp/, split /\|/, $string;