[AMDGPU] Restrict v_cndmask_b32 abs/neg modifiers to f32
authorJay Foad <jay.foad@gmail.com>
Fri, 12 Jul 2019 15:02:59 +0000 (15:02 +0000)
committerJay Foad <jay.foad@gmail.com>
Fri, 12 Jul 2019 15:02:59 +0000 (15:02 +0000)
commit7816ad918ff2049c2b3349d3500ad0a47c4f8ac7
tree535a6cf63bb2867222939cb8c4fd665897a9e1bd
parentb251cc0d91362ea44f00a0138998a0272791f7dc
[AMDGPU] Restrict v_cndmask_b32 abs/neg modifiers to f32

Summary:
D64497 allowed abs/neg source modifiers on v_cndmask_b32 but it doesn't
make any sense to apply them to f16 operands; they would interpret the
bits of the value as an f32, giving nonsensical results. This patch
restricts them to f32 operands.

Reviewers: arsenm, hakzsam

Subscribers: kzhuravl, jvesely, wdng, nhaehnle, yaxunl, dstuttard, tpr, t-tye, hiraditya, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D64636

llvm-svn: 365904
llvm/lib/Target/AMDGPU/AMDGPUISelDAGToDAG.cpp
llvm/lib/Target/AMDGPU/SIInstrInfo.td
llvm/lib/Target/AMDGPU/SIInstructions.td
llvm/test/CodeGen/AMDGPU/v_cndmask.ll