[llvm-commits] [dragonegg] r135472 - /dragonegg/trunk/src/Convert.cpp
Tobias Grosser
tobias at grosser.es
Tue Jul 19 03:53:31 PDT 2011
On 07/19/2011 10:43 AM, Jay Foad wrote:
> Author: foad
> Date: Tue Jul 19 03:43:11 2011
> New Revision: 135472
>
> URL: http://llvm.org/viewvc/llvm-project?rev=135472&view=rev
> Log:
> Update for change in Intrinsic::getDeclaration API.
>
> Modified:
> dragonegg/trunk/src/Convert.cpp
> // The gcc builtins are also full memory barriers.
> @@ -4694,7 +4691,7 @@
> // by passing it as the 3rd and 4th parameters. This isn't needed for
> // most intrinsics, but is needed for ctpop, cttz, ctlz.
> Type *Ty = InVal->getType();
> - Result = Builder.CreateCall(Intrinsic::getDeclaration(TheModule, Id,&Ty, 1),
> + Result = Builder.CreateCall(Intrinsic::getDeclaration(TheModule, Id, Ty),
> InVal);
> return true;
> }
> @@ -4704,7 +4701,7 @@
> Type* Ty = Amt->getType();
>
> return Builder.CreateCall(Intrinsic::getDeclaration(TheModule,
> - Intrinsic::sqrt,&Ty, 1),
> + Intrinsic::sqrt, Ty),
> Amt);
> }
>
> @@ -4721,7 +4718,7 @@
> Args.push_back(Val);
> Args.push_back(Pow);
> return Builder.CreateCall(Intrinsic::getDeclaration(TheModule,
> - Intrinsic::powi,&Ty, 1),
> + Intrinsic::powi, Ty),
> Args);
> }
>
> @@ -4737,7 +4734,7 @@
> Args.push_back(Val);
> Args.push_back(Pow);
> return Builder.CreateCall(Intrinsic::getDeclaration(TheModule,
> - Intrinsic::pow,&Ty, 1),
> + Intrinsic::pow, Ty),
> Args);
> }
>
> @@ -5553,7 +5550,7 @@
>
> Function *Fn = Intrinsic::getDeclaration(TheModule,
> Intrinsic::ptr_annotation,
> -&SBP, 1);
> + SBP);
Did you compile test these changes? I had the to use the following to
make the calls with a single element work:
- Result = Builder.CreateCall(Intrinsic::getDeclaration(TheModule, Id,
&Ty, 1),
+ Result = Builder.CreateCall(Intrinsic::getDeclaration(TheModule, Id,
+
makeArrayRef(&Ty, 1)),
Cheers
Tobi
More information about the llvm-commits
mailing list