KhronosGroup / KhronosGroup/SPIRV-Tools
Refactorize spv{Opcode,Operand,ExtInst}TableGet to remove the target env
- Dominant language
- C++
- Stars
- 1.4k
- Forks
- 709
- Avg merge
- 1d 22h
- Merged PRs (30d)
- 28
Description
~~The assemble grammar can be used to retrieve valuable spec information, like the extensions required for a given capability.
Most of the code to support it seems present, but it seems like we have only one table for operands, and we ignore the spirv version in use.~~
~~This means, no matter the SPIRV version, the Capability MultiView will require the SPV_KHR_multiview extension. I don't think this is a big issue, but would be a nice improvement the the capability trimming pass incoming.~~
Headers are not split by version anymore for the reasons explained below. This makes the table returned valid for all target env, as long as we check the minVersion/lastVersion values.
Those function should probably not take the target env anymore (and the caller maybe) as this can be confusing.
Contributor guide
Research direction
Start by locating spvOpcodeTableGet, spvOperandTableGet, and spvExtInstTableGet, then inspect their callers and how target environments are passed. Confirm that the returned tables are valid across target environments when minVersion and lastVersion are checked, and update the functions and any necessary caller so the target environment is no longer accepted.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- compilers
- Issue type
- Refactor
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100