Problem with joinXPath optimization

Looks like joining XPaths in an OR condition is not operating as expected and is producing inconsistent results.