cmajor
cmajor copied to clipboard
Multi-dimensional arrays of structures (bug?)
There seems to be some kind of issue with multi-dimensional arrays. In the following code the line 'test[0][0].a = 1;' takes an extremely long time to execute (in vscode there is a long delay before the 'console' is displayed).
processor Test
{
output event float out;
struct TestStruct {
int a;
int[100] b;
}
TestStruct[100][100] test;
void main()
{
test[0][0].a = 1;
loop {
advance();
}
}
}
Hi, yes I can confirm I can reproduce this here. The time is being spent at compile time, optimising the generated code. We altered how the optimiser runs a little while back and I think this is a side effect. I'll look at getting a fix in place. Thanks for raising.
Quick update - this dropped off my radar so i've not made any progress with it. Sorry about this, i'll get back onto it soon though...