Assert was wrong and caused issues when there are devices defined
after devices that are matched by chip_id.
Signed-off-by: Danylo Piliaiev <dpiliaiev@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21498>
if (ref->gpu_id && id->gpu_id) {
return ref->gpu_id == id->gpu_id;
} else {
- assert(ref->chip_id && id->chip_id);
+ if (!id->chip_id)
+ return false;
+
/* Match on either:
* (a) exact match:
*/
unsigned gen = test->gpu_id / 100;
if (!compilers[gen]) {
dev_ids[gen].gpu_id = test->gpu_id;
+ dev_ids[gen].chip_id = 0;
compilers[gen] = ir3_compiler_create(NULL, &dev_ids[gen],
&(struct ir3_compiler_options){});
}