[llvm] [GlobalISel] Add G_STEP_VECTOR instruction (PR #115598)

Amara Emerson via llvm-commits llvm-commits at lists.llvm.org
Sun Nov 10 14:23:53 PST 2024


Thorsten =?utf-8?q?Sch=C3=BCtt?= <schuett at gmail.com>,
Thorsten =?utf-8?q?Sch=C3=BCtt?= <schuett at gmail.com>,
Thorsten =?utf-8?q?Sch=C3=BCtt?= <schuett at gmail.com>,
Thorsten =?utf-8?q?Sch=C3=BCtt?= <schuett at gmail.com>,
Thorsten =?utf-8?q?Sch=C3=BCtt?= <schuett at gmail.com>,
Thorsten =?utf-8?q?Sch=C3=BCtt?= <schuett at gmail.com>,
Thorsten =?utf-8?q?Sch=C3=BCtt?= <schuett at gmail.com>,
Thorsten =?utf-8?q?Sch=C3=BCtt?= <schuett at gmail.com>,
Thorsten =?utf-8?q?Sch=C3=BCtt?= <schuett at gmail.com>
Message-ID:
In-Reply-To: <llvm.org/llvm/llvm-project/pull/115598 at github.com>


================
@@ -906,6 +906,16 @@ class GVScale : public GenericMachineInstr {
   };
 };
 
+/// Represents a step vector.
+class GStepVector : public GenericMachineInstr {
+public:
+  APInt getStep() const { return getOperand(1).getCImm()->getValue(); }
+
----------------
aemerson wrote:

Maybe also add a variant to return a uint64_t for convenience?

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


More information about the llvm-commits mailing list