I found the cascading match patterns really useful because it makes possible to link tables to the axes it really uses automatically. I do the link using a memory address in which an axis reference s stored. In my case (Smart MEG1.x) I observed few different rpm axes (values and length can vary). And the same table can use one or another axis from a bin to another.
<?xml version="1.0" encoding="UTF-8"?>
<map xmlns="http://prj-tuning.com/mapdef" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://prj-tuning.com/mapdef mapdef.xsd ">
<id>NIST@KFLDS</id>
<title>NIST@KFLDS - RPM Breakpoints</title>
<pattern>E6 F1 XX XX 0D 02 E6 F1 XX XX F2 F5 XX XX F2 F4 MMXX XX E0 87 DA XX XX XX F7 FA XX XX 8A XX XX XX 8A XX XX XX 8A|F6 F5 XX XX E6 F1 MMXX XX C2 F4 XX XX C2 F5 $$0 DA</pattern>
<conversion>
<factor>25</factor>
<signed>false</signed>
</conversion>
</map>
This is an example of dynamic RPM axis lookup (for KFLDS table)
First part of the pattern (before pipe) is locating the KFLDS table. The address after F2 F4 is the address the first axis reference.
This address is captured and reused in second pattern after C2 F5 and then the axis final address can be found just after E6 F1.
Looks like a bit complicated but it's not. The first pattern is a copy paste of the table pattern except that the MM mark is set at a different place.
It increases the accuracy of the axis lookup which is done in the second pattern.
I never tried anything more complicated but any number of patterns can be defined and matching values can be referenced using $$0, $$1,... $$n style expressions
Basically this feature is usefull when you have to process some indirect addressing.
From my experience the ecu code is built using the same coding patterns extensively.
This means that once an axis pattern like this one is discovered it can be reused a lot.