• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1//===-- R600Processors.td - R600 Processor definitions --------------------===//
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
10class SubtargetFeatureFetchLimit <string Value> :
11                          SubtargetFeature <"fetch"#Value,
12  "TexVTXClauseSize",
13  Value,
14  "Limit the maximum number of fetches in a clause to "#Value
15>;
16
17def FeatureR600ALUInst : SubtargetFeature<"R600ALUInst",
18  "R600ALUInst",
19  "false",
20  "Older version of ALU instructions encoding"
21>;
22
23def FeatureFetchLimit8 : SubtargetFeatureFetchLimit <"8">;
24def FeatureFetchLimit16 : SubtargetFeatureFetchLimit <"16">;
25
26def FeatureVertexCache : SubtargetFeature<"HasVertexCache",
27  "HasVertexCache",
28  "true",
29  "Specify use of dedicated vertex cache"
30>;
31
32def FeatureCaymanISA : SubtargetFeature<"caymanISA",
33  "CaymanISA",
34  "true",
35  "Use Cayman ISA"
36>;
37
38def FeatureCFALUBug : SubtargetFeature<"cfalubug",
39  "CFALUBug",
40  "true",
41  "GPU has CF_ALU bug"
42>;
43
44class R600SubtargetFeatureGeneration <string Value,
45                                  list<SubtargetFeature> Implies> :
46        SubtargetFeatureGeneration <Value, "R600Subtarget", Implies>;
47
48def FeatureR600 : R600SubtargetFeatureGeneration<"R600",
49  [FeatureR600ALUInst, FeatureFetchLimit8, FeatureLocalMemorySize0]
50>;
51
52def FeatureR700 : R600SubtargetFeatureGeneration<"R700",
53  [FeatureFetchLimit16, FeatureLocalMemorySize0]
54>;
55
56def FeatureEvergreen : R600SubtargetFeatureGeneration<"EVERGREEN",
57  [FeatureFetchLimit16, FeatureLocalMemorySize32768]
58>;
59
60def FeatureNorthernIslands : R600SubtargetFeatureGeneration<"NORTHERN_ISLANDS",
61  [FeatureFetchLimit16, FeatureWavefrontSize64,
62   FeatureLocalMemorySize32768]
63>;
64
65
66//===----------------------------------------------------------------------===//
67// Radeon HD 2000/3000 Series (R600).
68//===----------------------------------------------------------------------===//
69
70def : Processor<"r600", R600_VLIW5_Itin,
71  [FeatureR600, FeatureWavefrontSize64, FeatureVertexCache]
72>;
73
74def : Processor<"r630", R600_VLIW5_Itin,
75  [FeatureR600, FeatureWavefrontSize32, FeatureVertexCache]
76>;
77
78def : Processor<"rs880", R600_VLIW5_Itin,
79  [FeatureR600, FeatureWavefrontSize16]
80>;
81
82def : Processor<"rv670", R600_VLIW5_Itin,
83  [FeatureR600, FeatureWavefrontSize64, FeatureVertexCache]
84>;
85
86//===----------------------------------------------------------------------===//
87// Radeon HD 4000 Series (R700).
88//===----------------------------------------------------------------------===//
89
90def : Processor<"rv710", R600_VLIW5_Itin,
91  [FeatureR700, FeatureWavefrontSize32, FeatureVertexCache]
92>;
93
94def : Processor<"rv730", R600_VLIW5_Itin,
95  [FeatureR700, FeatureWavefrontSize32, FeatureVertexCache]
96>;
97
98def : Processor<"rv770", R600_VLIW5_Itin,
99  [FeatureR700, FeatureWavefrontSize64, FeatureVertexCache]
100>;
101
102//===----------------------------------------------------------------------===//
103// Radeon HD 5000 Series (Evergreen).
104//===----------------------------------------------------------------------===//
105
106def : Processor<"cedar", R600_VLIW5_Itin,
107  [FeatureEvergreen, FeatureWavefrontSize32, FeatureVertexCache,
108   FeatureCFALUBug]
109>;
110
111def : Processor<"cypress", R600_VLIW5_Itin,
112  [FeatureEvergreen, FeatureWavefrontSize64, FeatureVertexCache, FeatureFMA]
113>;
114
115def : Processor<"juniper", R600_VLIW5_Itin,
116  [FeatureEvergreen, FeatureWavefrontSize64, FeatureVertexCache]
117>;
118
119def : Processor<"redwood", R600_VLIW5_Itin,
120  [FeatureEvergreen, FeatureWavefrontSize64, FeatureVertexCache,
121   FeatureCFALUBug]
122>;
123
124def : Processor<"sumo", R600_VLIW5_Itin,
125  [FeatureEvergreen, FeatureWavefrontSize64, FeatureCFALUBug]
126>;
127
128//===----------------------------------------------------------------------===//
129// Radeon HD 6000 Series (Northern Islands).
130//===----------------------------------------------------------------------===//
131
132def : Processor<"barts", R600_VLIW5_Itin,
133  [FeatureNorthernIslands, FeatureVertexCache, FeatureCFALUBug]
134>;
135
136def : Processor<"caicos", R600_VLIW5_Itin,
137  [FeatureNorthernIslands, FeatureCFALUBug]
138>;
139
140def : Processor<"cayman", R600_VLIW4_Itin,
141  [FeatureNorthernIslands, FeatureCaymanISA, FeatureFMA]
142>;
143
144def : Processor<"turks", R600_VLIW5_Itin,
145  [FeatureNorthernIslands, FeatureVertexCache, FeatureCFALUBug]
146>;
147