KhronosGroup / KhronosGroup/SPIRV-Tools
Extend Phi placement to support unstructured control flow
Open
component:optimization
enhancement
- Dominant language
- C++
- Stars
- 1.4k
- Forks
- 709
- Avg merge
- 1d 22h
- Merged PRs (30d)
- 28
Description
This is a pre-requisite for #889. There exists an implementation for Phi placement in https://github.com/KhronosGroup/SPIRV-Tools/blob/master/source/opt/local_ssa_elim_pass.cpp#L410. However, that implementation is limited to structured control flow input.
To compute the minimal or pruned SSA form needed to insert Phi instructions, implement the algorithms referenced in https://en.wikipedia.org/wiki/Static_single_assignment_form.
This will require
- [ ] Implementation of a dominator tree.
- [ ] Implementation of dominance frontiers.
Contributor guide
Assessment
This issue has not been assessed yet.