LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Looking for information about the LabVIEW compiler.

Solved!
Go to solution

Looking for information about the LabVIEW compiler.

 

Like more about the how type propagation algorithm works with shift register and more.

 

Any Ebook, videos and white paper?

 

Hemant

0 Kudos
Message 1 of 8
(3,472 Views)
0 Kudos
Message 2 of 8
(3,470 Views)

When LabVIEW makes copy of the data. 

 

Branching wires always make copy of the data in LV?

 

Hemant

0 Kudos
Message 3 of 8
(3,464 Views)

@jg69 wrote:
https://www.ni.com/en/support/documentation/supplemental/10/ni-labview-compiler--under-the-hood.html

Regards, Jens

This tutorial i have gone through. Looking for more details info like typing rules about the shift register or how type propagation algorithm works in details and other algorithm.

 

Hemant 

0 Kudos
Message 4 of 8
(3,464 Views)

Hi Hemant,

 

I joined your other question into this thread as it basically asks the same about compiler internals.

 

The compiler is NI-stuff, I don't think you will get much more information than what is presented in the LabVIEW help and in those tutorials…

 

Why do you need all this information?

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 5 of 8
(3,441 Views)

@GerdW wrote:

Hi Hemant,

 

I joined your other question into this thread as it basically asks the same about compiler internals.

 

The compiler is NI-stuff, I don't think you will get much more information than what is presented in the LabVIEW help and in those tutorials…

 

Why do you need all this information?


Just curious to know about how LV internal works and how LV makes data copy and other details.

0 Kudos
Message 6 of 8
(3,432 Views)
Solution
Accepted by topic author LV_COder

@Hemant_LV

 

There's a full copy and shallow copy. Shallow copy occurs when then branches represent the same data (Both points to the same block of memory). Full copy occurs when the branch data is modified. Also, there's differences between the "Data Buffer" (Which is the byte cost of some datatype), "Transfer Buffer" (Which is the nodes, branches, wires and so on referenced by the "spatial lifetime on the VI") and the "Terminal" (Which is the controls/indicators) on the front panel. This also known as copy and write mechanism. Dunno if this happens to all datatypes and all cases.

 

Anyway, you can always use the "Show Buffer Allocations" and "Performance and Memory" on the Profile menu to get some insights.

 

Some useful links: 

 

https://www.ni.com/docs/en-US/bundle/labview/page/vi-memory-usage.html

https://www.ni.com/docs/en-US/bundle/labview/page/memory-management-for-large-data-sets.html

http://www.ni.com/white-paper/9386/en/ 

Message 7 of 8
(3,419 Views)

@LV_COder wrote:

When LabVIEW makes copy of the data. 

Only when needed. So this is very difficult to predict. Tools>Profile>Show Buffer Allocations gives a good idea. There are several stages working together. The BDHP (block diagram heap) is split into chunks, and is eventually converted to DIFR, and then LLVM. The LLVM compiler converts to assembler, but also performs optimisations. These are, I'd assume, out of control of NI developers, and there is no feedback AFAIK. So it's not hard to come up with examples where a copy will be a required, but a lot harder to prove the will or won't be a copy.

 


@LV_COder wrote:

 

Branching wires always make copy of the data in LV?

Absolutely most definitely NOT. That would be ridiculous (not the thought, but the resulting program).

 

Assume a copy is only made when needed. Worry about it iff (if and only if):

1) You need top notch performance.

2) You are dealing with huge data structures.

3) You're trying to understand when LabVIEW makes copies.

 

Where 1) and 2) are appropriate in the wild, 3) is just to validate this thread.

Message 8 of 8
(3,391 Views)