You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
struct S0 s {
1UL,
{{{1L},{1L},{1L}},{{1L},{1L},{1L}}},
}.
Finally, we iterate through the struct and add the values to a variable:
ulong c = 0UL;
for (i = 0; i < 2; i++)
for (j = 0; i < 3; j++)
for (k = 0; k < 1; k++)
c += s.b[i][j][k];
Reading the result from the variable returns 0x4 in oclgrind, compared to the expected 0x6 as with other platforms.
The types of the members of the struct did not seem to affect this result, but removing the first element makes the bug go away. Also, lower sizes for the dimensions, as well as less than 3 dimensions, did not exhibit the bug.
The text was updated successfully, but these errors were encountered:
Assume the following struct definition:
struct S0 {
uchar a;
ulong b[2][3][1];
}
, followed by this initialization:
struct S0 s {
1UL,
{{{1L},{1L},{1L}},{{1L},{1L},{1L}}},
}.
Finally, we iterate through the struct and add the values to a variable:
ulong c = 0UL;
for (i = 0; i < 2; i++)
for (j = 0; i < 3; j++)
for (k = 0; k < 1; k++)
c += s.b[i][j][k];
Reading the result from the variable returns 0x4 in oclgrind, compared to the expected 0x6 as with other platforms.
The types of the members of the struct did not seem to affect this result, but removing the first element makes the bug go away. Also, lower sizes for the dimensions, as well as less than 3 dimensions, did not exhibit the bug.
The text was updated successfully, but these errors were encountered: