[llvm] [AArch64][SME] Remove unused ZA lazy-save (PR #81648)

Sander de Smalen via llvm-commits llvm-commits at lists.llvm.org
Tue Mar 19 05:59:26 PDT 2024


================
@@ -29,6 +29,10 @@ def AArch64_save_zt : SDNode<"AArch64ISD::SAVE_ZT", SDTypeProfile<0, 2,
                              [SDTCisInt<0>, SDTCisPtrTy<1>]>,
                              [SDNPHasChain, SDNPSideEffect, SDNPMayStore]>;
 
+let usesCustomInserter = 1, Defs = [SP], Uses = [SP] in {
+  def ExpandZABuffer : Pseudo<(outs), (ins), []>, Sched<[WriteI]> {}
----------------
sdesmalen-arm wrote:

Can we split the functionality of this pseudo into two parts:
* One pseudo to allocate the buffer. This pseudo takes the size to allocate as an argument, and returns a pointer to the allocated block.
* Another pseudo to fill in the TPIDR2 object. This pseudo takes a pointer to the buffer and a frame-index for the TPIDR2 object to store to.

This way, we can express the RDVL*RDVL part in SelectionDAG nodes and simplify the expansion code. This makes the implementation of the dynamic allocation simpler and more suitable to reuse in the future.

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


More information about the llvm-commits mailing list