[clang] [mlir] [OpenACC] Implement tile/collapse lowering (PR #138576)
Andy Kaylor via cfe-commits
cfe-commits at lists.llvm.org
Mon May 5 15:37:14 PDT 2025
================
@@ -336,6 +348,52 @@ class OpenACCClauseCIREmitter final
return clauseNotImplemented(clause);
}
}
+
+ void VisitCollapseClause(const OpenACCCollapseClause &clause) {
+ if constexpr (isOneOfTypes<OpTy, mlir::acc::LoopOp>) {
+ llvm::APInt value =
+ clause.getIntExpr()->EvaluateKnownConstInt(cgf.cgm.getASTContext());
+
+ if (value.getBitWidth() != 64)
+ value = value.sext(64);
----------------
andykaylor wrote:
Is it possible for value to be wider than 64 bits?
https://github.com/llvm/llvm-project/pull/138576
More information about the cfe-commits
mailing list