1 //===------- AMDILNIDevice.h - Define NI Device for AMDIL -*- C++ -*------===// 2 // 3 // The LLVM Compiler Infrastructure 4 // 5 // This file is distributed under the University of Illinois Open Source 6 // License. See LICENSE.TXT for details. 7 // 8 //==-----------------------------------------------------------------------===// 9 /// \file 10 /// \brief Interface for the subtarget data classes. 11 /// 12 /// This file will define the interface that each generation needs to 13 /// implement in order to correctly answer queries on the capabilities of the 14 /// specific hardware. 15 //===---------------------------------------------------------------------===// 16 #ifndef AMDILNIDEVICE_H 17 #define AMDILNIDEVICE_H 18 #include "AMDGPUSubtarget.h" 19 #include "AMDILEvergreenDevice.h" 20 21 namespace llvm { 22 23 class AMDGPUSubtarget; 24 //===---------------------------------------------------------------------===// 25 // NI generation of devices and their respective sub classes 26 //===---------------------------------------------------------------------===// 27 28 /// \brief The AMDGPUNIDevice is the base class for all Northern Island series of 29 /// cards. 30 /// 31 /// It is very similiar to the AMDGPUEvergreenDevice, with the major 32 /// exception being differences in wavefront size and hardware capabilities. The 33 /// NI devices are all 64 wide wavefronts and also add support for signed 24 bit 34 /// integer operations 35 class AMDGPUNIDevice : public AMDGPUEvergreenDevice { 36 public: 37 AMDGPUNIDevice(AMDGPUSubtarget*); 38 virtual ~AMDGPUNIDevice(); 39 virtual size_t getMaxLDSSize() const; 40 virtual uint32_t getGeneration() const; 41 }; 42 43 /// Just as the AMDGPUCypressDevice is the double capable version of the 44 /// AMDGPUEvergreenDevice, the AMDGPUCaymanDevice is the double capable version 45 /// of the AMDGPUNIDevice. The other major difference is that the Cayman Device 46 /// has 4 wide ALU's, whereas the rest of the NI family is a 5 wide. 47 class AMDGPUCaymanDevice: public AMDGPUNIDevice { 48 public: 49 AMDGPUCaymanDevice(AMDGPUSubtarget*); 50 virtual ~AMDGPUCaymanDevice(); 51 private: 52 virtual void setCaps(); 53 }; 54 55 static const unsigned int MAX_LDS_SIZE_900 = AMDGPUDevice::MAX_LDS_SIZE_800; 56 } // namespace llvm 57 #endif // AMDILNIDEVICE_H 58