03-15-2011 06:13 AM
Hi,
I would like to know if there is a tool or a software to look at the IL code generated after the DFIR step and before the call to LLVM when you compil a VI in Labview 2010 ?
Information about DFIR and LLVM in this article : NI LabVIEW Compiler: Under the Hood
I know it's a weird request. I think sometimes it's useful to know exactly what are optimizations done on a code in comparison with another one.
Some details are not visibles on a simple benchmark, you only have a result.
By the way, I am very interested too by any documentation you could have on this subject.
Regards,
Fabien
Solved! Go to Solution.
03-16-2011 04:54 AM
Hello Fabien,
The DFIR is a new technology in LabVIEW 2009 and LLVM is a new technology in LabVIEW 2010.
This link http://zone.ni.com/devzone/cda/tut/p/id/11472 is the best to understand this process. This link is the only information on DFIR or LLVM.
There are no tools to see the optimization made by the DFIR.
Brice S.
National Instruments France
03-16-2011 11:27 AM
It's what I feared.
Thanks for your answer.
Regards,
02-10-2019 01:56 AM
This is an old post, but there actually is a way:
1. Open LabVIEW.ini and add "LVdebugKeys=True". Restart LabVIEW if necessary. This step only needs to be done once.
2. Open the VI you want to read the code for.
3. Hold Control and click the Run arrow. It will look like nothing happened—not even running the VI—but this tells LabVIEW to save a copy of the code in memory.
4. Hold Control and Shift, and press D, H. This will open "Heap Peek", a debugging window filled with technical information.
5. Select your VI from the top-left section in Heap Peek. If you see multiple entries with your VI's name, just choose any of them; it doesn't matter for this purpose.
6. In the section right under the one where you selected your VI, click "2. Optimized LLVM". The code you're looking for will appear in the bottom half of the window. In case you're interested, there are also options to view the IL code stream and the disassembled native machine code.