more efficient matching