clang 22.0.0git
AMDGPU.h
Go to the documentation of this file.
1//===--- AMDGPU.h - Declare AMDGPU target feature support -------*- C++ -*-===//
2//
3// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4// See https://llvm.org/LICENSE.txt for license information.
5// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6//
7//===----------------------------------------------------------------------===//
8//
9// This file declares AMDGPU TargetInfo objects.
10//
11//===----------------------------------------------------------------------===//
12
13#ifndef LLVM_CLANG_LIB_BASIC_TARGETS_AMDGPU_H
14#define LLVM_CLANG_LIB_BASIC_TARGETS_AMDGPU_H
15
19#include "llvm/ADT/StringSet.h"
20#include "llvm/Support/AMDGPUAddrSpace.h"
21#include "llvm/Support/Compiler.h"
22#include "llvm/TargetParser/TargetParser.h"
23#include "llvm/TargetParser/Triple.h"
24#include <optional>
25
26namespace clang {
27namespace targets {
28
29class LLVM_LIBRARY_VISIBILITY AMDGPUTargetInfo final : public TargetInfo {
30
31 static const char *const GCCRegNames[];
32
33 static const LangASMap AMDGPUDefIsGenMap;
34 static const LangASMap AMDGPUDefIsPrivMap;
35
36 llvm::AMDGPU::GPUKind GPUKind;
37 unsigned GPUFeatures;
38 unsigned WavefrontSize;
39
40 /// Whether to use cumode or WGP mode. True for cumode. False for WGP mode.
41 bool CUMode;
42
43 /// Whether having image instructions.
44 bool HasImage = false;
45
46 /// Target ID is device name followed by optional feature name postfixed
47 /// by plus or minus sign delimitted by colon, e.g. gfx908:xnack+:sramecc-.
48 /// If the target ID contains feature+, map it to true.
49 /// If the target ID contains feature-, map it to false.
50 /// If the target ID does not contain a feature (default), do not map it.
51 llvm::StringMap<bool> OffloadArchFeatures;
52 std::string TargetID;
53
54 bool hasFP64() const {
55 return getTriple().isAMDGCN() ||
56 !!(GPUFeatures & llvm::AMDGPU::FEATURE_FP64);
57 }
58
59 /// Has fast fma f32
60 bool hasFastFMAF() const {
61 return !!(GPUFeatures & llvm::AMDGPU::FEATURE_FAST_FMA_F32);
62 }
63
64 /// Has fast fma f64
65 bool hasFastFMA() const { return getTriple().isAMDGCN(); }
66
67 bool hasFMAF() const {
68 return getTriple().isAMDGCN() ||
69 !!(GPUFeatures & llvm::AMDGPU::FEATURE_FMA);
70 }
71
72 bool hasFullRateDenormalsF32() const {
73 return !!(GPUFeatures & llvm::AMDGPU::FEATURE_FAST_DENORMAL_F32);
74 }
75
76 bool hasLDEXPF() const {
77 return getTriple().isAMDGCN() ||
78 !!(GPUFeatures & llvm::AMDGPU::FEATURE_LDEXP);
79 }
80
81 static bool isAMDGCN(const llvm::Triple &TT) { return TT.isAMDGCN(); }
82
83 static bool isR600(const llvm::Triple &TT) {
84 return TT.getArch() == llvm::Triple::r600;
85 }
86
87 bool hasFlatSupport() const {
88 if (GPUKind >= llvm::AMDGPU::GK_GFX700)
89 return true;
90
91 // Dummy target is assumed to be gfx700+ for amdhsa.
92 if (GPUKind == llvm::AMDGPU::GK_NONE &&
93 getTriple().getOS() == llvm::Triple::AMDHSA)
94 return true;
95
96 return false;
97 }
98
99public:
100 AMDGPUTargetInfo(const llvm::Triple &Triple, const TargetOptions &Opts);
101
102 void setAddressSpaceMap(bool DefaultIsPrivate);
103
104 void adjust(DiagnosticsEngine &Diags, LangOptions &Opts,
105 const TargetInfo *Aux) override;
106
107 uint64_t getPointerWidthV(LangAS AS) const override {
108 if (isR600(getTriple()))
109 return 32;
110 unsigned TargetAS = getTargetAddressSpace(AS);
111
112 if (TargetAS == llvm::AMDGPUAS::PRIVATE_ADDRESS ||
113 TargetAS == llvm::AMDGPUAS::LOCAL_ADDRESS)
114 return 32;
115
116 return 64;
117 }
118
119 uint64_t getPointerAlignV(LangAS AddrSpace) const override {
120 return getPointerWidthV(AddrSpace);
121 }
122
123 virtual bool isAddressSpaceSupersetOf(LangAS A, LangAS B) const override {
124 // The flat address space AS(0) is a superset of all the other address
125 // spaces used by the backend target.
126 return A == B ||
127 ((A == LangAS::Default ||
129 toTargetAddressSpace(A) == llvm::AMDGPUAS::FLAT_ADDRESS)) &&
131 toTargetAddressSpace(B) >= llvm::AMDGPUAS::FLAT_ADDRESS &&
132 toTargetAddressSpace(B) <= llvm::AMDGPUAS::PRIVATE_ADDRESS &&
133 toTargetAddressSpace(B) != llvm::AMDGPUAS::REGION_ADDRESS);
134 }
135
136 uint64_t getMaxPointerWidth() const override {
137 return getTriple().isAMDGCN() ? 64 : 32;
138 }
139
140 bool hasBFloat16Type() const override { return isAMDGCN(getTriple()); }
141
142 std::string_view getClobbers() const override { return ""; }
143
144 ArrayRef<const char *> getGCCRegNames() const override;
145
147 return {};
148 }
149
150 /// Accepted register names: (n, m is unsigned integer, n < m)
151 /// v
152 /// s
153 /// a
154 /// {vn}, {v[n]}
155 /// {sn}, {s[n]}
156 /// {an}, {a[n]}
157 /// {S} , where S is a special register name
158 ////{v[n:m]}
159 /// {s[n:m]}
160 /// {a[n:m]}
161 bool validateAsmConstraint(const char *&Name,
162 TargetInfo::ConstraintInfo &Info) const override {
163 static const ::llvm::StringSet<> SpecialRegs({
164 "exec", "vcc", "flat_scratch", "m0", "scc", "tba", "tma",
165 "flat_scratch_lo", "flat_scratch_hi", "vcc_lo", "vcc_hi", "exec_lo",
166 "exec_hi", "tma_lo", "tma_hi", "tba_lo", "tba_hi",
167 });
168
169 switch (*Name) {
170 case 'I':
171 Info.setRequiresImmediate(-16, 64);
172 return true;
173 case 'J':
174 Info.setRequiresImmediate(-32768, 32767);
175 return true;
176 case 'A':
177 case 'B':
178 case 'C':
180 return true;
181 default:
182 break;
183 }
184
185 StringRef S(Name);
186
187 if (S == "DA" || S == "DB") {
188 Name++;
190 return true;
191 }
192
193 bool HasLeftParen = S.consume_front("{");
194 if (S.empty())
195 return false;
196 if (S.front() != 'v' && S.front() != 's' && S.front() != 'a') {
197 if (!HasLeftParen)
198 return false;
199 auto E = S.find('}');
200 if (!SpecialRegs.count(S.substr(0, E)))
201 return false;
202 S = S.drop_front(E + 1);
203 if (!S.empty())
204 return false;
205 // Found {S} where S is a special register.
206 Info.setAllowsRegister();
207 Name = S.data() - 1;
208 return true;
209 }
210 S = S.drop_front();
211 if (!HasLeftParen) {
212 if (!S.empty())
213 return false;
214 // Found s, v or a.
215 Info.setAllowsRegister();
216 Name = S.data() - 1;
217 return true;
218 }
219 bool HasLeftBracket = S.consume_front("[");
220 unsigned long long N;
221 if (S.empty() || consumeUnsignedInteger(S, 10, N))
222 return false;
223 if (S.consume_front(":")) {
224 if (!HasLeftBracket)
225 return false;
226 unsigned long long M;
227 if (consumeUnsignedInteger(S, 10, M) || N >= M)
228 return false;
229 }
230 if (HasLeftBracket) {
231 if (!S.consume_front("]"))
232 return false;
233 }
234 if (!S.consume_front("}"))
235 return false;
236 if (!S.empty())
237 return false;
238 // Found {vn}, {sn}, {an}, {v[n]}, {s[n]}, {a[n]}, {v[n:m]}, {s[n:m]}
239 // or {a[n:m]}.
240 Info.setAllowsRegister();
241 Name = S.data() - 1;
242 return true;
243 }
244
245 // \p Constraint will be left pointing at the last character of
246 // the constraint. In practice, it won't be changed unless the
247 // constraint is longer than one character.
248 std::string convertConstraint(const char *&Constraint) const override {
249
250 StringRef S(Constraint);
251 if (S == "DA" || S == "DB") {
252 return std::string("^") + std::string(Constraint++, 2);
253 }
254
255 const char *Begin = Constraint;
256 TargetInfo::ConstraintInfo Info("", "");
257 if (validateAsmConstraint(Constraint, Info))
258 return std::string(Begin).substr(0, Constraint - Begin + 1);
259
260 Constraint = Begin;
261 return std::string(1, *Constraint);
262 }
263
264 bool
265 initFeatureMap(llvm::StringMap<bool> &Features, DiagnosticsEngine &Diags,
266 StringRef CPU,
267 const std::vector<std::string> &FeatureVec) const override;
268
269 llvm::SmallVector<Builtin::InfosShard> getTargetBuiltins() const override;
270
271 bool useFP16ConversionIntrinsics() const override { return false; }
272
273 void getTargetDefines(const LangOptions &Opts,
274 MacroBuilder &Builder) const override;
275
279
280 bool isValidCPUName(StringRef Name) const override {
281 if (getTriple().isAMDGCN())
282 return llvm::AMDGPU::parseArchAMDGCN(Name) != llvm::AMDGPU::GK_NONE;
283 return llvm::AMDGPU::parseArchR600(Name) != llvm::AMDGPU::GK_NONE;
284 }
285
286 void fillValidCPUList(SmallVectorImpl<StringRef> &Values) const override;
287
288 bool setCPU(const std::string &Name) override {
289 if (getTriple().isAMDGCN()) {
290 GPUKind = llvm::AMDGPU::parseArchAMDGCN(Name);
291 GPUFeatures = llvm::AMDGPU::getArchAttrAMDGCN(GPUKind);
292 } else {
293 GPUKind = llvm::AMDGPU::parseArchR600(Name);
294 GPUFeatures = llvm::AMDGPU::getArchAttrR600(GPUKind);
295 }
296
297 return GPUKind != llvm::AMDGPU::GK_NONE;
298 }
299
300 void setSupportedOpenCLOpts() override {
301 auto &Opts = getSupportedOpenCLOpts();
302 Opts["cl_clang_storage_class_specifiers"] = true;
303 Opts["__cl_clang_variadic_functions"] = true;
304 Opts["__cl_clang_function_pointers"] = true;
305 Opts["__cl_clang_non_portable_kernel_param_types"] = true;
306 Opts["__cl_clang_bitfields"] = true;
307
308 bool IsAMDGCN = isAMDGCN(getTriple());
309
310 Opts["cl_khr_fp64"] = hasFP64();
311 Opts["__opencl_c_fp64"] = hasFP64();
312
313 if (IsAMDGCN || GPUKind >= llvm::AMDGPU::GK_CEDAR) {
314 Opts["cl_khr_byte_addressable_store"] = true;
315 Opts["cl_khr_global_int32_base_atomics"] = true;
316 Opts["cl_khr_global_int32_extended_atomics"] = true;
317 Opts["cl_khr_local_int32_base_atomics"] = true;
318 Opts["cl_khr_local_int32_extended_atomics"] = true;
319 }
320
321 if (IsAMDGCN) {
322 Opts["cl_khr_fp16"] = true;
323 Opts["cl_khr_int64_base_atomics"] = true;
324 Opts["cl_khr_int64_extended_atomics"] = true;
325 Opts["cl_khr_mipmap_image"] = true;
326 Opts["cl_khr_mipmap_image_writes"] = true;
327 Opts["cl_khr_subgroups"] = true;
328 Opts["cl_amd_media_ops"] = true;
329 Opts["cl_amd_media_ops2"] = true;
330
331 // FIXME: Check subtarget for image support.
332 Opts["__opencl_c_images"] = true;
333 Opts["__opencl_c_3d_image_writes"] = true;
334 Opts["__opencl_c_read_write_images"] = true;
335 Opts["cl_khr_3d_image_writes"] = true;
336 Opts["__opencl_c_program_scope_global_variables"] = true;
337 Opts["__opencl_c_atomic_order_acq_rel"] = true;
338 Opts["__opencl_c_atomic_order_seq_cst"] = true;
339 Opts["__opencl_c_atomic_scope_device"] = true;
340 Opts["__opencl_c_atomic_scope_all_devices"] = true;
341 Opts["__opencl_c_work_group_collective_functions"] = true;
342
343 if (hasFlatSupport()) {
344 Opts["__opencl_c_generic_address_space"] = true;
345 Opts["__opencl_c_device_enqueue"] = true;
346 Opts["__opencl_c_pipes"] = true;
347 }
348 }
349 }
350
352 switch (TK) {
353 case OCLTK_Image:
355
356 case OCLTK_ClkEvent:
357 case OCLTK_Queue:
358 case OCLTK_ReserveID:
360
361 default:
363 }
364 }
365
366 LangAS getOpenCLBuiltinAddressSpace(unsigned AS) const override {
367 switch (AS) {
368 case 0:
370 case 1:
372 case 3:
374 case 4:
376 case 5:
378 default:
379 return getLangASFromTargetAS(AS);
380 }
381 }
382
383 LangAS getCUDABuiltinAddressSpace(unsigned AS) const override {
384 switch (AS) {
385 case 0:
386 return LangAS::Default;
387 case 1:
388 return LangAS::cuda_device;
389 case 3:
390 return LangAS::cuda_shared;
391 case 4:
393 default:
394 return getLangASFromTargetAS(AS);
395 }
396 }
397
398 std::optional<LangAS> getConstantAddressSpace() const override {
399 return getLangASFromTargetAS(llvm::AMDGPUAS::CONSTANT_ADDRESS);
400 }
401
402 const llvm::omp::GV &getGridValue() const override {
403 switch (WavefrontSize) {
404 case 32:
405 return llvm::omp::getAMDGPUGridValues<32>();
406 case 64:
407 return llvm::omp::getAMDGPUGridValues<64>();
408 default:
409 llvm_unreachable("getGridValue not implemented for this wavesize");
410 }
411 }
412
413 /// \returns Target specific vtbl ptr address space.
414 unsigned getVtblPtrAddressSpace() const override {
415 return static_cast<unsigned>(llvm::AMDGPUAS::CONSTANT_ADDRESS);
416 }
417
418 /// \returns If a target requires an address within a target specific address
419 /// space \p AddressSpace to be converted in order to be used, then return the
420 /// corresponding target specific DWARF address space.
421 ///
422 /// \returns Otherwise return std::nullopt and no conversion will be emitted
423 /// in the DWARF.
424 std::optional<unsigned>
425 getDWARFAddressSpace(unsigned AddressSpace) const override {
426 int DWARFAS = llvm::AMDGPU::mapToDWARFAddrSpace(AddressSpace);
427 // If there is no corresponding address space identifier, or it would be
428 // the default, then don't emit the attribute.
429 if (DWARFAS == -1 || DWARFAS == llvm::AMDGPU::DWARFAS::DEFAULT)
430 return std::nullopt;
431 return DWARFAS;
432 }
433
435 switch (CC) {
436 default:
437 return CCCR_Warning;
438 case CC_C:
439 case CC_DeviceKernel:
440 return CCCR_OK;
441 }
442 }
443
444 // In amdgcn target the null pointer in global, constant, and generic
445 // address space has value 0 but in private and local address space has
446 // value ~0.
447 uint64_t getNullPointerValue(LangAS AS) const override {
448 // FIXME: Also should handle region.
449 return (AS == LangAS::opencl_local || AS == LangAS::opencl_private ||
451 ? ~0
452 : 0;
453 }
454
455 void setAuxTarget(const TargetInfo *Aux) override;
456
457 bool hasBitIntType() const override { return true; }
458
459 // Record offload arch features since they are needed for defining the
460 // pre-defined macros.
461 bool handleTargetFeatures(std::vector<std::string> &Features,
462 DiagnosticsEngine &Diags) override {
463 HasFullBFloat16 = true;
464 auto TargetIDFeatures =
465 getAllPossibleTargetIDFeatures(getTriple(), getArchNameAMDGCN(GPUKind));
466 for (const auto &F : Features) {
467 assert(F.front() == '+' || F.front() == '-');
468 if (F == "+wavefrontsize64")
469 WavefrontSize = 64;
470 else if (F == "+cumode")
471 CUMode = true;
472 else if (F == "-cumode")
473 CUMode = false;
474 else if (F == "+image-insts")
475 HasImage = true;
476 bool IsOn = F.front() == '+';
477 StringRef Name = StringRef(F).drop_front();
478 if (!llvm::is_contained(TargetIDFeatures, Name))
479 continue;
480 assert(!OffloadArchFeatures.contains(Name));
481 OffloadArchFeatures[Name] = IsOn;
482 }
483 return true;
484 }
485
486 std::optional<std::string> getTargetID() const override {
487 if (!isAMDGCN(getTriple()))
488 return std::nullopt;
489 // When -target-cpu is not set, we assume generic code that it is valid
490 // for all GPU and use an empty string as target ID to represent that.
491 if (GPUKind == llvm::AMDGPU::GK_NONE)
492 return std::string("");
493 return getCanonicalTargetID(getArchNameAMDGCN(GPUKind),
494 OffloadArchFeatures);
495 }
496
497 bool hasHIPImageSupport() const override { return HasImage; }
498
499 std::pair<unsigned, unsigned> hardwareInterferenceSizes() const override {
500 // This is imprecise as the value can vary between 64, 128 (even 256!) bytes
501 // depending on the level of cache and the target architecture. We select
502 // the size that corresponds to the largest L1 cache line for all
503 // architectures.
504 return std::make_pair(128, 128);
505 }
506};
507
508} // namespace targets
509} // namespace clang
510
511#endif // LLVM_CLANG_LIB_BASIC_TARGETS_AMDGPU_H
Defines the clang::TargetOptions class.
Concrete class used by the front-end to report problems and issues.
Definition Diagnostic.h:232
Keeps track of the various options that can be enabled, which controls the dialect of C or C++ that i...
Exposes information about the current target.
Definition TargetInfo.h:226
TargetInfo(const llvm::Triple &T)
const llvm::Triple & getTriple() const
Returns the target triple of the primary target.
BuiltinVaListKind
The different kinds of __builtin_va_list types defined by the target implementation.
Definition TargetInfo.h:333
@ CharPtrBuiltinVaList
typedef char* __builtin_va_list;
Definition TargetInfo.h:335
virtual LangAS getOpenCLTypeAddrSpace(OpenCLTypeKind TK) const
Get address space for OpenCL type.
llvm::StringMap< bool > & getSupportedOpenCLOpts()
Get supported OpenCL extensions and optional core features.
unsigned getTargetAddressSpace(LangAS AS) const
Options for controlling the target.
const llvm::omp::GV & getGridValue() const override
Definition AMDGPU.h:402
std::string_view getClobbers() const override
Returns a string of target-specific clobbers, in LLVM format.
Definition AMDGPU.h:142
uint64_t getPointerAlignV(LangAS AddrSpace) const override
Definition AMDGPU.h:119
LangAS getOpenCLBuiltinAddressSpace(unsigned AS) const override
Map from the address space field in builtin description strings to the language address space.
Definition AMDGPU.h:366
AMDGPUTargetInfo(const llvm::Triple &Triple, const TargetOptions &Opts)
Definition AMDGPU.cpp:221
uint64_t getPointerWidthV(LangAS AS) const override
Definition AMDGPU.h:107
bool setCPU(const std::string &Name) override
Target the specified CPU.
Definition AMDGPU.h:288
ArrayRef< TargetInfo::GCCRegAlias > getGCCRegAliases() const override
Definition AMDGPU.h:146
bool hasBFloat16Type() const override
Determine whether the _BFloat16 type is supported on this target.
Definition AMDGPU.h:140
uint64_t getNullPointerValue(LangAS AS) const override
Get integer value for null pointer.
Definition AMDGPU.h:447
void adjust(DiagnosticsEngine &Diags, LangOptions &Opts, const TargetInfo *Aux) override
Set forced language options.
Definition AMDGPU.cpp:265
LangAS getCUDABuiltinAddressSpace(unsigned AS) const override
Map from the address space field in builtin description strings to the language address space.
Definition AMDGPU.h:383
virtual bool isAddressSpaceSupersetOf(LangAS A, LangAS B) const override
Returns true if an address space can be safely converted to another.
Definition AMDGPU.h:123
bool useFP16ConversionIntrinsics() const override
Check whether llvm intrinsics such as llvm.convert.to.fp16 should be used to convert to and from __fp...
Definition AMDGPU.h:271
void setAddressSpaceMap(bool DefaultIsPrivate)
Definition AMDGPU.cpp:217
bool handleTargetFeatures(std::vector< std::string > &Features, DiagnosticsEngine &Diags) override
Perform initialization based on the user configured set of features (e.g., +sse4).
Definition AMDGPU.h:461
bool validateAsmConstraint(const char *&Name, TargetInfo::ConstraintInfo &Info) const override
Accepted register names: (n, m is unsigned integer, n < m) v s a {vn}, {v[n]} {sn}...
Definition AMDGPU.h:161
std::optional< std::string > getTargetID() const override
Returns the target ID if supported.
Definition AMDGPU.h:486
std::optional< unsigned > getDWARFAddressSpace(unsigned AddressSpace) const override
Definition AMDGPU.h:425
std::string convertConstraint(const char *&Constraint) const override
Definition AMDGPU.h:248
std::pair< unsigned, unsigned > hardwareInterferenceSizes() const override
The first value in the pair is the minimum offset between two objects to avoid false sharing (destruc...
Definition AMDGPU.h:499
unsigned getVtblPtrAddressSpace() const override
Definition AMDGPU.h:414
std::optional< LangAS > getConstantAddressSpace() const override
Return an AST address space which can be used opportunistically for constant global memory.
Definition AMDGPU.h:398
bool isValidCPUName(StringRef Name) const override
Determine whether this TargetInfo supports the given CPU name.
Definition AMDGPU.h:280
bool hasBitIntType() const override
Determine whether the _BitInt type is supported on this target.
Definition AMDGPU.h:457
bool hasHIPImageSupport() const override
Whether to support HIP image/texture API's.
Definition AMDGPU.h:497
uint64_t getMaxPointerWidth() const override
Return the maximum width of pointers on this target.
Definition AMDGPU.h:136
CallingConvCheckResult checkCallingConvention(CallingConv CC) const override
Determines whether a given calling convention is valid for the target.
Definition AMDGPU.h:434
LangAS getOpenCLTypeAddrSpace(OpenCLTypeKind TK) const override
Get address space for OpenCL type.
Definition AMDGPU.h:351
void setSupportedOpenCLOpts() override
Set supported OpenCL extensions and optional core features.
Definition AMDGPU.h:300
BuiltinVaListKind getBuiltinVaListKind() const override
Returns the kind of __builtin_va_list type that should be used with this target.
Definition AMDGPU.h:276
Defines the clang::TargetInfo interface.
The JSON file list parser is used to communicate input to InstallAPI.
bool isTargetAddressSpace(LangAS AS)
OpenCLTypeKind
OpenCL type kinds.
Definition TargetInfo.h:212
@ OCLTK_ReserveID
Definition TargetInfo.h:219
@ OCLTK_Image
Definition TargetInfo.h:216
@ OCLTK_ClkEvent
Definition TargetInfo.h:214
@ OCLTK_Queue
Definition TargetInfo.h:218
unsigned toTargetAddressSpace(LangAS AS)
llvm::SmallVector< llvm::StringRef, 4 > getAllPossibleTargetIDFeatures(const llvm::Triple &T, llvm::StringRef Processor)
Get all feature strings that can be used in target ID for Processor.
Definition TargetID.cpp:41
LangAS
Defines the address space values used by the address space qualifier of QualType.
std::string getCanonicalTargetID(llvm::StringRef Processor, const llvm::StringMap< bool > &Features)
Returns canonical target ID, assuming Processor is canonical and all entries in Features are valid.
Definition TargetID.cpp:130
CallingConv
CallingConv - Specifies the calling convention that a function uses.
Definition Specifiers.h:278
@ CC_DeviceKernel
Definition Specifiers.h:292
LangAS getLangASFromTargetAS(unsigned TargetAS)
unsigned[(unsigned) LangAS::FirstTargetAddressSpace] LangASMap
The type of a lookup table which maps from language-specific address spaces to target-specific ones.
void setRequiresImmediate(int Min, int Max)