hc_clFlush (data.ocl, device_param->command_queue);
+ if (data.devices_status == STATUS_RUNNING)
+ {
+ usleep (device_param->exec_prev * 1000);
+ }
+
hc_clWaitForEvents (data.ocl, 1, &event);
if (event_update)
device_param->exec_ms[exec_pos] = exec_time;
+ device_param->exec_prev = exec_time;
+
exec_pos++;
if (exec_pos == EXEC_CACHE)
* main
*/
-#ifdef LINUX
-int (*clock_gettime_orig) (clockid_t clk_id, struct timespec *tp);
-
-int clock_gettime (clockid_t clk_id, struct timespec *tp)
-{
- int r = clock_gettime_orig (clk_id, tp);
-
- usleep (NVIDIA_100PERCENTCPU_WORKAROUND);
-
- return r;
-}
-#endif
-
#ifdef WIN
void SetConsoleWindowSize (const int x)
{
int main (int argc, char **argv)
{
- #ifdef LINUX
- clock_gettime_orig = dlsym (RTLD_NEXT, "clock_gettime");
- #endif
-
#ifdef WIN
SetConsoleWindowSize (132);
#endif