LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

multi plot waveform graph plot order

Solved!
Go to solution

I haven't had the chance to program much LabVIEW during the previous years but worked intensely with it in the far past (and even passed the "developer" exam). Regarding property nodes vs. local variables: I remember the recommendation to prefer property nodes over local variables. Give me a hint: Why could local variables be favourable? Wasn't it the memory argument? Which one of the two options uses less memory?

0 Kudos
Message 11 of 12
(76 Views)

@Ljewin wrote:

I remember the recommendation to prefer property nodes over local variables. Give me a hint: Why could local variables be favourable? Wasn't it the memory argument? Which one of the two options uses less memory?


Nobody sane ever suggested that value property nodes are preferred over local variables. You probably heard that local variables cause extra memory copies (completely irrelevant for scalars) and extrapolated from there, but property nodes are significantly worse because they also execute synchronously and force a thread switch.

 

(Value property nodes are useful of you want to change a value from within a subVI that has a control reference as input, but they have little usefulness within the same diagram)

 

LabVIEW is a dataflow language and the wire is the variable. You can always tell where the value comes from and what depends on it downstream. One you break dataflow with locals and value property node you never know what part changed the value last and race conditions can occur.

 

Message 12 of 12
(70 Views)