Summary:
Currently they are not supported together. Supporting them will require
a LangRef change. See discussion in https://reviews.llvm.org/D77689.
Reviewers: rnk, efriedma
Subscribers: hiraditya, llvm-commits
Tags: #llvm
Differential Revision: https://reviews.llvm.org/D80132
void Verifier::verifyMustTailCall(CallInst &CI) {
Assert(!CI.isInlineAsm(), "cannot use musttail call with inline asm", &CI);
+ // FIXME: support musttail + preallocated
+ Assert(!CI.countOperandBundlesOfType(LLVMContext::OB_preallocated),
+ "musttail and preallocated not yet supported", &CI);
// - The caller and callee prototypes must match. Pointer types of
// parameters or return types may differ in pointee type, but not
%x = call i8* @llvm.call.preallocated.arg(token %t, i32 1) preallocated(i32)
ret void
}
+
+; CHECK: musttail and preallocated not yet supported
+define void @musttail() {
+ %cs = call token @llvm.call.preallocated.setup(i32 0)
+ musttail call void @foo0() ["preallocated"(token %cs)]
+ ret void
+}