Imre Deak <imre.d...@intel.com> writes: > - if (values[table[hash & mask]].pname == d->pname) > - break; > - hash += prime_step; > - j++; > + if (values[TABLE_IDX(table[hash & mask])].pname == d->pname) > + break; > + hash += prime_step; > + j++;
indentation changes, fold them into the first patch. > - if (likely(d->pname == pname)) > + if (likely(d->pname == pname && (TABLE_API(table_val) & api_bit))) > + /* > + * Don't bail out here if the API doesn't match, since the same > pname > + * can be present in the table for other APIs (with different > + * semantics). > + */ > break; How many of the pnames appear twice in the values table? Would they be better handled by doing some custom checking that was api-dependent, and then not having the hash table be api-dependent? It seems like it would be nice to do the hash table generation at build time instead, so that it was constant data.
pgpCz3oHsDkY8.pgp
Description: PGP signature
_______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev