LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Variant memory allocation and profiler problem

Hi fellows,

I'm trying to do a hierarchical data type that would allow clustering data one inside another indefenitely. I was considering a implementation where I'd have a variant inside a variant inside a variant... To find out if the implementation is sufficiently effective in performance and memory usage means, I tried to use Labview Performance and Memory profiler to study the issue. I found out that profiler incorrectly shows the memory allocation for variant data type. A array uses much more memory according to profiler than an array transformed to a variant. Task manager tells the truth and shows that variant indeed uses more memory than the native data type.

My question is, how does Labview allocate memory for variant and store variant into memory when I
1) transform native data type to variant
2) transform variant to native data type
3) transform variant to variant (both ways)

I also wonder why doesn't Labview performance and memory profiler correctly show variant memory usage. I'm using Labview 8.0.1. In the attatchment there is a LLB with two alternative solutions to do the same thing. Hierarchical Analysis.vi uses variants and Hierarchical Analysis_novariant.vi uses native data types. When using the profiler, it seems that non-variant version uses much more memory that the variant version, which of course cannot be the case.
--
Tomi Maila
0 Kudos
Message 1 of 3
(2,799 Views)
Are there anybody who knows anything about this?
--
Tomi Maila
0 Kudos
Message 2 of 3
(2,782 Views)
Sounds pretty quiet Smiley Sad
--
Tomi Maila
0 Kudos
Message 3 of 3
(2,769 Views)