[PDI-12927] - Filter Rows performance issue

Cherry-pick of master commit 
https://github.com/pentaho/pentaho-kettle/commit/3cb888725cecaee4360454343efa0a57bd6efb96