Unverified Commit 59e5cb7b authored by Michal Paszkowski's avatar Michal Paszkowski Committed by GitHub
Browse files

[SPIR-V] Do not emit spv_ptrcast if GEP result is of expected type (#78122)

Prior to this change spv_ptrcast (and OpBitcast) was never emitted for
GEP resulting pointers. While such SPIR-V was (mostly) accepted by the
NEO GPU driver, the generated SPIR-V was incorrect.

The newly added test (pointers/getelementptr-bitcast-load.ll) verifies
that a correct bitcast is added for more complex cases and passes
spirv-val. The test is based on an OpenCL CTS test (basic/prefetch).
parent 1b6c1a3b
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment