[OLK-5.10 10/36] perf tools: Fix pattern matching for same substring in different PMU type