[PATCH] D99037: [Matrix] Implement explicit type conversions for matrix types
Saurabh Jha via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Apr 1 13:33:23 PDT 2021
SaurabhJha updated this revision to Diff 334815.
SaurabhJha added a comment.
Herald added a subscriber: martong.
Hi Florian and John,
Thanks for the comments so far. I figure it would be easier for further discussion if I have something concrete. Here's what I have right now:
- A new CK_MatrixCast.
- Sema code for C-style cast along with its tests.
- My guess on places CK_MatrixCast will go in CodeGen. I have added a TODO in CGExprScalar.cpp indicating where I think we should implement the code gen for this conversion. There's a failing CodeGen test too.
- I am not sure yet if we need to anything with StaticAnalyzer/Core/ExprEngineC.cpp. I got a warning that CK_MatrixCast needs handling there.
My next step is to make it work for C style cast. Once that works, I can use that learning to implement static_cast.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D99037/new/
https://reviews.llvm.org/D99037
Files:
clang/include/clang/AST/OperationKinds.def
clang/include/clang/Basic/DiagnosticSemaKinds.td
clang/include/clang/Sema/Sema.h
clang/lib/AST/Expr.cpp
clang/lib/AST/ExprConstant.cpp
clang/lib/CodeGen/CGExpr.cpp
clang/lib/CodeGen/CGExprAgg.cpp
clang/lib/CodeGen/CGExprComplex.cpp
clang/lib/CodeGen/CGExprConstant.cpp
clang/lib/CodeGen/CGExprScalar.cpp
clang/lib/Edit/RewriteObjCFoundationAPI.cpp
clang/lib/Sema/SemaCast.cpp
clang/lib/Sema/SemaExpr.cpp
clang/lib/StaticAnalyzer/Core/ExprEngineC.cpp
clang/test/CodeGen/matrix-cast.c
clang/test/Sema/matrix-cast.c
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D99037.334815.patch
Type: text/x-patch
Size: 13098 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20210401/eac86047/attachment-0001.bin>
More information about the cfe-commits
mailing list