]> granicus.if.org Git - llvm/commit
AMDGPU: Default to using scalar mov to materialize immediate
authorMatt Arsenault <Matthew.Arsenault@amd.com>
Tue, 1 Nov 2016 22:55:07 +0000 (22:55 +0000)
committerMatt Arsenault <Matthew.Arsenault@amd.com>
Tue, 1 Nov 2016 22:55:07 +0000 (22:55 +0000)
commite9a23c4c57a235ead3003196c1ae1de05aa79fc6
treea5e8ba4a1591a383147431eba7b701b486cb57fa
parentfd64fad2439726f97df4c555e9fbea9746e96981
AMDGPU: Default to using scalar mov to materialize immediate

This is the conservatively correct way because it's easy to
move or replace a scalar immediate. This was incorrect in the case
when the register class wasn't known from the static instruction
definition, but still needed to be an SGPR. The main example of this
is inlineasm has an SGPR constraint.

Also start verifying the register classes of inlineasm operands.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@285762 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/AMDGPU/SIInstrInfo.cpp
lib/Target/AMDGPU/SIInstrInfo.td
lib/Target/AMDGPU/SIInstructions.td
test/CodeGen/AMDGPU/control-flow-fastregalloc.ll
test/CodeGen/AMDGPU/inline-constraints.ll
test/CodeGen/AMDGPU/insert_vector_elt.ll