R600RegisterInfo.h revision a75c6163e605f35b14f26930dd9227e4f337ec9e
1a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard//===-- R600RegisterInfo.h - TODO: Add brief description -------===// 2a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard// 3a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard// The LLVM Compiler Infrastructure 4a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard// 5a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard// This file is distributed under the University of Illinois Open Source 6a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard// License. See LICENSE.TXT for details. 7a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard// 8a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard//===----------------------------------------------------------------------===// 9a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard// 10a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard// TODO: Add full description 11a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard// 12a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard//===----------------------------------------------------------------------===// 13a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard 14a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard#ifndef R600REGISTERINFO_H_ 15a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard#define R600REGISTERINFO_H_ 16a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard 17a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard#include "AMDGPUTargetMachine.h" 18a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard#include "AMDILRegisterInfo.h" 19a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard 20a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellardnamespace llvm { 21a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard 22a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard class R600TargetMachine; 23a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard class TargetInstrInfo; 24a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard 25a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard struct R600RegisterInfo : public AMDGPURegisterInfo 26a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard { 27a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard AMDGPUTargetMachine &TM; 28a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard const TargetInstrInfo &TII; 29a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard 30a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard R600RegisterInfo(AMDGPUTargetMachine &tm, const TargetInstrInfo &tii); 31a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard 32a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard virtual BitVector getReservedRegs(const MachineFunction &MF) const; 33a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard 34a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard virtual const TargetRegisterClass * 35a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard getISARegClass(const TargetRegisterClass * rc) const; 36a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard unsigned getHWRegIndex(unsigned reg) const; 37a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard unsigned getHWRegChan(unsigned reg) const; 38a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellardprivate: 39a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard unsigned getHWRegChanGen(unsigned reg) const; 40a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard unsigned getHWRegIndexGen(unsigned reg) const; 41a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard }; 42a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard} // End namespace llvm 43a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard 44a75c6163e605f35b14f26930dd9227e4f337ec9eTom Stellard#endif // AMDIDSAREGISTERINFO_H_ 45