]> granicus.if.org Git - llvm/commit
AMDGPU: Make f16 ConstantFP legal
authorMatt Arsenault <Matthew.Arsenault@amd.com>
Thu, 8 Dec 2016 20:14:46 +0000 (20:14 +0000)
committerMatt Arsenault <Matthew.Arsenault@amd.com>
Thu, 8 Dec 2016 20:14:46 +0000 (20:14 +0000)
commitbeec226db531a440c63ed48c4b66fd12da24724f
treea4db561d2f63d0ce04f02acc32dc6e18064d0348
parent00f1f5a96172e6c85bae345b6209958ba94444ae
AMDGPU: Make f16 ConstantFP legal

Not having this legal led to combine failures, resulting
in dumb things like bitcasts of constants not being folded
away.

The only reason I'm leaving the v_mov_b32 hack that f32
already uses is to avoid madak formation test regressions.
PeepholeOptimizer has an ordering issue where the immediate
fold attempt is into the sgpr->vgpr copy instead of the actual
use. Running it twice avoids that problem.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@289096 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/AMDGPU/SIISelLowering.cpp
lib/Target/AMDGPU/SIISelLowering.h
lib/Target/AMDGPU/SIInstructions.td
test/CodeGen/AMDGPU/br_cc.f16.ll