Transformations Infrastructure: MultiMatcher (#30587)
### Details:
This PR introduces a new MultiMatcher utility class to OpenVINO's
pattern matching framework:
- ov::pass::MultiMatcher – supports matching multiple non-overlapping
(or overlapping) pattern instances across the graph
This components is designed to improve developer experience, enable
subgraph reuse, and simplify complex transformation logic.
**Motivation**
- Avoid repeated pattern definitions (e.g., Q/K/V projections, RoPE,
SDPA)
- Enable grouping and processing of repeated structures (e.g., attention
heads)
- Improve readability and maintainability of transformation passes
MultiMatcher:
```
Input
│
┌──────────────────┼──────────────────┐
▼ ▼ ▼
MatMul_Q MatMul_K MatMul_V
│ │ │
▼ ▼ ▼
Add_Q Add_K Add_V
auto projection = wrap_type<MatMul>(...);
auto bias = wrap_type<Add>(...);
MultiMatcher::register_patterns({bias}, callback);
All 3 matches are available in the callback:
matches = {
bias: [MatchQ pattern map, MatchK pattern map, MatchV pattern map],
}
```
### Tickets:
- *CVS-167802*
*CVS-170239*
---------
Co-authored-by: Mikhail Ryzhov <mikhail.ryzhov@intel.com>
Co-authored-by: Andrii Staikov <andrii.staikov@intel.com>