[PATCH] D35438: CodeGen: Ensure there is basic block when performing address space cast
Yaxun Liu via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Fri Jul 14 18:48:00 PDT 2017
yaxunl added a comment.
In https://reviews.llvm.org/D35438#810234, @rjmccall wrote:
> Hmm. It doesn't seem unreasonable for this to require an insertion point as a precondition. In what situation do we emit addrspace casts after a return?
When the alloca address space is not zero and we declare an automatic variable after return. Since we need to cast the automatic variable to default address space, we need to have a new basic block.
https://reviews.llvm.org/D35438
More information about the cfe-commits
mailing list