LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

LabView DLL code execution speed

Hello,

 

snippy.png

 

If I call this piece of code (it is decoding frames from .mkv file) in a loop, the exe time is aprox. 15 ms.

 

If I call this piece of code in a loop with wait object, the execution time goes to 25 ms aprox. (no matter what the wait is of course).

 

If you have any clue why this could be happening let me know please.

 

0 Kudos
Message 1 of 4
(2,832 Views)

At the first - set option "Run in any thread" instead of "Run in UI Thread" (if your DLL is thread-safe, of course)

 

Andrey,

0 Kudos
Message 2 of 4
(2,810 Views)

It isnt + it runs in subVI that is nonreentrant.

 

Funny is, that this happens in the standard basic one while loop. I stripped down the code to maximum and it still behaves this weird.

0 Kudos
Message 3 of 4
(2,808 Views)

I would expect the overhead for the scheduler to evaluate if anything else is ready to run to be that high but that may be what you are running into. Even a Wait 0 will result in the scheduler evaluating if anything else is ready to run. Without the Wait the scheduler is not necessary invoked.



Mark Yedinak
Certified LabVIEW Architect
LabVIEW Champion

"Does anyone know where the love of God goes when the waves turn the minutes to hours?"
Wreck of the Edmund Fitzgerald - Gordon Lightfoot
Message 4 of 4
(2,801 Views)