[Mlir-commits] [mlir] [mlir][EmitC] Add support for pointer and opaque types to subscript op (PR #86266)

Marius Brehler llvmlistbot at llvm.org
Fri Mar 22 04:00:00 PDT 2024


================
@@ -30,8 +30,14 @@
 namespace mlir {
 namespace emitc {
 void buildTerminatedBody(OpBuilder &builder, Location loc);
+
 /// Determines whether \p type is a valid integer type in EmitC.
 bool isSupportedIntegerType(mlir::Type type);
+
+/// Determines whether \p type is integer like, i.e. it's a supported integer,
+/// an index or opaque type.
+bool isIntegerLikeType(Type type);
----------------
marbre wrote:

I wouldn't consider an opaque type as an integer like type. If you really want to allow for opaque types I would rename to `isIntegerIndexOrOpaqueType` which better matches with what I envision when thinking of making https://github.com/llvm/llvm-project/blob/cb4453dc69d75064c9a82e9a6a9bf0d0ded4b204/mlir/include/mlir/Dialect/EmitC/IR/EmitC.td#L54 accessible (I am fine if that is done in a follow up).




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


More information about the Mlir-commits mailing list