summaryrefslogtreecommitdiffstats
path: root/llvm/lib/TextAPI/MachO/TextStubCommon.cpp
diff options
context:
space:
mode:
authorJessica Paquette <jpaquette@apple.com>2019-09-10 23:34:45 +0000
committerJessica Paquette <jpaquette@apple.com>2019-09-10 23:34:45 +0000
commit469d42fcf6b674137c2406c506b6ab4141abcb44 (patch)
tree391be83d005c00f8b61fcc7d7058b788016cda9a /llvm/lib/TextAPI/MachO/TextStubCommon.cpp
parentd40ddb9df26b4a8b5cf8ad7c920a9acccb98a13c (diff)
downloadbcm5719-llvm-469d42fcf6b674137c2406c506b6ab4141abcb44.tar.gz
bcm5719-llvm-469d42fcf6b674137c2406c506b6ab4141abcb44.zip
[GlobalISel] When a tail call is emitted in a block, stop translating it
This fixes a crash in tail call translation caused by assume and lifetime_end intrinsics. It's possible to have instructions other than a return after a tail call which will still have `Analysis::isInTailCallPosition` return true. (Namely, lifetime_end and assume intrinsics.) If we emit a tail call, we should stop translating instructions in the block. Otherwise, we can end up emitting an extra return, or dead instructions in general. This makes the verifier unhappy, and is generally unfortunate for codegen. This also removes the code from AArch64CallLowering that checks if we have a tail call when lowering a return. This is covered by the new code now. Also update call-translator-tail-call.ll to show that we now properly tail call in the presence of lifetime_end and assume. Differential Revision: https://reviews.llvm.org/D67415 llvm-svn: 371572
Diffstat (limited to 'llvm/lib/TextAPI/MachO/TextStubCommon.cpp')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud