{
struct agent_info *agent = get_agent_info (device);
maybe_init_omp_async (agent);
+ if (!agent->omp_async_queue)
+ return false;
queue_push_copy (agent->omp_async_queue, dst, src, n);
return true;
}
}
maybe_init_omp_async (agent);
+ if (!agent->omp_async_queue)
+ GOMP_PLUGIN_fatal ("Asynchronous queue initialization failed");
queue_push_launch (agent->omp_async_queue, kernel, tgt_vars, kla);
queue_push_callback (agent->omp_async_queue,
GOMP_PLUGIN_target_task_completion, async_data);
gcn_exec (kernel, devaddrs, dims, targ_mem_desc, true, aq);
}
-/* Create a new asynchronous thread and queue for running future kernels;
- issues a fatal error if the queue cannot be created as all callers expect
- that the queue exists. */
+/* Create a new asynchronous thread and queue for running future kernels. */
struct goacc_asyncqueue *
GOMP_OFFLOAD_openacc_async_construct (int device)
if (pthread_mutex_init (&aq->mutex, NULL))
{
- GOMP_PLUGIN_fatal ("Failed to initialize a GCN agent queue mutex");
+ GOMP_PLUGIN_error ("Failed to initialize a GCN agent queue mutex");
return NULL;
}
if (pthread_cond_init (&aq->queue_cond_in, NULL))
{
- GOMP_PLUGIN_fatal ("Failed to initialize a GCN agent queue cond");
+ GOMP_PLUGIN_error ("Failed to initialize a GCN agent queue cond");
return NULL;
}
if (pthread_cond_init (&aq->queue_cond_out, NULL))
{
- GOMP_PLUGIN_fatal ("Failed to initialize a GCN agent queue cond");
+ GOMP_PLUGIN_error ("Failed to initialize a GCN agent queue cond");
return NULL;
}