OSDN Git Service

AMDGPU: Remove dx10-clamp from subtarget features
authorMatt Arsenault <Matthew.Arsenault@amd.com>
Fri, 29 Mar 2019 19:14:54 +0000 (19:14 +0000)
committerMatt Arsenault <Matthew.Arsenault@amd.com>
Fri, 29 Mar 2019 19:14:54 +0000 (19:14 +0000)
commit234b3a117e8a966a077e154eba0241fa00622871
tree7d0457289975c9f4d5e01c70b7bf93e987d81baf
parent966d4dc9697fab248575a3b99de53bae284f6709
AMDGPU: Remove dx10-clamp from subtarget features

Since this can be set with s_setreg*, it should not be a subtarget
property. Set a default based on the calling convention, and Introduce
a new amdgpu-dx10-clamp attribute to override this if desired.

Also introduce a new amdgpu-ieee attribute to match.

The values need to match to allow inlining. I think it is OK for the
caller's dx10-clamp attribute to override the callee, but there
doesn't appear to be the infrastructure to do this currently without
definining the attribute in the generic Attributes.td.

Eventually the calling convention lowering will need to insert a mode
switch somewhere for these.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@357302 91177308-0d34-0410-b5e6-96231b3b80d8
17 files changed:
docs/AMDGPUUsage.rst
lib/Target/AMDGPU/AMDGPUAsmPrinter.cpp
lib/Target/AMDGPU/AMDGPUFeatures.td
lib/Target/AMDGPU/AMDGPUSubtarget.cpp
lib/Target/AMDGPU/AMDGPUSubtarget.h
lib/Target/AMDGPU/AMDGPUTargetTransformInfo.cpp
lib/Target/AMDGPU/SIFoldOperands.cpp
lib/Target/AMDGPU/SIISelLowering.cpp
lib/Target/AMDGPU/SIMachineFunctionInfo.cpp
lib/Target/AMDGPU/SIMachineFunctionInfo.h
lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.cpp
lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.h
test/CodeGen/AMDGPU/amdgcn-ieee.ll [new file with mode: 0644]
test/CodeGen/AMDGPU/clamp.ll
test/CodeGen/AMDGPU/hsa-fp-mode.ll
test/Transforms/Inline/AMDGPU/inline-amdgpu-dx10.ll [new file with mode: 0644]
test/Transforms/Inline/AMDGPU/inline-amdgpu-ieee.ll [new file with mode: 0644]