forked from OSchip/llvm-project
parent
fd1f4fe54e
commit
da8b71f292
|
@ -2916,7 +2916,7 @@ void Verifier::verifyMustTailCall(CallInst &CI) {
|
|||
|
||||
// Check the return.
|
||||
ReturnInst *Ret = dyn_cast_or_null<ReturnInst>(Next);
|
||||
Assert(Ret, "musttail call must be precede a ret with an optional bitcast",
|
||||
Assert(Ret, "musttail call must precede a ret with an optional bitcast",
|
||||
&CI);
|
||||
Assert(!Ret->getReturnValue() || Ret->getReturnValue() == RetVal,
|
||||
"musttail call result must be returned", Ret);
|
||||
|
|
|
@ -69,7 +69,7 @@ define void @mismatched_alignment(i32* byval align 4 %a) {
|
|||
|
||||
declare i32 @not_tail_pos_callee()
|
||||
define i32 @not_tail_pos() {
|
||||
; CHECK: musttail call must be precede a ret with an optional bitcast
|
||||
; CHECK: musttail call must precede a ret with an optional bitcast
|
||||
%v = musttail call i32 @not_tail_pos_callee()
|
||||
%w = add i32 %v, 1
|
||||
ret i32 %w
|
||||
|
|
Loading…
Reference in New Issue