Forum Discussion
Altera_Forum
Honored Contributor
9 years agodevice_handler_thread_main: Assertion `args && args->func_name' failed
I use mutilthread in my opencl code. When run in emulator mode, code run successfully. But when run in FPGA, and excute to "clWaitForEvents()" function, it abort and show: "cnn: acl_hal_mmd.c:...
Altera_Forum
Honored Contributor
9 years agoI don't think multiple threads can access the same FPGA simultaneously. Altera's implementation seems to use some locking mechanism that when one thread/process accesses a device, it is locked to prevent other threads/processes from accessing it. You can use multiple queues with one thread/process to run multiple kernels on the same FPGA simultaneously (as long as all kernels were in the same .cl file); you don't need multiple threads in the host code to achieve this.