Opened 13 years ago

Closed 13 years ago

#1158 closed Defect (fixed)

opencl_ati_101 plan class does not work

Reported by: tstrunk Owned by: davea
Priority: Undetermined Milestone: Undetermined
Component: Server - Scheduler Version: 6.13.12
Keywords: OpenCL, ATI Cc:

Description

Specifying the opencl_ati_101 plan class does not work. It's easy to see in sched_customize.cpp, line 580

This is the app_plan function:

 if (!strcmp(plan_class, "mt")) {
        return app_plan_mt(sreq, hu);
    } else if (strstr(plan_class, "ati")) {
        return app_plan_ati(sreq, plan_class, hu);
    } else if (strstr(plan_class, "cuda")) {
        return app_plan_cuda(sreq, plan_class, hu);
    } else if (!strcmp(plan_class, "nci")) {
        return app_plan_nci(sreq, hu);
    } else if (!strcmp(plan_class, "sse3")) {
        return app_plan_sse3(sreq, hu);
    } else if (!strcmp(plan_class, "vbox32")) {
        return app_plan_vbox(sreq, hu, false);
    } else if (!strcmp(plan_class, "vbox64")) {
        return app_plan_vbox(sreq, hu, true);
    } else if (strstr(plan_class, "opencl")) {
        return app_plan_opencl(sreq, plan_class, hu);
    }

In case of a plan class opencl_ati_101 the code returns app_plan_ati instead of traversing to app_plan_opencl, because of a substring comparison for ati.

The fix or rather workaround for this is easy: One just needs to make the opencl check before the ati one.

Thanks and bye!

Change History (1)

comment:1 Changed 13 years ago by davea

Resolution: fixed
Status: newclosed

(In [24716]) - scheduler: in app_plan(), check for "opencl" before "ati".

Otherwise "opencl_ati" won't get handled right. Fixes #1158

Note: See TracTickets for help on using tickets.