LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

LabVIEW Functions and reentrant execution

Are the LabVIEW functions reentrant? I am writing a threaded application where the same code is used for the multiple threads. I have made the top level and lower level VIs reentrant but am wondering if the LabVIEW functions (specifically TCP Read and TCP Write) have only one instance loaded into memory or one instance is loaded for each VI instance that is loaded at runtime?
Cheers,
Wayne
0 Kudos
Message 1 of 2
(2,775 Views)
> Are the LabVIEW functions reentrant? I am writing a threaded
> application where the same code is used for the multiple threads. I
> have made the top level and lower level VIs reentrant but am wondering
> if the LabVIEW functions (specifically TCP Read and TCP Write) have
> only one instance loaded into memory or one instance is loaded for
> each VI instance that is loaded at runtime?

The built-in objects in LV do tend to be reentrant. They are always
threadsafe, even when the access must be serialized such as for UI
actions. When the API has a connection ID or other reference to work
off of, they connect directly to lower OS APIs and are as reentrant to
the extent the lower level APIs allow.

Greg McKaskle
Message 2 of 2
(2,775 Views)