<div dir="ltr"><div class="gmail_default" style="font-family:verdana,sans-serif">Thanks for the heads up. </div><div class="gmail_default" style="font-family:verdana,sans-serif"><br></div><div class="gmail_default" style="font-family:verdana,sans-serif">Which buildbot shows the failure? I don't see the failure on the cuda buildbot, nor do I see it on my machine locally. </div><div class="gmail_default" style="font-family:verdana,sans-serif"><br></div><div class="gmail_default" style="font-family:verdana,sans-serif">It may be due to llvm/clang being out of sync. The commit had changes for both sides and if clang and llvm are out of sync, you may see this kind of error.</div><div class="gmail_default" style="font-family:verdana,sans-serif"><br></div><div class="gmail_default" style="font-family:verdana,sans-serif">--Artem</div><br><br><div class="gmail_quote"><div dir="ltr">On Tue, Mar 20, 2018 at 1:33 PM Rafael Avila de Espindola <<a href="mailto:rafael.espindola@gmail.com" target="_blank">rafael.espindola@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">With this clang/test/CodeGen/<a href="http://builtins-nvptx-sm_70.cu" rel="noreferrer" target="_blank">builtins-nvptx-sm_70.cu</a> is crashing:<br>
<br>
lib/IR/Instructions.cpp:299: void<br>
llvm::CallInst::init(llvm::FunctionType *, llvm::Value *,<br>
ArrayRef<llvm::Value *>, ArrayRef<llvm::OperandBundleDef>, const<br>
llvm::Twine &): Assertion `(i >= FTy->getNumParams()||<br>
FTy->getParamType(i) == Args[i]->getType()) && "Calling a function with<br>
a bad signature!"' failed.<br>
<br>
Cheers,<br>
Rafael<br>
<br>
<br>
Artem Belevich via cfe-commits <<a href="mailto:cfe-commits@lists.llvm.org" target="_blank">cfe-commits@lists.llvm.org</a>> writes:<br>
<br>
> Author: tra<br>
> Date: Tue Mar 20 10:18:59 2018<br>
> New Revision: 328006<br>
><br>
> URL: <a href="http://llvm.org/viewvc/llvm-project?rev=328006&view=rev" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project?rev=328006&view=rev</a><br>
> Log:<br>
> [NVPTX] Make tensor load/store intrinsics overloaded.<br>
><br>
> This way we can support address-space specific variants without explicitly<br>
> encoding the space in the name of the intrinsic. Less intrinsics to deal with -><br>
> less boilerplate.<br>
><br>
> Added a bit of tablegen magic to match/replace an intrinsics with a pointer<br>
> argument in particular address space with the space-specific instruction<br>
> variant.<br>
><br>
> Updated tests to use non-default address spaces.<br>
><br>
> Differential Revision: <a href="https://reviews.llvm.org/D43268" rel="noreferrer" target="_blank">https://reviews.llvm.org/D43268</a><br>
><br>
> Modified:<br>
> cfe/trunk/lib/CodeGen/CGBuiltin.cpp<br>
><br>
> Modified: cfe/trunk/lib/CodeGen/CGBuiltin.cpp<br>
> URL: <a href="http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/CodeGen/CGBuiltin.cpp?rev=328006&r1=328005&r2=328006&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/CodeGen/CGBuiltin.cpp?rev=328006&r1=328005&r2=328006&view=diff</a><br>
> ==============================================================================<br>
> --- cfe/trunk/lib/CodeGen/CGBuiltin.cpp (original)<br>
> +++ cfe/trunk/lib/CodeGen/CGBuiltin.cpp Tue Mar 20 10:18:59 2018<br>
> @@ -10527,8 +10527,7 @@ Value *CodeGenFunction::EmitNVPTXBuiltin<br>
> llvm_unreachable("Unexpected builtin ID.");<br>
> }<br>
> Value *Result =<br>
> - Builder.CreateCall(CGM.getIntrinsic(IID),<br>
> - {Builder.CreatePointerCast(Src, VoidPtrTy), Ldm});<br>
> + Builder.CreateCall(CGM.getIntrinsic(IID, Src->getType()), {Src, Ldm});<br>
><br>
> // Save returned values.<br>
> for (unsigned i = 0; i < NumResults; ++i) {<br>
> @@ -10567,10 +10566,9 @@ Value *CodeGenFunction::EmitNVPTXBuiltin<br>
> default:<br>
> llvm_unreachable("Unexpected builtin ID.");<br>
> }<br>
> - Function *Intrinsic = CGM.getIntrinsic(IID);<br>
> + Function *Intrinsic = CGM.getIntrinsic(IID, Dst->getType());<br>
> llvm::Type *ParamType = Intrinsic->getFunctionType()->getParamType(1);<br>
> - SmallVector<Value *, 10> Values;<br>
> - Values.push_back(Builder.CreatePointerCast(Dst, VoidPtrTy));<br>
> + SmallVector<Value *, 10> Values = {Dst};<br>
> for (unsigned i = 0; i < NumResults; ++i) {<br>
> Value *V = Builder.CreateAlignedLoad(<br>
> Builder.CreateGEP(Src.getPointer(), llvm::ConstantInt::get(IntTy, i)),<br>
><br>
><br>
> _______________________________________________<br>
> cfe-commits mailing list<br>
> <a href="mailto:cfe-commits@lists.llvm.org" target="_blank">cfe-commits@lists.llvm.org</a><br>
> <a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits</a><br>
</blockquote></div><br clear="all"><div><br></div>-- <br><div dir="ltr" class="m_-8912849795918784703gmail_signature" data-smartmail="gmail_signature"><div dir="ltr">--Artem Belevich</div></div></div>