[PATCH] D79141: [RISCV] Better Split Stack Pointer Adjustment for RVC

Shiva Chen via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Apr 30 02:07:15 PDT 2020


shiva0217 accepted this revision.
shiva0217 added a comment.
This revision is now accepted and ready to land.

In D79141#2011973 <https://reviews.llvm.org/D79141#2011973>, @lenary wrote:

> Update after shiva0217's review:
>
> - Update test to correctly show splitting on RV32*C
> - Use early return if `CSI.size() == 0`
> - Update comments to count bits correctly.
>
>   I decided against a `getOffsetAddressableLimit` function, as the logic in `getFirstSPAdjustAmount` isn't just about addressable offsets, it's also about what we can adjust in a single (compressed if possible) instruction, so I thought that adding that function would make the logic harder to understand.


Got your point. The logic is not only for addressable but also for preference for code size.

LGTM. Thanks for the update.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D79141/new/

https://reviews.llvm.org/D79141





More information about the llvm-commits mailing list