[PATCH] D121641: MemoryBuiltins: also check function definition for allocalign

Nikita Popov via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Apr 7 02:40:10 PDT 2022


nikic added inline comments.


================
Comment at: llvm/lib/IR/Instructions.cpp:340
 
+Value *CallBase::getAllocAlignArgOperand() const {
+  unsigned Index;
----------------
That wasn't quite what I had in mind: I don't think we'll want to fetch allocalign beyond that one callsite. Rather, we could have `CallBase::getArgOperandWithAttribute(AttrKind)` and then use that both in `getReturnedArgOperand()` and in `getAllocAlignment()`.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D121641



More information about the llvm-commits mailing list