aboutsummaryrefslogtreecommitdiffstats
path: root/lib/Target/R600/R600RegisterInfo.cpp
diff options
context:
space:
mode:
authorTom Stellard <thomas.stellard@amd.com>2013-01-23 02:09:06 +0000
committerTom Stellard <thomas.stellard@amd.com>2013-01-23 02:09:06 +0000
commit9f7818d9bdfce2e9c7a2cbe31490a135aa6d1211 (patch)
tree31e05a5bfa8a0ff244b3d281a107be0bb71effbb /lib/Target/R600/R600RegisterInfo.cpp
parentc7e1888d93f4cb2982266986f3af7e99df631fa1 (diff)
downloadexternal_llvm-9f7818d9bdfce2e9c7a2cbe31490a135aa6d1211.zip
external_llvm-9f7818d9bdfce2e9c7a2cbe31490a135aa6d1211.tar.gz
external_llvm-9f7818d9bdfce2e9c7a2cbe31490a135aa6d1211.tar.bz2
R600: rework handling of the constants
Remove Cxxx registers, add new special register - "ALU_CONST" and new operand for each alu src - "sel". ALU_CONST is used to designate that the new operand contains the value to override src.sel, src.kc_bank, src.chan for constants in the driver. Patch by: Vadim Girlin Vincent Lejeune: - Use pointers for constants - Fold CONST_ADDRESS when possible Tom Stellard: - Give CONSTANT_BUFFER_0 its own address space - Use integer types for constant loads Reviewed-by: Tom Stellard <thomas.stellard@amd.com> git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173222 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Target/R600/R600RegisterInfo.cpp')
-rw-r--r--lib/Target/R600/R600RegisterInfo.cpp6
1 files changed, 1 insertions, 5 deletions
diff --git a/lib/Target/R600/R600RegisterInfo.cpp b/lib/Target/R600/R600RegisterInfo.cpp
index a39f83d..0441e4a 100644
--- a/lib/Target/R600/R600RegisterInfo.cpp
+++ b/lib/Target/R600/R600RegisterInfo.cpp
@@ -38,16 +38,12 @@ BitVector R600RegisterInfo::getReservedRegs(const MachineFunction &MF) const {
Reserved.set(AMDGPU::NEG_ONE);
Reserved.set(AMDGPU::PV_X);
Reserved.set(AMDGPU::ALU_LITERAL_X);
+ Reserved.set(AMDGPU::ALU_CONST);
Reserved.set(AMDGPU::PREDICATE_BIT);
Reserved.set(AMDGPU::PRED_SEL_OFF);
Reserved.set(AMDGPU::PRED_SEL_ZERO);
Reserved.set(AMDGPU::PRED_SEL_ONE);
- for (TargetRegisterClass::iterator I = AMDGPU::R600_CReg32RegClass.begin(),
- E = AMDGPU::R600_CReg32RegClass.end(); I != E; ++I) {
- Reserved.set(*I);
- }
-
for (std::vector<unsigned>::const_iterator I = MFI->ReservedRegs.begin(),
E = MFI->ReservedRegs.end(); I != E; ++I) {
Reserved.set(*I);