[PATCH] D158081: [IR] Add writable attribute
Nikita Popov via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Aug 22 11:39:55 PDT 2023
nikic added inline comments.
================
Comment at: llvm/docs/LangRef.rst:1550
+ ``dereferenceable_or_null`` (if the pointer is non-null) and the
+ ``sret``, ``byval``, ``byref``, ``inalloca``, ``preallocated`` family of
+ attributes. Note that not all of these combinations are useful, e.g.
----------------
efriedma wrote:
> Does anything actually use sret to drive analysis like this? I thought we eliminated most of the usage.
It happens here: https://github.com/llvm/llvm-project/blob/f105ed11ae44b382f1c2cf9f83cba313ad0b8d7f/llvm/lib/IR/Value.cpp#L857-L863 sret is one of the types part of getPointeeInMemoryValueType().
Worth noting that clang doesn't currently emit dereferenceable for sret arguments, it relies on the implied dereferenceability.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D158081/new/
https://reviews.llvm.org/D158081
More information about the llvm-commits
mailing list