|
@@ -1257,11 +1257,12 @@ double starpu_permodel_history_based_expected_perf(struct starpu_perfmodel *mode
|
|
|
return _starpu_history_based_job_expected_perf(model, arch, &j, j.nimpl);
|
|
|
}
|
|
|
|
|
|
-void _starpu_perfmodel_create_comb_if_needed(struct starpu_perfmodel_arch* arch)
|
|
|
+int _starpu_perfmodel_create_comb_if_needed(struct starpu_perfmodel_arch* arch)
|
|
|
{
|
|
|
int comb = starpu_perfmodel_arch_comb_get(arch->ndevices, arch->devices);
|
|
|
if(comb == -1)
|
|
|
comb = starpu_perfmodel_arch_comb_add(arch->ndevices, arch->devices);
|
|
|
+ return comb;
|
|
|
}
|
|
|
|
|
|
void _starpu_update_perfmodel_history(struct _starpu_job *j, struct starpu_perfmodel *model, struct starpu_perfmodel_arch* arch, unsigned cpuid STARPU_ATTRIBUTE_UNUSED, double measured, unsigned impl)
|
|
@@ -1270,8 +1271,8 @@ void _starpu_update_perfmodel_history(struct _starpu_job *j, struct starpu_perfm
|
|
|
{
|
|
|
int c;
|
|
|
unsigned found = 0;
|
|
|
- int comb = starpu_perfmodel_arch_comb_get(arch->ndevices, arch->devices);
|
|
|
- STARPU_ASSERT(comb != -1);
|
|
|
+ int comb = _starpu_perfmodel_create_comb_if_needed(arch);
|
|
|
+
|
|
|
for(c = 0; c < model->state->ncombs; c++)
|
|
|
{
|
|
|
if(model->state->combs[c] == comb)
|