[clang] [mlir][llvm] Fix elem type passing into `getelementptr` (PR #68136)

2023-10-06 Thread Stella Laurenzo via cfe-commits
stellaraccident wrote: Thank you for the revert. We were failing on assertion when integrating this patch: ``` iree-compile: /home/stella/megabump/work/iree/third_party/llvm-project/llvm/include/llvm/Support/Casting.h:566: decltype(auto) llvm::cast(const From &) [To =

[clang] [mlir][llvm] Fix elem type passing into `getelementptr` (PR #68136)

2023-10-05 Thread Mehdi Amini via cfe-commits
joker-eph wrote: Reverted, the bots have been broken all day. https://github.com/llvm/llvm-project/pull/68136 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [mlir][llvm] Fix elem type passing into `getelementptr` (PR #68136)

2023-10-05 Thread Aart Bik via cfe-commits
aartbik wrote: This broke the bot? https://lab.llvm.org/buildbot/#/builders/61/builds/50100 https://github.com/llvm/llvm-project/pull/68136 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang] [mlir][llvm] Fix elem type passing into `getelementptr` (PR #68136)

2023-10-05 Thread Rik Huijzer via cfe-commits
rikhuijzer wrote: Thanks both for the review and clarifications. I'm learning a lot. https://github.com/llvm/llvm-project/pull/68136 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [mlir][llvm] Fix elem type passing into `getelementptr` (PR #68136)

2023-10-05 Thread Rik Huijzer via cfe-commits
https://github.com/rikhuijzer closed https://github.com/llvm/llvm-project/pull/68136 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [mlir][llvm] Fix elem type passing into `getelementptr` (PR #68136)

2023-10-05 Thread Oleksandr Alex Zinenko via cfe-commits
https://github.com/ftynse approved this pull request. https://github.com/llvm/llvm-project/pull/68136 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [mlir][llvm] Fix elem type passing into `getelementptr` (PR #68136)

2023-10-05 Thread Oleksandr Alex Zinenko via cfe-commits
ftynse wrote: What I meant in the comment was that MLIR doesn't need to make a hard switch to using opaque pointers and immediately turn off typed pointers. I didn't really imply that an operations in the IR should freely mix the two. Typed pointers should and will be removed from the LLVM

[clang] [mlir][llvm] Fix elem type passing into `getelementptr` (PR #68136)

2023-10-04 Thread Markus Böck via cfe-commits
zero9178 wrote: > So before I spend more time on the code, shall I rewrite this PR to throw a > clear error from `GEPOp::verify` for the incorrect representation? Then we > can close #63832. I'd personally be in favour of that. There is a **lot** of room for improvements in the verifiers

[clang] [mlir][llvm] Fix elem type passing into `getelementptr` (PR #68136)

2023-10-04 Thread Rik Huijzer via cfe-commits
rikhuijzer wrote: > [...] I am a bit afraid of the burden of having to maintain what is > essentially a third GEP representation. Thanks for the explanation @zero9178. I am affraid I do not fully understand your reasoning (most likely due to a lack of knowledge on my side). However, it

[clang] [mlir][llvm] Fix elem type passing into `getelementptr` (PR #68136)

2023-10-04 Thread Markus Böck via cfe-commits
zero9178 wrote: Thank you for your elaboration! I am not sure whether the original commit is referring to also supporting both typed pointers and opaque pointers in the exact same IR. This behaviour deviates from LLVM entirely as LLVM only supported one or the other as well. Furthermore, your

[clang] [mlir][llvm] Fix elem type passing into `getelementptr` (PR #68136)

2023-10-04 Thread Rik Huijzer via cfe-commits
rikhuijzer wrote: > What are the use cases for allowing either of these two syntaxes? > The LLVM Dialect tries to closely mirror LLVM proper as much as possible and > this would deviate from LLVMs behaviour. While the transition is currently > stalled, in the future typed pointers will be

[clang] [mlir][llvm] Fix elem type passing into `getelementptr` (PR #68136)

2023-10-03 Thread Markus Böck via cfe-commits
zero9178 wrote: What are the use cases for allowing either of these two syntaxes? The LLVM Dialect tries to closely mirror LLVM proper as much as possible and this would deviate from LLVMs behaviour. While the transition is currently stalled, in the future typed pointers will be removed from

[clang] [mlir][llvm] Fix elem type passing into `getelementptr` (PR #68136)

2023-10-03 Thread Rik Huijzer via cfe-commits
https://github.com/rikhuijzer updated https://github.com/llvm/llvm-project/pull/68136 >From 57ec61b03b4c54164f40be996b1d57420f2d4a2c Mon Sep 17 00:00:00 2001 From: Rik Huijzer Date: Tue, 3 Oct 2023 19:31:03 +0200 Subject: [PATCH] [mlir][llvm] Fix elem type passing into `getelementptr` ---