kernel void Generate_v_alt_full (out double v_alt<>, double orig_x[][], int aout_full[] )
{
int2 ind = instance().xy;
v_alt = orig_x[ind.y][aout_full[ind.x]];
}
Above compiles well
kernel void Generate_v_alt_full (out double v_alt<>, double orig_x[][], int aout_full[] )
{
int2 ind = instance().xy;
v_alt = orig_x[aout_full[ind.x]][ind.y];
}
Interchanging the indices spews a bunch of parser error
While processing <buffer>:176
In compiler at zzerror()[parser.y:112]
message = syntax error
ERROR: Parse error. Invalid expression.
While processing <buffer>:176
In compiler at zzparse()[parser.y:301]
(yyvsp[0]).ToString() = ")"
Aborting...
Problem with compiling brookgenfiles/misc_kernels_Copy_Stream_kv.hlsl
Error--:cal back end failed to compile kernel "Copy_Stream_kv"
NOTICE: Parse error
In compiler at zzerror()[parser.y:112]
message = syntax error
ERROR: Parse error. Expected declaration.
In compiler at zzparse()[parser.y:198]
(yyvsp[0]) = ")"
Declaring a temp variable for aout_full[ind.x] and substituting in the last kernel makes the parse errors go away.