[PATCH] D33355: [IR] Add additional addParamAttr/removeParamAttr to AttributeList API

Reid Kleckner via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue May 23 13:07:53 PDT 2017


rnk added inline comments.


================
Comment at: include/llvm/IR/Attributes.h:414
+  /// Add an attribute to the attribute list at the given arg indices. Returns a
+  // new list because attribute lists are immutable.
+  AttributeList addParamAttribute(LLVMContext &C, ArrayRef<unsigned> ArgNos,
----------------
Try to keep the triple-slash doxygen comments.


================
Comment at: include/llvm/IR/Function.h:367
+  /// @brief Extract the number of dereferenceable bytes for a parameter.
+  /// @param ArgNo AttributeList ArgNo, referring to an argument.
+  uint64_t getParamDereferenceableBytes(unsigned ArgNo) const {
----------------
I think saying "AttributeList ArgNo" is misleading. There is no special AttributeList argument numbering scheme, just the obvious LLVM function prototype argument number.


https://reviews.llvm.org/D33355





More information about the llvm-commits mailing list