[llvm] [RISCV] Use RVVBitsPerBlock in assignRVVStackObjectOffsets and adjustReg. NFC (PR #109848)

Philip Reames via llvm-commits llvm-commits at lists.llvm.org
Wed Sep 25 10:39:54 PDT 2024


================
@@ -1090,11 +1090,12 @@ RISCVFrameLowering::assignRVVStackObjectOffsets(MachineFunction &MF) const {
   for (int FI : ObjectsToAllocate) {
     // ObjectSize in bytes.
     int64_t ObjectSize = MFI.getObjectSize(FI);
-    auto ObjectAlign = std::max(Align(8), MFI.getObjectAlign(FI));
+    auto ObjectAlign =
+        std::max(Align(RISCV::RVVBitsPerBlock / 8), MFI.getObjectAlign(FI));
----------------
preames wrote:

Very minor, but maybe it's time to introduce RVVBytesPerBlock?  

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


More information about the llvm-commits mailing list