Allow 8/16-bit integer as array index
Also enable 8/16 bit int capability in SPIR-V in such cases. Also enable 64 bit capabilities when used in operations. Fixes #2779
This commit is contained in:
parent
6351fcef28
commit
82b2668d58
6 changed files with 988 additions and 924 deletions
|
|
@ -116,6 +116,8 @@ void operators()
|
|||
int32_t i;
|
||||
int64_t i64;
|
||||
bool b;
|
||||
float f;
|
||||
float arr[4] = {1.0, 2.0, 3.0, 4.0};
|
||||
|
||||
// Unary
|
||||
u16v++;
|
||||
|
|
@ -163,6 +165,9 @@ void operators()
|
|||
uv = u16v & uv;
|
||||
uv ^= i16;
|
||||
u16v = u16v ^ i16;
|
||||
|
||||
// Index
|
||||
f = arr[i16];
|
||||
}
|
||||
|
||||
void builtinFuncs()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue