[mlir][GPUToLLVM] Fix regression introduced with opaque-pointers when generate GPU...
authorMarkus Böck <markus.boeck02@gmail.com>
Fri, 10 Mar 2023 09:49:16 +0000 (10:49 +0100)
committerMarkus Böck <markus.boeck02@gmail.com>
Fri, 10 Mar 2023 10:05:18 +0000 (11:05 +0100)
commit4614889a936fe7a69a4760fd765c374002c207c3
tree295ae0e79e480ca67c6f74fccd8f966e84223f99
parentbe687aff052bbdd6fd2cc3c75c8cebdd9ce7fab2
[mlir][GPUToLLVM] Fix regression introduced with opaque-pointers when generate GPU launch func parameters

This has caused build failures when enabling opaque pointers for the GPU integration tests as could be seen here:
https://lab.llvm.org/buildbot/#/builders/220/builds/16946 and here https://lab.llvm.org/buildbot/#/builders/61/builds/40822

The gist of the issue was the use of a wrong pointer base type within a GEP. There sadly was no test coverage for either the generating of that GEP, nor is LLVM Dialects GEP verifier currently capable of catching such issues, so it went unnoticed until the integration tests actually attempted to convert it to LLVM IR.

Differential Revision: https://reviews.llvm.org/D145774
mlir/lib/Conversion/GPUCommon/GPUToLLVMConversion.cpp
mlir/test/Conversion/GPUCommon/lower-launch-func-to-gpu-runtime-calls.mlir