[all-commits] [llvm/llvm-project] 818af7: [mlir][emitc] Add ArrayType (#83386)

Matthias Gehre via All-commits all-commits at lists.llvm.org
Mon Mar 11 08:41:18 PDT 2024


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 818af71b72219d149174faf9420dfc00f2c03470
      https://github.com/llvm/llvm-project/commit/818af71b72219d149174faf9420dfc00f2c03470
  Author: Matthias Gehre <matthias.gehre at amd.com>
  Date:   2024-03-11 (Mon, 11 Mar 2024)

  Changed paths:
    M mlir/include/mlir/Dialect/EmitC/IR/EmitCTypes.td
    M mlir/lib/Dialect/EmitC/IR/EmitC.cpp
    M mlir/lib/Target/Cpp/TranslateToCpp.cpp
    M mlir/test/Dialect/EmitC/invalid_ops.mlir
    M mlir/test/Dialect/EmitC/invalid_types.mlir
    M mlir/test/Dialect/EmitC/types.mlir
    M mlir/test/Target/Cpp/common-cpp.mlir
    M mlir/test/Target/Cpp/declare_func.mlir
    M mlir/test/Target/Cpp/func.mlir
    M mlir/test/Target/Cpp/invalid.mlir
    A mlir/test/Target/Cpp/invalid_declare_variables_at_top.mlir
    M mlir/test/Target/Cpp/variable.mlir

  Log Message:
  -----------
  [mlir][emitc] Add ArrayType (#83386)

This models a one or multi-dimensional C/C++ array.

The type implements the `ShapedTypeInterface` and prints similar to
memref/tensor:
```
  %arg0: !emitc.array<1xf32>,
  %arg1: !emitc.array<10x20x30xi32>,
  %arg2: !emitc.array<30x!emitc.ptr<i32>>,
  %arg3: !emitc.array<30x!emitc.opaque<"int">>
```

It can be translated to a C array type when used as function parameter
or as `emitc.variable` type.



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list