Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Invalid SPIR-V for some phi nodes/selects #1020

Open
alan-baker opened this issue Feb 21, 2023 · 0 comments
Open

Invalid SPIR-V for some phi nodes/selects #1020

alan-baker opened this issue Feb 21, 2023 · 0 comments
Labels

Comments

@alan-baker
Copy link
Collaborator

I noticed this for at least physical storage buffer.

constant int b[5] = {1,2,3,4,5};
__attribute__((noinline))
int foo(constant int* p, int x) {
  return p[x];
}
kernel void test(global int* out, constant int* other, int x) {
  int gid = get_global_id(0);
  out[gid] = foo(x > 5 ? other : p, gid);
}

The geps generated for the selection of pointers has differing types due to the module scope constant vs the kernel argument.

@alan-baker alan-baker added the bug label Feb 21, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant