[clang] [CIR] Call code gen; create empty cir.func op (PR #113483)

David Olsen via cfe-commits cfe-commits at lists.llvm.org
Fri Nov 1 10:45:30 PDT 2024


================
@@ -53,6 +53,7 @@ class CIRGenerator : public clang::ASTConsumer {
   ~CIRGenerator() override;
   void Initialize(clang::ASTContext &astCtx) override;
   bool HandleTopLevelDecl(clang::DeclGroupRef group) override;
+  mlir::ModuleOp getModule();
----------------
dkolsen-pgi wrote:

https://mlir.llvm.org/docs/Rationale/UsageOfConst/

Types that implement MLIR data structures are not `const` correct.  That attitude will probably bleed over into ClangIR types that aren't part of the MLIR dialect.  But in this case I think this particular function can be `const`.


https://github.com/llvm/llvm-project/pull/113483


More information about the cfe-commits mailing list