06-13-2014 12:45 PM - edited 06-13-2014 12:46 PM
My system consists of a host PXI host running a VI front panel and communicating with three NI-9112 cRIOs using shared libraries. Two of the cRIO's utilize an FPGA and it is these two that consume 100% CPU according to the Distributed System Manager. I have no idea why these two cRIOs are consuming 100% CPU. Looking for any suggestions that may help.
06-13-2014 12:50 PM
Greedy loop (loop with no timing in it so it just runs as fast as it can taking up 100% CPU)? Extreme processing? We would need to see some code to diagnose anything without completely guessing.
06-14-2014 01:21 PM
Another guess - you have DMA communication between the RT and FPGA parts and you set a long or infinite timeout on that read or write operation. In normal LV, this would cause a reduction in CPU usage, because the code would wait for an interrupt to continue. In the case of a DMA read, it causes high CPU usage.
Generally, for debugging CPU consumption issues it is helpful to start disabling parts of the code. You do this until you find that the consumption is down and then you know which part is responsible. Another variation on this is to use case structures with boolean controls, which then allow you to dynamically play with this.
06-26-2014 06:15 PM
Sorry for the long delay. I was assisting the Labview developer on and off and posted this problem in order to help facilitate a solution. Short story is that it was indeed a loop, actually two loops that starved the CPU. We had one loop communicating to the FPGA and another running the main application. Both were running at 100Hz and when analyzing the processing of each loop, we dropped the loop rates down to the bare minimum to properly crunch the data. Once the loops were dropped ~60Hz CPU drop down to ~60Hz.
Although the developer viewed this response, he past and tried the "everything else under the sun approach." Eventually he had a NI support engineer come in house where the loop starvation issue was discovered. Many other issues were found by the "everything under the sun" approach (missed updates, etc.) so it wasn't a complete waste of time.
Thanks for your quick response and help in this matter! Much appreciated.