Skip to content

[SYCL] Added arbitrary integer SPIR-V spec as an extension #1957

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

Merged
merged 1 commit into from
Jun 27, 2020

Conversation

ajaykumarkannan
Copy link
Contributor

Create a new extension to enable SPIR-V to use arbitrary precision integers, with a default maximum bitwidth (with this extension) up to 32 bits, but implementers are allowed to go up to any arbitrary bitwidth.

@bader bader added the spec extension All issues/PRs related to extensions specifications label Jun 27, 2020
@bader bader merged commit b96aa2e into intel:sycl Jun 27, 2020
@ajaykumarkannan ajaykumarkannan deleted the kannanaj_arbitrary_integers branch August 5, 2020 15:17
againull pushed a commit to againull/llvm that referenced this pull request May 4, 2023
This is a massive change, which consists of the following pieces that are not so easily seperable (why this is a large, single commit instead of many smaller ones):

Use typed pointer types in the external interface of the scavenger.
Use target extension types in lieu of DeferredType to represent types not yet known. These types are now target("typevar", N), where N is some integer.
Use TypedPointerType in lieu of DeducedType. This makes multi-level pointer types simpler to use.
Replace std::pair<unsigned, DeducedType> with a more generalized TypeRule class, which simplifies some of the rules for the typing procedure.
Make computePointerElementType and correctUseTypes both rely on the same list of type rules, removing duplication.
Add support for vectors of pointers, arrays of pointers, and function pointers in the type scavenger.
Allow global variables to have scavenged types.
Allow return types to not be i8*.
Add more documentation of the type scavenger process.
More tests!
Miscellaneous type rule fixes.
Overall, the logic of the type scavenger largely remains unchanged (albeit with increased functionality), but the way that logic is expressed has changed very significantly, and the easier functionality for handling a few cases causes shifting of expected bitcast placements in existing tests.

Original commit:
KhronosGroup/SPIRV-LLVM-Translator@cb6de04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
spec extension All issues/PRs related to extensions specifications
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants