[llvm] r211247 - R600/SI: Add intrinsics for various math instructions.
Matt Arsenault
arsenm2 at gmail.com
Wed Jun 18 23:33:36 PDT 2014
On Jun 18, 2014, at 11:27 PM, Michel Dänzer <michel at daenzer.net> wrote:
> On 19.06.2014 10:19, Matt Arsenault wrote:
>> Author: arsenm
>> Date: Wed Jun 18 20:19:19 2014
>> New Revision: 211247
>>
>> URL: http://llvm.org/viewvc/llvm-project?rev=211247&view=rev
>> Log:
>> R600/SI: Add intrinsics for various math instructions.
>>
>> These will be used for custom lowering and for library
>> implementations of various math functions, so it's useful
>> to expose these as builtins.
>
> This change breaks lots of piglit gpu.py tests:
>
> LLVM triggered Diagnostic Handler: unsupported call to function llvm.AMDGPU.rsq in main
> shader_runner: /home/daenzer/src/llvm-git/llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp:7247: std::pair<SDValue, SDValue> llvm::TargetLowering::LowerCallTo(TargetLowering::CallLoweringInfo &) const: Assertion `CLI.Chain.getNode() && CLI.Chain.getValueType() == MVT::Other && "LowerCall didn't return a valid chain!"' failed.
>
> Would it be possible to preserve the pre-existing intrinsics unchanged?
> If not, it's a minor inconvenience for Mesa, as using
> llvm.AMDGPU.rsq.f32 breaks in the same way with older LLVM. Not the end
> of the world though.
I’m guessing this is broken because rsq now needs to be mangled to include the type since it now accepts f64 as well. It would be possible by using some other name for the f64 version, but I would rather not do that
More information about the llvm-commits
mailing list