[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Octave-bug-tracker] [bug #64557] New Virtual machine (VM): Performance
From: |
anonymous |
Subject: |
[Octave-bug-tracker] [bug #64557] New Virtual machine (VM): Performance issues with structs of cell arrays |
Date: |
Mon, 21 Aug 2023 22:14:13 -0400 (EDT) |
Follow-up Comment #2, bug #64557 (project octave):
Add-On:
The same performance issue where the VM is materially slower than the octave
interpreter exists for cell arrays containing a cell array or even a cell
array containing just a matrix.
So obviously the VM does not cope well with nested data structures from a
performance perspective.
function retval = test1()
a = cell(1,1);
a{1} = cell(100000,1);
for i=1:100
set_idx = rand(100000,1) < 0.001;
a{1}(set_idx) = [sin(i), cos(i)];
endfor
retval = a;
endfunction
clear test1; __enable_vm_eval__ (1); tic; a= test1(); toc;
Elapsed time is 0.14317 seconds.
clear test1; __enable_vm_eval__ (0); tic; a= test1(); toc;
Elapsed time is 0.0665581 seconds
_______________________________________________________
Reply to this item at:
<https://savannah.gnu.org/bugs/?64557>
_______________________________________________
Message sent via Savannah
https://savannah.gnu.org/