Drastically speed up matching by not doing full tree cursor copies