[PATCH] D149566: [CodeGen] Replace CCState's getNextStackOffset with getStackSize (NFC)
Sergei Barannikov via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri May 12 08:25:08 PDT 2023
barannikov88 added inline comments.
================
Comment at: llvm/include/llvm/CodeGen/CallingConvLower.h:178
- unsigned StackOffset;
+ unsigned StackSize;
Align MaxStackArgAlign;
----------------
arsenm wrote:
> Maybe CurrentStackSize would help make it clearer this is a stateful thing which may keep increasing
I can rename this variable and/or add a comment (there is an equivalent in GISel),
but I wouldn't want to change the name of `getStackSize()` and `getAlignedCallFrameSize()`.
Most clients use them when the stack has finished growing. As for other uses, I think it shouldn't
cause much confusion; there is std::my_fav_container::size() that also returns the current size.
What do you think?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D149566/new/
https://reviews.llvm.org/D149566
More information about the llvm-commits
mailing list