Skip to content

Commit 24b2292

Browse files
Merge pull request #3004 from varungandhi-apple/vg-apple/stable
Use additional musttail checking only in debug builds.
2 parents dec144c + a02f434 commit 24b2292

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

llvm/lib/IR/Verifier.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3323,6 +3323,7 @@ cl::init(false), cl::desc("Check that tail calls from swifttailcc functions to"
33233323

33243324
void Verifier::verifyMustTailCall(CallInst &CI) {
33253325
if (!CI.isMustTailCall()) {
3326+
#ifndef NDEBUG
33263327
if (EnableSwiftTailCCMustTailCheck &&
33273328
CI.getCallingConv() == CallingConv::SwiftTail &&
33283329
CI.getCaller()->getCallingConv() == CallingConv::SwiftTail &&
@@ -3331,6 +3332,7 @@ void Verifier::verifyMustTailCall(CallInst &CI) {
33313332
false, "tail call from swifttail->swiftail should be marked musttail",
33323333
&CI);
33333334
}
3335+
#endif
33343336
return;
33353337
}
33363338

0 commit comments

Comments
 (0)