[PATCH] D105671: [Intrinsics][ObjC] Mark objc_retain and friends as thisreturn.

Jon Roelofs via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Aug 30 17:12:50 PDT 2021


jroelofs updated this revision to Diff 369584.
jroelofs added a comment.
Herald added a subscriber: dexonsmith.

Rebased.

Also, turns out that `stripPointerCasts()` can see through the `thisreturn` attribute, which defeats a self retain optimization, breaking one of the clang tests. I tweaked a callback to make it configurable. Let me know if you see a better way of dealing with that.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D105671

Files:
  clang/lib/CodeGen/CGCall.cpp
  clang/test/CodeGenObjC/arc.m
  clang/test/CodeGenObjC/convert-messages-to-runtime-calls.m
  llvm/include/llvm/IR/Intrinsics.td
  llvm/include/llvm/IR/Value.h
  llvm/lib/CodeGen/PreISelIntrinsicLowering.cpp
  llvm/lib/IR/Value.cpp
  llvm/test/Transforms/PreISelIntrinsicLowering/objc-arc.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D105671.369584.patch
Type: text/x-patch
Size: 15411 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20210831/d2ed3fdf/attachment.bin>


More information about the cfe-commits mailing list