[PATCH] D154941: [mlir][ArmSME] Add custom get_tile_id and cast ops

Cullen Rhodes via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jul 11 03:31:26 PDT 2023


c-rhodes created this revision.
c-rhodes added reviewers: awarzynski, WanderAway.
c-rhodes added a project: MLIR.
Herald added subscribers: gysit, Dinistro, bviyer, Moerafaat, zero9178, bzcheeseman, sdasgup3, wenzhicui, wrengr, cota, teijeong, rdzhabarov, tatianashp, msifontes, jurahul, Kayjukh, grosul1, Joonsoo, liufengdb, aartbik, mgester, arpith-jacob, antiagainst, shauheen, rriddle, mehdi_amini, kristof.beyls.
Herald added a reviewer: rriddle.
Herald added a reviewer: antiagainst.
Herald added a reviewer: ftynse.
Herald added a reviewer: dcaballe.
Herald added a project: All.
c-rhodes requested review of this revision.
Herald added a reviewer: nicolasvasilache.
Herald added subscribers: alextsao1999, stephenneuendorffer, nicolasvasilache.

This patch adds three new custom ops to the ArmSME dialect:

- arm_sme.get_tile_id - returns a scalar integer representing an SME "virtual tile" that is not in use.
- arm_sme.cast_tile_to_vector - casts from a tile id to a 2-d scalable vector type, which represents an SME "virtual tile".
- arm_sme.cast_vector_to_tile - casts from a 2-d scalable vector type, which represents an SME "virtual tile", to a tile id.

The 'arm_sme.get_tile_id' op currently only supports tile 0, a follow-up
patch will implement proper tile allocation. A further follow-up patch
will demonstrate load/store to/from ZA using these ops.

See the op descriptions for further details and examples.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D154941

Files:
  mlir/include/mlir/Dialect/ArmSME/IR/ArmSME.td
  mlir/include/mlir/IR/OpBase.td
  mlir/lib/Dialect/ArmSME/IR/ArmSME.cpp
  mlir/lib/Dialect/ArmSME/Transforms/LegalizeForLLVMExport.cpp
  mlir/test/Dialect/ArmSME/canonicalize.mlir
  mlir/test/Dialect/ArmSME/invalid.mlir
  mlir/test/Dialect/ArmSME/roundtrip.mlir

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D154941.539000.patch
Type: text/x-patch
Size: 13481 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20230711/dab7761e/attachment.bin>


More information about the llvm-commits mailing list