[PATCH] D58514: Avoid needlessly copying blocks that initialize or are assigned to local auto variables to the heap
Erik Pilkington via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Mar 14 11:17:19 PDT 2019
erik.pilkington added a comment.
In D58514#1429606 <https://reviews.llvm.org/D58514#1429606>, @rjmccall wrote:
> There is no way in the existing ABI for copying a block to cause other references to the block to become references to the heap block. We do do that for `__block` variables, but not for block objects themselves.
Do you think thats worth doing? We could add a forwarding pointer to the end of a block literal on the stack (after all the captures) and flip an unused bit to track it, preserving ABI. Seems like now that we're delaying `_Block_copy`ies this might be a bigger issue.
Repository:
rC Clang
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D58514/new/
https://reviews.llvm.org/D58514
More information about the cfe-commits
mailing list