LLVM  14.0.0git
AMDGPUMetadata.h
Go to the documentation of this file.
1 //===--- AMDGPUMetadata.h ---------------------------------------*- 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 /// \file
10 /// AMDGPU metadata definitions and in-memory representations.
11 ///
12 //
13 //===----------------------------------------------------------------------===//
14 
15 #ifndef LLVM_SUPPORT_AMDGPUMETADATA_H
16 #define LLVM_SUPPORT_AMDGPUMETADATA_H
17 
18 #include "llvm/ADT/StringRef.h"
19 #include <cstdint>
20 #include <string>
21 #include <system_error>
22 #include <vector>
23 
24 namespace llvm {
25 namespace AMDGPU {
26 
27 //===----------------------------------------------------------------------===//
28 // HSA metadata.
29 //===----------------------------------------------------------------------===//
30 namespace HSAMD {
31 
32 /// HSA metadata major version for code object V2.
33 constexpr uint32_t VersionMajorV2 = 1;
34 /// HSA metadata minor version for code object V2.
35 constexpr uint32_t VersionMinorV2 = 0;
36 
37 /// HSA metadata major version for code object V3.
38 constexpr uint32_t VersionMajorV3 = 1;
39 /// HSA metadata minor version for code object V3.
40 constexpr uint32_t VersionMinorV3 = 0;
41 
42 /// HSA metadata major version for code object V4.
43 constexpr uint32_t VersionMajorV4 = 1;
44 /// HSA metadata minor version for code object V4.
45 constexpr uint32_t VersionMinorV4 = 1;
46 
47 /// HSA metadata beginning assembler directive.
48 constexpr char AssemblerDirectiveBegin[] = ".amd_amdgpu_hsa_metadata";
49 /// HSA metadata ending assembler directive.
50 constexpr char AssemblerDirectiveEnd[] = ".end_amd_amdgpu_hsa_metadata";
51 
52 /// Access qualifiers.
53 enum class AccessQualifier : uint8_t {
54  Default = 0,
55  ReadOnly = 1,
56  WriteOnly = 2,
57  ReadWrite = 3,
58  Unknown = 0xff
59 };
60 
61 /// Address space qualifiers.
62 enum class AddressSpaceQualifier : uint8_t {
63  Private = 0,
64  Global = 1,
65  Constant = 2,
66  Local = 3,
67  Generic = 4,
68  Region = 5,
69  Unknown = 0xff
70 };
71 
72 /// Value kinds.
73 enum class ValueKind : uint8_t {
74  ByValue = 0,
75  GlobalBuffer = 1,
77  Sampler = 3,
78  Image = 4,
79  Pipe = 5,
80  Queue = 6,
84  HiddenNone = 10,
85  HiddenPrintfBuffer = 11,
86  HiddenDefaultQueue = 12,
90  Unknown = 0xff
91 };
92 
93 /// Value types. This is deprecated and only remains for compatibility parsing
94 /// of old metadata.
95 enum class ValueType : uint8_t {
96  Struct = 0,
97  I8 = 1,
98  U8 = 2,
99  I16 = 3,
100  U16 = 4,
101  F16 = 5,
102  I32 = 6,
103  U32 = 7,
104  F32 = 8,
105  I64 = 9,
106  U64 = 10,
107  F64 = 11,
108  Unknown = 0xff
109 };
110 
111 //===----------------------------------------------------------------------===//
112 // Kernel Metadata.
113 //===----------------------------------------------------------------------===//
114 namespace Kernel {
115 
116 //===----------------------------------------------------------------------===//
117 // Kernel Attributes Metadata.
118 //===----------------------------------------------------------------------===//
119 namespace Attrs {
120 
121 namespace Key {
122 /// Key for Kernel::Attr::Metadata::mReqdWorkGroupSize.
123 constexpr char ReqdWorkGroupSize[] = "ReqdWorkGroupSize";
124 /// Key for Kernel::Attr::Metadata::mWorkGroupSizeHint.
125 constexpr char WorkGroupSizeHint[] = "WorkGroupSizeHint";
126 /// Key for Kernel::Attr::Metadata::mVecTypeHint.
127 constexpr char VecTypeHint[] = "VecTypeHint";
128 /// Key for Kernel::Attr::Metadata::mRuntimeHandle.
129 constexpr char RuntimeHandle[] = "RuntimeHandle";
130 } // end namespace Key
131 
132 /// In-memory representation of kernel attributes metadata.
133 struct Metadata final {
134  /// 'reqd_work_group_size' attribute. Optional.
135  std::vector<uint32_t> mReqdWorkGroupSize = std::vector<uint32_t>();
136  /// 'work_group_size_hint' attribute. Optional.
137  std::vector<uint32_t> mWorkGroupSizeHint = std::vector<uint32_t>();
138  /// 'vec_type_hint' attribute. Optional.
139  std::string mVecTypeHint = std::string();
140  /// External symbol created by runtime to store the kernel address
141  /// for enqueued blocks.
142  std::string mRuntimeHandle = std::string();
143 
144  /// Default constructor.
145  Metadata() = default;
146 
147  /// \returns True if kernel attributes metadata is empty, false otherwise.
148  bool empty() const {
149  return !notEmpty();
150  }
151 
152  /// \returns True if kernel attributes metadata is not empty, false otherwise.
153  bool notEmpty() const {
154  return !mReqdWorkGroupSize.empty() || !mWorkGroupSizeHint.empty() ||
155  !mVecTypeHint.empty() || !mRuntimeHandle.empty();
156  }
157 };
158 
159 } // end namespace Attrs
160 
161 //===----------------------------------------------------------------------===//
162 // Kernel Argument Metadata.
163 //===----------------------------------------------------------------------===//
164 namespace Arg {
165 
166 namespace Key {
167 /// Key for Kernel::Arg::Metadata::mName.
168 constexpr char Name[] = "Name";
169 /// Key for Kernel::Arg::Metadata::mTypeName.
170 constexpr char TypeName[] = "TypeName";
171 /// Key for Kernel::Arg::Metadata::mSize.
172 constexpr char Size[] = "Size";
173 /// Key for Kernel::Arg::Metadata::mOffset.
174 constexpr char Offset[] = "Offset";
175 /// Key for Kernel::Arg::Metadata::mAlign.
176 constexpr char Align[] = "Align";
177 /// Key for Kernel::Arg::Metadata::mValueKind.
178 constexpr char ValueKind[] = "ValueKind";
179 /// Key for Kernel::Arg::Metadata::mValueType. (deprecated)
180 constexpr char ValueType[] = "ValueType";
181 /// Key for Kernel::Arg::Metadata::mPointeeAlign.
182 constexpr char PointeeAlign[] = "PointeeAlign";
183 /// Key for Kernel::Arg::Metadata::mAddrSpaceQual.
184 constexpr char AddrSpaceQual[] = "AddrSpaceQual";
185 /// Key for Kernel::Arg::Metadata::mAccQual.
186 constexpr char AccQual[] = "AccQual";
187 /// Key for Kernel::Arg::Metadata::mActualAccQual.
188 constexpr char ActualAccQual[] = "ActualAccQual";
189 /// Key for Kernel::Arg::Metadata::mIsConst.
190 constexpr char IsConst[] = "IsConst";
191 /// Key for Kernel::Arg::Metadata::mIsRestrict.
192 constexpr char IsRestrict[] = "IsRestrict";
193 /// Key for Kernel::Arg::Metadata::mIsVolatile.
194 constexpr char IsVolatile[] = "IsVolatile";
195 /// Key for Kernel::Arg::Metadata::mIsPipe.
196 constexpr char IsPipe[] = "IsPipe";
197 } // end namespace Key
198 
199 /// In-memory representation of kernel argument metadata.
200 struct Metadata final {
201  /// Name. Optional.
202  std::string mName = std::string();
203  /// Type name. Optional.
204  std::string mTypeName = std::string();
205  /// Size in bytes. Required.
207  /// Offset in bytes. Required for code object v3, unused for code object v2.
209  /// Alignment in bytes. Required.
211  /// Value kind. Required.
213  /// Pointee alignment in bytes. Optional.
215  /// Address space qualifier. Optional.
217  /// Access qualifier. Optional.
219  /// Actual access qualifier. Optional.
221  /// True if 'const' qualifier is specified. Optional.
222  bool mIsConst = false;
223  /// True if 'restrict' qualifier is specified. Optional.
224  bool mIsRestrict = false;
225  /// True if 'volatile' qualifier is specified. Optional.
226  bool mIsVolatile = false;
227  /// True if 'pipe' qualifier is specified. Optional.
228  bool mIsPipe = false;
229 
230  /// Default constructor.
231  Metadata() = default;
232 };
233 
234 } // end namespace Arg
235 
236 //===----------------------------------------------------------------------===//
237 // Kernel Code Properties Metadata.
238 //===----------------------------------------------------------------------===//
239 namespace CodeProps {
240 
241 namespace Key {
242 /// Key for Kernel::CodeProps::Metadata::mKernargSegmentSize.
243 constexpr char KernargSegmentSize[] = "KernargSegmentSize";
244 /// Key for Kernel::CodeProps::Metadata::mGroupSegmentFixedSize.
245 constexpr char GroupSegmentFixedSize[] = "GroupSegmentFixedSize";
246 /// Key for Kernel::CodeProps::Metadata::mPrivateSegmentFixedSize.
247 constexpr char PrivateSegmentFixedSize[] = "PrivateSegmentFixedSize";
248 /// Key for Kernel::CodeProps::Metadata::mKernargSegmentAlign.
249 constexpr char KernargSegmentAlign[] = "KernargSegmentAlign";
250 /// Key for Kernel::CodeProps::Metadata::mWavefrontSize.
251 constexpr char WavefrontSize[] = "WavefrontSize";
252 /// Key for Kernel::CodeProps::Metadata::mNumSGPRs.
253 constexpr char NumSGPRs[] = "NumSGPRs";
254 /// Key for Kernel::CodeProps::Metadata::mNumVGPRs.
255 constexpr char NumVGPRs[] = "NumVGPRs";
256 /// Key for Kernel::CodeProps::Metadata::mMaxFlatWorkGroupSize.
257 constexpr char MaxFlatWorkGroupSize[] = "MaxFlatWorkGroupSize";
258 /// Key for Kernel::CodeProps::Metadata::mIsDynamicCallStack.
259 constexpr char IsDynamicCallStack[] = "IsDynamicCallStack";
260 /// Key for Kernel::CodeProps::Metadata::mIsXNACKEnabled.
261 constexpr char IsXNACKEnabled[] = "IsXNACKEnabled";
262 /// Key for Kernel::CodeProps::Metadata::mNumSpilledSGPRs.
263 constexpr char NumSpilledSGPRs[] = "NumSpilledSGPRs";
264 /// Key for Kernel::CodeProps::Metadata::mNumSpilledVGPRs.
265 constexpr char NumSpilledVGPRs[] = "NumSpilledVGPRs";
266 } // end namespace Key
267 
268 /// In-memory representation of kernel code properties metadata.
269 struct Metadata final {
270  /// Size in bytes of the kernarg segment memory. Kernarg segment memory
271  /// holds the values of the arguments to the kernel. Required.
272  uint64_t mKernargSegmentSize = 0;
273  /// Size in bytes of the group segment memory required by a workgroup.
274  /// This value does not include any dynamically allocated group segment memory
275  /// that may be added when the kernel is dispatched. Required.
277  /// Size in bytes of the private segment memory required by a workitem.
278  /// Private segment memory includes arg, spill and private segments. Required.
280  /// Maximum byte alignment of variables used by the kernel in the
281  /// kernarg memory segment. Required.
283  /// Wavefront size. Required.
285  /// Total number of SGPRs used by a wavefront. Optional.
287  /// Total number of VGPRs used by a workitem. Optional.
289  /// Maximum flat work-group size supported by the kernel. Optional.
291  /// True if the generated machine code is using a dynamically sized
292  /// call stack. Optional.
293  bool mIsDynamicCallStack = false;
294  /// True if the generated machine code is capable of supporting XNACK.
295  /// Optional.
296  bool mIsXNACKEnabled = false;
297  /// Number of SGPRs spilled by a wavefront. Optional.
299  /// Number of VGPRs spilled by a workitem. Optional.
301 
302  /// Default constructor.
303  Metadata() = default;
304 
305  /// \returns True if kernel code properties metadata is empty, false
306  /// otherwise.
307  bool empty() const {
308  return !notEmpty();
309  }
310 
311  /// \returns True if kernel code properties metadata is not empty, false
312  /// otherwise.
313  bool notEmpty() const {
314  return true;
315  }
316 };
317 
318 } // end namespace CodeProps
319 
320 //===----------------------------------------------------------------------===//
321 // Kernel Debug Properties Metadata.
322 //===----------------------------------------------------------------------===//
323 namespace DebugProps {
324 
325 namespace Key {
326 /// Key for Kernel::DebugProps::Metadata::mDebuggerABIVersion.
327 constexpr char DebuggerABIVersion[] = "DebuggerABIVersion";
328 /// Key for Kernel::DebugProps::Metadata::mReservedNumVGPRs.
329 constexpr char ReservedNumVGPRs[] = "ReservedNumVGPRs";
330 /// Key for Kernel::DebugProps::Metadata::mReservedFirstVGPR.
331 constexpr char ReservedFirstVGPR[] = "ReservedFirstVGPR";
332 /// Key for Kernel::DebugProps::Metadata::mPrivateSegmentBufferSGPR.
333 constexpr char PrivateSegmentBufferSGPR[] = "PrivateSegmentBufferSGPR";
334 /// Key for
335 /// Kernel::DebugProps::Metadata::mWavefrontPrivateSegmentOffsetSGPR.
337  "WavefrontPrivateSegmentOffsetSGPR";
338 } // end namespace Key
339 
340 /// In-memory representation of kernel debug properties metadata.
341 struct Metadata final {
342  /// Debugger ABI version. Optional.
343  std::vector<uint32_t> mDebuggerABIVersion = std::vector<uint32_t>();
344  /// Consecutive number of VGPRs reserved for debugger use. Must be 0 if
345  /// mDebuggerABIVersion is not set. Optional.
347  /// First fixed VGPR reserved. Must be uint16_t(-1) if
348  /// mDebuggerABIVersion is not set or mReservedFirstVGPR is 0. Optional.
350  /// Fixed SGPR of the first of 4 SGPRs used to hold the scratch V# used
351  /// for the entire kernel execution. Must be uint16_t(-1) if
352  /// mDebuggerABIVersion is not set or SGPR not used or not known. Optional.
354  /// Fixed SGPR used to hold the wave scratch offset for the entire
355  /// kernel execution. Must be uint16_t(-1) if mDebuggerABIVersion is not set
356  /// or SGPR is not used or not known. Optional.
358 
359  /// Default constructor.
360  Metadata() = default;
361 
362  /// \returns True if kernel debug properties metadata is empty, false
363  /// otherwise.
364  bool empty() const {
365  return !notEmpty();
366  }
367 
368  /// \returns True if kernel debug properties metadata is not empty, false
369  /// otherwise.
370  bool notEmpty() const {
371  return !mDebuggerABIVersion.empty();
372  }
373 };
374 
375 } // end namespace DebugProps
376 
377 namespace Key {
378 /// Key for Kernel::Metadata::mName.
379 constexpr char Name[] = "Name";
380 /// Key for Kernel::Metadata::mSymbolName.
381 constexpr char SymbolName[] = "SymbolName";
382 /// Key for Kernel::Metadata::mLanguage.
383 constexpr char Language[] = "Language";
384 /// Key for Kernel::Metadata::mLanguageVersion.
385 constexpr char LanguageVersion[] = "LanguageVersion";
386 /// Key for Kernel::Metadata::mAttrs.
387 constexpr char Attrs[] = "Attrs";
388 /// Key for Kernel::Metadata::mArgs.
389 constexpr char Args[] = "Args";
390 /// Key for Kernel::Metadata::mCodeProps.
391 constexpr char CodeProps[] = "CodeProps";
392 /// Key for Kernel::Metadata::mDebugProps.
393 constexpr char DebugProps[] = "DebugProps";
394 } // end namespace Key
395 
396 /// In-memory representation of kernel metadata.
397 struct Metadata final {
398  /// Kernel source name. Required.
399  std::string mName = std::string();
400  /// Kernel descriptor name. Required.
401  std::string mSymbolName = std::string();
402  /// Language. Optional.
403  std::string mLanguage = std::string();
404  /// Language version. Optional.
405  std::vector<uint32_t> mLanguageVersion = std::vector<uint32_t>();
406  /// Attributes metadata. Optional.
408  /// Arguments metadata. Optional.
409  std::vector<Arg::Metadata> mArgs = std::vector<Arg::Metadata>();
410  /// Code properties metadata. Optional.
412  /// Debug properties metadata. Optional.
414 
415  /// Default constructor.
416  Metadata() = default;
417 };
418 
419 } // end namespace Kernel
420 
421 namespace Key {
422 /// Key for HSA::Metadata::mVersion.
423 constexpr char Version[] = "Version";
424 /// Key for HSA::Metadata::mPrintf.
425 constexpr char Printf[] = "Printf";
426 /// Key for HSA::Metadata::mKernels.
427 constexpr char Kernels[] = "Kernels";
428 } // end namespace Key
429 
430 /// In-memory representation of HSA metadata.
431 struct Metadata final {
432  /// HSA metadata version. Required.
433  std::vector<uint32_t> mVersion = std::vector<uint32_t>();
434  /// Printf metadata. Optional.
435  std::vector<std::string> mPrintf = std::vector<std::string>();
436  /// Kernels metadata. Required.
437  std::vector<Kernel::Metadata> mKernels = std::vector<Kernel::Metadata>();
438 
439  /// Default constructor.
440  Metadata() = default;
441 };
442 
443 /// Converts \p String to \p HSAMetadata.
444 std::error_code fromString(StringRef String, Metadata &HSAMetadata);
445 
446 /// Converts \p HSAMetadata to \p String.
447 std::error_code toString(Metadata HSAMetadata, std::string &String);
448 
449 //===----------------------------------------------------------------------===//
450 // HSA metadata for v3 code object.
451 //===----------------------------------------------------------------------===//
452 namespace V3 {
453 /// HSA metadata major version.
454 constexpr uint32_t VersionMajor = 1;
455 /// HSA metadata minor version.
456 constexpr uint32_t VersionMinor = 0;
457 
458 /// HSA metadata beginning assembler directive.
459 constexpr char AssemblerDirectiveBegin[] = ".amdgpu_metadata";
460 /// HSA metadata ending assembler directive.
461 constexpr char AssemblerDirectiveEnd[] = ".end_amdgpu_metadata";
462 } // end namespace V3
463 
464 } // end namespace HSAMD
465 
466 //===----------------------------------------------------------------------===//
467 // PAL metadata.
468 //===----------------------------------------------------------------------===//
469 namespace PALMD {
470 
471 /// PAL metadata (old linear format) assembler directive.
472 constexpr char AssemblerDirective[] = ".amd_amdgpu_pal_metadata";
473 
474 /// PAL metadata (new MsgPack format) beginning assembler directive.
475 constexpr char AssemblerDirectiveBegin[] = ".amdgpu_pal_metadata";
476 
477 /// PAL metadata (new MsgPack format) ending assembler directive.
478 constexpr char AssemblerDirectiveEnd[] = ".end_amdgpu_pal_metadata";
479 
480 /// PAL metadata keys.
481 enum Key : uint32_t {
494 
495  LS_NUM_USED_VGPRS = 0x10000021,
496  HS_NUM_USED_VGPRS = 0x10000022,
497  ES_NUM_USED_VGPRS = 0x10000023,
498  GS_NUM_USED_VGPRS = 0x10000024,
499  VS_NUM_USED_VGPRS = 0x10000025,
500  PS_NUM_USED_VGPRS = 0x10000026,
501  CS_NUM_USED_VGPRS = 0x10000027,
502 
503  LS_NUM_USED_SGPRS = 0x10000028,
504  HS_NUM_USED_SGPRS = 0x10000029,
505  ES_NUM_USED_SGPRS = 0x1000002a,
506  GS_NUM_USED_SGPRS = 0x1000002b,
507  VS_NUM_USED_SGPRS = 0x1000002c,
508  PS_NUM_USED_SGPRS = 0x1000002d,
509  CS_NUM_USED_SGPRS = 0x1000002e,
510 
511  LS_SCRATCH_SIZE = 0x10000044,
512  HS_SCRATCH_SIZE = 0x10000045,
513  ES_SCRATCH_SIZE = 0x10000046,
514  GS_SCRATCH_SIZE = 0x10000047,
515  VS_SCRATCH_SIZE = 0x10000048,
516  PS_SCRATCH_SIZE = 0x10000049,
517  CS_SCRATCH_SIZE = 0x1000004a
518 };
519 
520 } // end namespace PALMD
521 } // end namespace AMDGPU
522 } // end namespace llvm
523 
524 #endif // LLVM_SUPPORT_AMDGPUMETADATA_H
llvm::AMDGPU::PALMD::GS_NUM_USED_VGPRS
@ GS_NUM_USED_VGPRS
Definition: AMDGPUMetadata.h:498
llvm::AMDGPU::HSAMD::Kernel::Arg::Metadata::mAccQual
AccessQualifier mAccQual
Access qualifier. Optional.
Definition: AMDGPUMetadata.h:218
llvm::AMDGPU::HSAMD::Kernel::DebugProps::Metadata::mPrivateSegmentBufferSGPR
uint16_t mPrivateSegmentBufferSGPR
Fixed SGPR of the first of 4 SGPRs used to hold the scratch V# used for the entire kernel execution.
Definition: AMDGPUMetadata.h:353
llvm::AMDGPU::HSAMD::Metadata::Metadata
Metadata()=default
Default constructor.
Attrs
Function Attrs
Definition: README_ALTIVEC.txt:215
llvm::AMDGPU::HSAMD::Kernel::DebugProps::Metadata::notEmpty
bool notEmpty() const
Definition: AMDGPUMetadata.h:370
llvm::AMDGPU::HSAMD::Kernel::DebugProps::Metadata
In-memory representation of kernel debug properties metadata.
Definition: AMDGPUMetadata.h:341
llvm
---------------------— PointerInfo ------------------------------------—
Definition: AllocatorList.h:23
llvm::AMDGPU::PALMD::R_A2D5_VGT_SHADER_STAGES_EN
@ R_A2D5_VGT_SHADER_STAGES_EN
Definition: AMDGPUMetadata.h:493
llvm::AMDGPU::HSAMD::ValueType::U16
@ U16
llvm::AMDGPU::PALMD::GS_NUM_USED_SGPRS
@ GS_NUM_USED_SGPRS
Definition: AMDGPUMetadata.h:506
llvm::AMDGPU::HSAMD::AccessQualifier::Unknown
@ Unknown
llvm::AMDGPU::HSAMD::Kernel::CodeProps::Metadata::empty
bool empty() const
Definition: AMDGPUMetadata.h:307
llvm::AMDGPU::HSAMD::Kernel::Metadata::mArgs
std::vector< Arg::Metadata > mArgs
Arguments metadata. Optional.
Definition: AMDGPUMetadata.h:409
llvm::AMDGPU::HSAMD::Kernel::CodeProps::Key::NumSGPRs
constexpr char NumSGPRs[]
Key for Kernel::CodeProps::Metadata::mNumSGPRs.
Definition: AMDGPUMetadata.h:253
llvm::AMDGPU::HSAMD::Kernel::DebugProps::Metadata::mReservedFirstVGPR
uint16_t mReservedFirstVGPR
First fixed VGPR reserved.
Definition: AMDGPUMetadata.h:349
llvm::AMDGPU::HSAMD::Kernel::CodeProps::Key::KernargSegmentSize
constexpr char KernargSegmentSize[]
Key for Kernel::CodeProps::Metadata::mKernargSegmentSize.
Definition: AMDGPUMetadata.h:243
llvm::AMDGPU::HSAMD::Metadata::mVersion
std::vector< uint32_t > mVersion
HSA metadata version. Required.
Definition: AMDGPUMetadata.h:433
llvm::AMDGPU::HSAMD::Kernel::Key::Attrs
constexpr char Attrs[]
Key for Kernel::Metadata::mAttrs.
Definition: AMDGPUMetadata.h:387
StringRef.h
llvm::AMDGPU::HSAMD::ValueKind::ByValue
@ ByValue
llvm::AMDGPU::HSAMD::Kernel::Arg::Metadata::mIsConst
bool mIsConst
True if 'const' qualifier is specified. Optional.
Definition: AMDGPUMetadata.h:222
llvm::AMDGPU::PALMD::R_2D4A_SPI_SHADER_PGM_RSRC1_LS
@ R_2D4A_SPI_SHADER_PGM_RSRC1_LS
Definition: AMDGPUMetadata.h:483
llvm::AMDGPU::PALMD::R_A1B4_SPI_PS_INPUT_ADDR
@ R_A1B4_SPI_PS_INPUT_ADDR
Definition: AMDGPUMetadata.h:491
llvm::AMDGPU::HSAMD::Kernel::Arg::Metadata::mValueKind
ValueKind mValueKind
Value kind. Required.
Definition: AMDGPUMetadata.h:212
llvm::AMDGPU::HSAMD::Kernel::Arg::Key::AddrSpaceQual
constexpr char AddrSpaceQual[]
Key for Kernel::Arg::Metadata::mAddrSpaceQual.
Definition: AMDGPUMetadata.h:184
llvm::AMDGPU::PALMD::R_2E12_COMPUTE_PGM_RSRC1
@ R_2E12_COMPUTE_PGM_RSRC1
Definition: AMDGPUMetadata.h:482
llvm::AMDGPU::HSAMD::ValueType::I8
@ I8
llvm::AMDGPU::HSAMD::Kernel::Arg::Key::Offset
constexpr char Offset[]
Key for Kernel::Arg::Metadata::mOffset.
Definition: AMDGPUMetadata.h:174
llvm::AMDGPU::HSAMD::ValueType::U32
@ U32
llvm::AMDGPU::HSAMD::VersionMajorV4
constexpr uint32_t VersionMajorV4
HSA metadata major version for code object V4.
Definition: AMDGPUMetadata.h:43
llvm::AMDGPU::HSAMD::Key::Version
constexpr char Version[]
Key for HSA::Metadata::mVersion.
Definition: AMDGPUMetadata.h:423
llvm::AMDGPU::PALMD::VS_SCRATCH_SIZE
@ VS_SCRATCH_SIZE
Definition: AMDGPUMetadata.h:515
llvm::AMDGPU::PALMD::ES_NUM_USED_SGPRS
@ ES_NUM_USED_SGPRS
Definition: AMDGPUMetadata.h:505
llvm::AMDGPU::HSAMD::Kernel::CodeProps::Metadata::mPrivateSegmentFixedSize
uint32_t mPrivateSegmentFixedSize
Size in bytes of the private segment memory required by a workitem.
Definition: AMDGPUMetadata.h:279
llvm::AMDGPU::PALMD::VS_NUM_USED_VGPRS
@ VS_NUM_USED_VGPRS
Definition: AMDGPUMetadata.h:499
llvm::AMDGPU::HSAMD::Kernel::Key::Name
constexpr char Name[]
Key for Kernel::Metadata::mName.
Definition: AMDGPUMetadata.h:379
llvm::AMDGPU::HSAMD::Kernel::Arg::Key::IsPipe
constexpr char IsPipe[]
Key for Kernel::Arg::Metadata::mIsPipe.
Definition: AMDGPUMetadata.h:196
llvm::AMDGPU::PALMD::R_A1B3_SPI_PS_INPUT_ENA
@ R_A1B3_SPI_PS_INPUT_ENA
Definition: AMDGPUMetadata.h:490
llvm::AMDGPU::HSAMD::Kernel::Arg::Metadata
In-memory representation of kernel argument metadata.
Definition: AMDGPUMetadata.h:200
llvm::AMDGPU::PALMD::AssemblerDirective
constexpr char AssemblerDirective[]
PAL metadata (old linear format) assembler directive.
Definition: AMDGPUMetadata.h:472
llvm::AMDGPU::HSAMD::Kernel::Arg::Metadata::mActualAccQual
AccessQualifier mActualAccQual
Actual access qualifier. Optional.
Definition: AMDGPUMetadata.h:220
llvm::AMDGPU::PALMD::CS_NUM_USED_SGPRS
@ CS_NUM_USED_SGPRS
Definition: AMDGPUMetadata.h:509
llvm::AMDGPU::HSAMD::Kernel::Attrs::Key::ReqdWorkGroupSize
constexpr char ReqdWorkGroupSize[]
Key for Kernel::Attr::Metadata::mReqdWorkGroupSize.
Definition: AMDGPUMetadata.h:123
llvm::AMDGPU::HSAMD::Kernel::CodeProps::Metadata::mWavefrontSize
uint32_t mWavefrontSize
Wavefront size. Required.
Definition: AMDGPUMetadata.h:284
llvm::AMDGPU::HSAMD::Kernel::DebugProps::Key::WavefrontPrivateSegmentOffsetSGPR
constexpr char WavefrontPrivateSegmentOffsetSGPR[]
Key for Kernel::DebugProps::Metadata::mWavefrontPrivateSegmentOffsetSGPR.
Definition: AMDGPUMetadata.h:336
llvm::AMDGPU::PALMD::AssemblerDirectiveBegin
constexpr char AssemblerDirectiveBegin[]
PAL metadata (new MsgPack format) beginning assembler directive.
Definition: AMDGPUMetadata.h:475
llvm::AMDGPU::HSAMD::ValueKind::Queue
@ Queue
llvm::AMDGPU::HSAMD::Kernel::CodeProps::Key::MaxFlatWorkGroupSize
constexpr char MaxFlatWorkGroupSize[]
Key for Kernel::CodeProps::Metadata::mMaxFlatWorkGroupSize.
Definition: AMDGPUMetadata.h:257
llvm::AMDGPU::PALMD::ES_NUM_USED_VGPRS
@ ES_NUM_USED_VGPRS
Definition: AMDGPUMetadata.h:497
llvm::AMDGPU::HSAMD::V3::VersionMajor
constexpr uint32_t VersionMajor
HSA metadata major version.
Definition: AMDGPUMetadata.h:454
llvm::AMDGPU::HSAMD::VersionMajorV2
constexpr uint32_t VersionMajorV2
HSA metadata major version for code object V2.
Definition: AMDGPUMetadata.h:33
llvm::AMDGPU::HSAMD::AccessQualifier
AccessQualifier
Access qualifiers.
Definition: AMDGPUMetadata.h:53
llvm::AMDGPU::HSAMD::Kernel::Key::DebugProps
constexpr char DebugProps[]
Key for Kernel::Metadata::mDebugProps.
Definition: AMDGPUMetadata.h:393
Arg
amdgpu Simplify well known AMD library false FunctionCallee Value * Arg
Definition: AMDGPULibCalls.cpp:206
llvm::AMDGPU::HSAMD::fromString
std::error_code fromString(StringRef String, Metadata &HSAMetadata)
Converts String to HSAMetadata.
Definition: AMDGPUMetadata.cpp:213
llvm::AMDGPU::HSAMD::Key::Kernels
constexpr char Kernels[]
Key for HSA::Metadata::mKernels.
Definition: AMDGPUMetadata.h:427
llvm::AMDGPU::HSAMD::ValueKind
ValueKind
Value kinds.
Definition: AMDGPUMetadata.h:73
llvm::AMDGPU::PALMD::VS_NUM_USED_SGPRS
@ VS_NUM_USED_SGPRS
Definition: AMDGPUMetadata.h:507
llvm::AMDGPU::HSAMD::Kernel::Attrs::Key::WorkGroupSizeHint
constexpr char WorkGroupSizeHint[]
Key for Kernel::Attr::Metadata::mWorkGroupSizeHint.
Definition: AMDGPUMetadata.h:125
llvm::AMDGPU::HSAMD::ValueType::F64
@ F64
llvm::AMDGPU::HSAMD::Kernel::CodeProps::Metadata::mIsXNACKEnabled
bool mIsXNACKEnabled
True if the generated machine code is capable of supporting XNACK.
Definition: AMDGPUMetadata.h:296
llvm::AMDGPU::HSAMD::Kernel::Attrs::Key::VecTypeHint
constexpr char VecTypeHint[]
Key for Kernel::Attr::Metadata::mVecTypeHint.
Definition: AMDGPUMetadata.h:127
llvm::AMDGPU::HSAMD::Kernel::CodeProps::Metadata::mNumSGPRs
uint16_t mNumSGPRs
Total number of SGPRs used by a wavefront. Optional.
Definition: AMDGPUMetadata.h:286
llvm::AMDGPU::HSAMD::ValueType::I32
@ I32
llvm::AMDGPU::HSAMD::ValueKind::HiddenCompletionAction
@ HiddenCompletionAction
llvm::AMDGPU::HSAMD::Kernel::CodeProps::Key::NumSpilledVGPRs
constexpr char NumSpilledVGPRs[]
Key for Kernel::CodeProps::Metadata::mNumSpilledVGPRs.
Definition: AMDGPUMetadata.h:265
llvm::AMDGPU::HSAMD::ValueType::U64
@ U64
llvm::AMDGPU::HSAMD::Kernel::Key::Language
constexpr char Language[]
Key for Kernel::Metadata::mLanguage.
Definition: AMDGPUMetadata.h:383
llvm::AMDGPU::PALMD::R_2C8A_SPI_SHADER_PGM_RSRC1_GS
@ R_2C8A_SPI_SHADER_PGM_RSRC1_GS
Definition: AMDGPUMetadata.h:486
llvm::AMDGPU::HSAMD::VersionMinorV2
constexpr uint32_t VersionMinorV2
HSA metadata minor version for code object V2.
Definition: AMDGPUMetadata.h:35
llvm::AMDGPU::HSAMD::Kernel::CodeProps::Key::PrivateSegmentFixedSize
constexpr char PrivateSegmentFixedSize[]
Key for Kernel::CodeProps::Metadata::mPrivateSegmentFixedSize.
Definition: AMDGPUMetadata.h:247
llvm::AMDGPU::HSAMD::Kernel::Metadata::mLanguage
std::string mLanguage
Language. Optional.
Definition: AMDGPUMetadata.h:403
llvm::AMDGPU::HSAMD::Kernel::Arg::Key::AccQual
constexpr char AccQual[]
Key for Kernel::Arg::Metadata::mAccQual.
Definition: AMDGPUMetadata.h:186
llvm::AMDGPU::HSAMD::Kernel::Key::CodeProps
constexpr char CodeProps[]
Key for Kernel::Metadata::mCodeProps.
Definition: AMDGPUMetadata.h:391
llvm::AMDGPU::HSAMD::Kernel::Arg::Metadata::mTypeName
std::string mTypeName
Type name. Optional.
Definition: AMDGPUMetadata.h:204
llvm::AMDGPU::HSAMD::ValueKind::HiddenGlobalOffsetY
@ HiddenGlobalOffsetY
llvm::AMDGPU::PALMD::PS_NUM_USED_SGPRS
@ PS_NUM_USED_SGPRS
Definition: AMDGPUMetadata.h:508
llvm::AMDGPU::HSAMD::Kernel::Attrs::Metadata::notEmpty
bool notEmpty() const
Definition: AMDGPUMetadata.h:153
llvm::AMDGPU::PALMD::Key
Key
PAL metadata keys.
Definition: AMDGPUMetadata.h:481
llvm::AMDGPU::PALMD::GS_SCRATCH_SIZE
@ GS_SCRATCH_SIZE
Definition: AMDGPUMetadata.h:514
llvm::AMDGPU::HSAMD::Kernel::Arg::Metadata::mIsPipe
bool mIsPipe
True if 'pipe' qualifier is specified. Optional.
Definition: AMDGPUMetadata.h:228
llvm::AMDGPU::HSAMD::ValueKind::HiddenGlobalOffsetZ
@ HiddenGlobalOffsetZ
llvm::AMDGPU::HSAMD::Metadata
In-memory representation of HSA metadata.
Definition: AMDGPUMetadata.h:431
llvm::AMDGPU::HSAMD::Kernel::Arg::Metadata::mSize
uint32_t mSize
Size in bytes. Required.
Definition: AMDGPUMetadata.h:206
llvm::AMDGPU::HSAMD::ValueKind::GlobalBuffer
@ GlobalBuffer
llvm::AMDGPU::HSAMD::ValueType::I64
@ I64
llvm::Align
This struct is a compact representation of a valid (non-zero power of two) alignment.
Definition: Alignment.h:39
llvm::AMDGPU::HSAMD::Kernel::Arg::Key::Name
constexpr char Name[]
Key for Kernel::Arg::Metadata::mName.
Definition: AMDGPUMetadata.h:168
llvm::AMDGPU::HSAMD::Kernel::Arg::Metadata::mIsVolatile
bool mIsVolatile
True if 'volatile' qualifier is specified. Optional.
Definition: AMDGPUMetadata.h:226
llvm::AMDGPU::HSAMD::Kernel::DebugProps::Metadata::Metadata
Metadata()=default
Default constructor.
llvm::AMDGPU::HSAMD::AddressSpaceQualifier::Global
@ Global
llvm::AMDGPU::HSAMD::Kernel::CodeProps::Metadata::mKernargSegmentAlign
uint32_t mKernargSegmentAlign
Maximum byte alignment of variables used by the kernel in the kernarg memory segment.
Definition: AMDGPUMetadata.h:282
llvm::AMDGPU::HSAMD::AccessQualifier::WriteOnly
@ WriteOnly
llvm::AMDGPU::HSAMD::ValueType::F16
@ F16
llvm::AMDGPU::HSAMD::Kernel::Attrs::Metadata::empty
bool empty() const
Definition: AMDGPUMetadata.h:148
llvm::AMDGPU::HSAMD::ValueKind::Image
@ Image
llvm::AMDGPU::PALMD::CS_NUM_USED_VGPRS
@ CS_NUM_USED_VGPRS
Definition: AMDGPUMetadata.h:501
llvm::Constant
This is an important base class in LLVM.
Definition: Constant.h:41
llvm::AMDGPU::HSAMD::Kernel::Attrs::Metadata::mVecTypeHint
std::string mVecTypeHint
'vec_type_hint' attribute. Optional.
Definition: AMDGPUMetadata.h:139
llvm::AMDGPU::HSAMD::ValueKind::Unknown
@ Unknown
llvm::AMDGPU::HSAMD::V3::VersionMinor
constexpr uint32_t VersionMinor
HSA metadata minor version.
Definition: AMDGPUMetadata.h:456
llvm::AMDGPU::HSAMD::Metadata::mPrintf
std::vector< std::string > mPrintf
Printf metadata. Optional.
Definition: AMDGPUMetadata.h:435
llvm::AMDGPU::HSAMD::Kernel::CodeProps::Metadata::mNumSpilledSGPRs
uint16_t mNumSpilledSGPRs
Number of SGPRs spilled by a wavefront. Optional.
Definition: AMDGPUMetadata.h:298
llvm::AMDGPU::HSAMD::AddressSpaceQualifier::Local
@ Local
llvm::AMDGPU::HSAMD::Kernel::Metadata::mAttrs
Attrs::Metadata mAttrs
Attributes metadata. Optional.
Definition: AMDGPUMetadata.h:407
llvm::AMDGPU::HSAMD::AccessQualifier::ReadOnly
@ ReadOnly
llvm::AMDGPU::HSAMD::AccessQualifier::ReadWrite
@ ReadWrite
llvm::omp::Kernel
Function * Kernel
Summary of a kernel (=entry point for target offloading).
Definition: OpenMPOpt.h:21
llvm::AMDGPU::HSAMD::Kernel::DebugProps::Key::ReservedFirstVGPR
constexpr char ReservedFirstVGPR[]
Key for Kernel::DebugProps::Metadata::mReservedFirstVGPR.
Definition: AMDGPUMetadata.h:331
llvm::AMDGPU::HSAMD::ValueType::F32
@ F32
llvm::AMDGPU::HSAMD::Kernel::Metadata
In-memory representation of kernel metadata.
Definition: AMDGPUMetadata.h:397
llvm::AMDGPU::HSAMD::ValueKind::HiddenDefaultQueue
@ HiddenDefaultQueue
llvm::AMDGPU::PALMD::ES_SCRATCH_SIZE
@ ES_SCRATCH_SIZE
Definition: AMDGPUMetadata.h:513
llvm::AMDGPU::HSAMD::Kernel::DebugProps::Key::DebuggerABIVersion
constexpr char DebuggerABIVersion[]
Key for Kernel::DebugProps::Metadata::mDebuggerABIVersion.
Definition: AMDGPUMetadata.h:327
llvm::AMDGPU::HSAMD::Kernel::Metadata::mLanguageVersion
std::vector< uint32_t > mLanguageVersion
Language version. Optional.
Definition: AMDGPUMetadata.h:405
llvm::AMDGPU::HSAMD::Kernel::DebugProps::Metadata::mReservedNumVGPRs
uint16_t mReservedNumVGPRs
Consecutive number of VGPRs reserved for debugger use.
Definition: AMDGPUMetadata.h:346
llvm::AMDGPU::HSAMD::Kernel::Arg::Metadata::mAlign
uint32_t mAlign
Alignment in bytes. Required.
Definition: AMDGPUMetadata.h:210
llvm::AMDGPU::HSAMD::Kernel::CodeProps::Key::GroupSegmentFixedSize
constexpr char GroupSegmentFixedSize[]
Key for Kernel::CodeProps::Metadata::mGroupSegmentFixedSize.
Definition: AMDGPUMetadata.h:245
llvm::AMDGPU::HSAMD::Kernel::CodeProps::Key::KernargSegmentAlign
constexpr char KernargSegmentAlign[]
Key for Kernel::CodeProps::Metadata::mKernargSegmentAlign.
Definition: AMDGPUMetadata.h:249
llvm::AMDGPU::HSAMD::ValueKind::HiddenNone
@ HiddenNone
llvm::AMDGPU::HSAMD::Kernel::Attrs::Metadata::Metadata
Metadata()=default
Default constructor.
llvm::AMDGPU::HSAMD::Kernel::Arg::Key::PointeeAlign
constexpr char PointeeAlign[]
Key for Kernel::Arg::Metadata::mPointeeAlign.
Definition: AMDGPUMetadata.h:182
llvm::AMDGPU::HSAMD::AddressSpaceQualifier::Generic
@ Generic
llvm::AMDGPU::HSAMD::ValueKind::Pipe
@ Pipe
llvm::AMDGPU::HSAMD::Kernel::Metadata::Metadata
Metadata()=default
Default constructor.
llvm::AMDGPU::HSAMD::ValueType
ValueType
Value types.
Definition: AMDGPUMetadata.h:95
llvm::AMDGPU::HSAMD::ValueType::I16
@ I16
llvm::AMDGPU::PALMD::R_2E00_COMPUTE_DISPATCH_INITIATOR
@ R_2E00_COMPUTE_DISPATCH_INITIATOR
Definition: AMDGPUMetadata.h:489
llvm::AMDGPU::HSAMD::Kernel::Metadata::mCodeProps
CodeProps::Metadata mCodeProps
Code properties metadata. Optional.
Definition: AMDGPUMetadata.h:411
llvm::AMDGPU::HSAMD::AddressSpaceQualifier::Unknown
@ Unknown
llvm::AMDGPU::HSAMD::Kernel::CodeProps::Metadata
In-memory representation of kernel code properties metadata.
Definition: AMDGPUMetadata.h:269
llvm::AMDGPU::HSAMD::ValueKind::HiddenPrintfBuffer
@ HiddenPrintfBuffer
llvm::AMDGPU::HSAMD::Kernel::DebugProps::Key::ReservedNumVGPRs
constexpr char ReservedNumVGPRs[]
Key for Kernel::DebugProps::Metadata::mReservedNumVGPRs.
Definition: AMDGPUMetadata.h:329
llvm::AMDGPU::HSAMD::Kernel::Arg::Metadata::mPointeeAlign
uint32_t mPointeeAlign
Pointee alignment in bytes. Optional.
Definition: AMDGPUMetadata.h:214
llvm::AMDGPU::HSAMD::VersionMajorV3
constexpr uint32_t VersionMajorV3
HSA metadata major version for code object V3.
Definition: AMDGPUMetadata.h:38
llvm::AMDGPU::PALMD::R_2C4A_SPI_SHADER_PGM_RSRC1_VS
@ R_2C4A_SPI_SHADER_PGM_RSRC1_VS
Definition: AMDGPUMetadata.h:487
llvm::AMDGPU::HSAMD::Kernel::DebugProps::Metadata::mWavefrontPrivateSegmentOffsetSGPR
uint16_t mWavefrontPrivateSegmentOffsetSGPR
Fixed SGPR used to hold the wave scratch offset for the entire kernel execution.
Definition: AMDGPUMetadata.h:357
llvm::AMDGPU::PALMD::HS_NUM_USED_VGPRS
@ HS_NUM_USED_VGPRS
Definition: AMDGPUMetadata.h:496
llvm::AMDGPU::HSAMD::Kernel::Arg::Key::IsConst
constexpr char IsConst[]
Key for Kernel::Arg::Metadata::mIsConst.
Definition: AMDGPUMetadata.h:190
llvm::AMDGPU::HSAMD::Kernel::Metadata::mName
std::string mName
Kernel source name. Required.
Definition: AMDGPUMetadata.h:399
llvm::StringRef
StringRef - Represent a constant reference to a string, i.e.
Definition: StringRef.h:58
llvm::AMDGPU::PALMD::HS_SCRATCH_SIZE
@ HS_SCRATCH_SIZE
Definition: AMDGPUMetadata.h:512
llvm::AMDGPU::HSAMD::Kernel::Metadata::mDebugProps
DebugProps::Metadata mDebugProps
Debug properties metadata. Optional.
Definition: AMDGPUMetadata.h:413
llvm::AMDGPU::HSAMD::Kernel::CodeProps::Metadata::Metadata
Metadata()=default
Default constructor.
llvm::AMDGPU::HSAMD::ValueKind::Sampler
@ Sampler
uint32_t
llvm::AMDGPU::HSAMD::Kernel::Arg::Metadata::Metadata
Metadata()=default
Default constructor.
llvm::AMDGPU::HSAMD::Kernel::Key::LanguageVersion
constexpr char LanguageVersion[]
Key for Kernel::Metadata::mLanguageVersion.
Definition: AMDGPUMetadata.h:385
llvm::AMDGPU::HSAMD::ValueType::U8
@ U8
llvm::AMDGPU::HSAMD::Metadata::mKernels
std::vector< Kernel::Metadata > mKernels
Kernels metadata. Required.
Definition: AMDGPUMetadata.h:437
llvm::AMDGPU::HSAMD::AssemblerDirectiveBegin
constexpr char AssemblerDirectiveBegin[]
HSA metadata beginning assembler directive.
Definition: AMDGPUMetadata.h:48
llvm::AMDGPU::HSAMD::Kernel::Metadata::mSymbolName
std::string mSymbolName
Kernel descriptor name. Required.
Definition: AMDGPUMetadata.h:401
llvm::AMDGPU::HSAMD::Kernel::CodeProps::Metadata::mNumSpilledVGPRs
uint16_t mNumSpilledVGPRs
Number of VGPRs spilled by a workitem. Optional.
Definition: AMDGPUMetadata.h:300
llvm::AMDGPU::HSAMD::Kernel::Attrs::Metadata
In-memory representation of kernel attributes metadata.
Definition: AMDGPUMetadata.h:133
llvm::AMDGPU::HSAMD::Kernel::Arg::Key::IsRestrict
constexpr char IsRestrict[]
Key for Kernel::Arg::Metadata::mIsRestrict.
Definition: AMDGPUMetadata.h:192
llvm::AMDGPU::HSAMD::Kernel::Arg::Key::IsVolatile
constexpr char IsVolatile[]
Key for Kernel::Arg::Metadata::mIsVolatile.
Definition: AMDGPUMetadata.h:194
llvm::AMDGPU::HSAMD::ValueKind::HiddenMultiGridSyncArg
@ HiddenMultiGridSyncArg
llvm::AMDGPU::HSAMD::AddressSpaceQualifier
AddressSpaceQualifier
Address space qualifiers.
Definition: AMDGPUMetadata.h:62
llvm::AMDGPU::PALMD::LS_NUM_USED_VGPRS
@ LS_NUM_USED_VGPRS
Definition: AMDGPUMetadata.h:495
llvm::AMDGPU::PALMD::PS_SCRATCH_SIZE
@ PS_SCRATCH_SIZE
Definition: AMDGPUMetadata.h:516
llvm::AMDGPU::HSAMD::Kernel::CodeProps::Metadata::mMaxFlatWorkGroupSize
uint32_t mMaxFlatWorkGroupSize
Maximum flat work-group size supported by the kernel. Optional.
Definition: AMDGPUMetadata.h:290
llvm::AMDGPU::HSAMD::ValueKind::DynamicSharedPointer
@ DynamicSharedPointer
llvm::AMDGPU::HSAMD::ValueKind::HiddenHostcallBuffer
@ HiddenHostcallBuffer
llvm::AMDGPU::HSAMD::Kernel::CodeProps::Metadata::mIsDynamicCallStack
bool mIsDynamicCallStack
True if the generated machine code is using a dynamically sized call stack.
Definition: AMDGPUMetadata.h:293
llvm::AMDGPU::HSAMD::Kernel::Key::SymbolName
constexpr char SymbolName[]
Key for Kernel::Metadata::mSymbolName.
Definition: AMDGPUMetadata.h:381
llvm::AMDGPU::PALMD::PS_NUM_USED_VGPRS
@ PS_NUM_USED_VGPRS
Definition: AMDGPUMetadata.h:500
llvm::AMDGPU::HSAMD::Kernel::DebugProps::Metadata::mDebuggerABIVersion
std::vector< uint32_t > mDebuggerABIVersion
Debugger ABI version. Optional.
Definition: AMDGPUMetadata.h:343
llvm::AMDGPU::HSAMD::AssemblerDirectiveEnd
constexpr char AssemblerDirectiveEnd[]
HSA metadata ending assembler directive.
Definition: AMDGPUMetadata.h:50
llvm::AMDGPU::PALMD::R_2C0A_SPI_SHADER_PGM_RSRC1_PS
@ R_2C0A_SPI_SHADER_PGM_RSRC1_PS
Definition: AMDGPUMetadata.h:488
uint16_t
llvm::AMDGPU::HSAMD::Kernel::Arg::Key::TypeName
constexpr char TypeName[]
Key for Kernel::Arg::Metadata::mTypeName.
Definition: AMDGPUMetadata.h:170
llvm::AMDGPU::PALMD::LS_SCRATCH_SIZE
@ LS_SCRATCH_SIZE
Definition: AMDGPUMetadata.h:511
llvm::AMDGPU::PALMD::HS_NUM_USED_SGPRS
@ HS_NUM_USED_SGPRS
Definition: AMDGPUMetadata.h:504
llvm::AMDGPU::HSAMD::Kernel::Arg::Metadata::mOffset
uint32_t mOffset
Offset in bytes. Required for code object v3, unused for code object v2.
Definition: AMDGPUMetadata.h:208
llvm::AMDGPU::PALMD::R_A1B6_SPI_PS_IN_CONTROL
@ R_A1B6_SPI_PS_IN_CONTROL
Definition: AMDGPUMetadata.h:492
llvm::AMDGPU::PALMD::R_2CCA_SPI_SHADER_PGM_RSRC1_ES
@ R_2CCA_SPI_SHADER_PGM_RSRC1_ES
Definition: AMDGPUMetadata.h:485
llvm::AMDGPU::PALMD::LS_NUM_USED_SGPRS
@ LS_NUM_USED_SGPRS
Definition: AMDGPUMetadata.h:503
llvm::AMDGPU::PALMD::CS_SCRATCH_SIZE
@ CS_SCRATCH_SIZE
Definition: AMDGPUMetadata.h:517
llvm::AMDGPU::PALMD::AssemblerDirectiveEnd
constexpr char AssemblerDirectiveEnd[]
PAL metadata (new MsgPack format) ending assembler directive.
Definition: AMDGPUMetadata.h:478
llvm::AMDGPU::HSAMD::ValueType::Struct
@ Struct
llvm::AMDGPU::HSAMD::Kernel::CodeProps::Metadata::mKernargSegmentSize
uint64_t mKernargSegmentSize
Size in bytes of the kernarg segment memory.
Definition: AMDGPUMetadata.h:272
llvm::AMDGPU::HSAMD::Kernel::Attrs::Key::RuntimeHandle
constexpr char RuntimeHandle[]
Key for Kernel::Attr::Metadata::mRuntimeHandle.
Definition: AMDGPUMetadata.h:129
llvm::AMDGPU::HSAMD::AccessQualifier::Default
@ Default
llvm::AMDGPU::HSAMD::Key::Printf
constexpr char Printf[]
Key for HSA::Metadata::mPrintf.
Definition: AMDGPUMetadata.h:425
llvm::AMDGPU::HSAMD::V3::AssemblerDirectiveBegin
constexpr char AssemblerDirectiveBegin[]
HSA metadata beginning assembler directive.
Definition: AMDGPUMetadata.h:459
llvm::AMDGPU::HSAMD::Kernel::Attrs::Metadata::mReqdWorkGroupSize
std::vector< uint32_t > mReqdWorkGroupSize
'reqd_work_group_size' attribute. Optional.
Definition: AMDGPUMetadata.h:135
llvm::AMDGPU::HSAMD::Kernel::DebugProps::Metadata::empty
bool empty() const
Definition: AMDGPUMetadata.h:364
llvm::AMDGPU::HSAMD::AddressSpaceQualifier::Private
@ Private
llvm::AMDGPU::HSAMD::Kernel::Arg::Metadata::mIsRestrict
bool mIsRestrict
True if 'restrict' qualifier is specified. Optional.
Definition: AMDGPUMetadata.h:224
llvm::AMDGPU::HSAMD::Kernel::Arg::Metadata::mName
std::string mName
Name. Optional.
Definition: AMDGPUMetadata.h:202
llvm::AMDGPU::HSAMD::Kernel::CodeProps::Metadata::notEmpty
bool notEmpty() const
Definition: AMDGPUMetadata.h:313
llvm::AMDGPU::HSAMD::V3::AssemblerDirectiveEnd
constexpr char AssemblerDirectiveEnd[]
HSA metadata ending assembler directive.
Definition: AMDGPUMetadata.h:461
llvm::AMDGPU::HSAMD::Kernel::DebugProps::Key::PrivateSegmentBufferSGPR
constexpr char PrivateSegmentBufferSGPR[]
Key for Kernel::DebugProps::Metadata::mPrivateSegmentBufferSGPR.
Definition: AMDGPUMetadata.h:333
llvm::AMDGPU::PALMD::R_2D0A_SPI_SHADER_PGM_RSRC1_HS
@ R_2D0A_SPI_SHADER_PGM_RSRC1_HS
Definition: AMDGPUMetadata.h:484
llvm::AMDGPU::HSAMD::Kernel::CodeProps::Key::WavefrontSize
constexpr char WavefrontSize[]
Key for Kernel::CodeProps::Metadata::mWavefrontSize.
Definition: AMDGPUMetadata.h:251
llvm::AMDGPU::HSAMD::Kernel::CodeProps::Key::NumVGPRs
constexpr char NumVGPRs[]
Key for Kernel::CodeProps::Metadata::mNumVGPRs.
Definition: AMDGPUMetadata.h:255
llvm::AMDGPU::HSAMD::ValueType::Unknown
@ Unknown
llvm::AMDGPU::HSAMD::Kernel::Arg::Metadata::mAddrSpaceQual
AddressSpaceQualifier mAddrSpaceQual
Address space qualifier. Optional.
Definition: AMDGPUMetadata.h:216
llvm::AMDGPU::HSAMD::Kernel::CodeProps::Key::NumSpilledSGPRs
constexpr char NumSpilledSGPRs[]
Key for Kernel::CodeProps::Metadata::mNumSpilledSGPRs.
Definition: AMDGPUMetadata.h:263
llvm::AMDGPU::HSAMD::Kernel::Key::Args
constexpr char Args[]
Key for Kernel::Metadata::mArgs.
Definition: AMDGPUMetadata.h:389
llvm::Region
Definition: RegionInfo.h:889
llvm::AMDGPU::HSAMD::Kernel::Attrs::Metadata::mRuntimeHandle
std::string mRuntimeHandle
External symbol created by runtime to store the kernel address for enqueued blocks.
Definition: AMDGPUMetadata.h:142
llvm::AMDGPU::HSAMD::Kernel::CodeProps::Key::IsDynamicCallStack
constexpr char IsDynamicCallStack[]
Key for Kernel::CodeProps::Metadata::mIsDynamicCallStack.
Definition: AMDGPUMetadata.h:259
llvm::AMDGPU::HSAMD::VersionMinorV3
constexpr uint32_t VersionMinorV3
HSA metadata minor version for code object V3.
Definition: AMDGPUMetadata.h:40
llvm::AMDGPU::HSAMD::Kernel::CodeProps::Metadata::mGroupSegmentFixedSize
uint32_t mGroupSegmentFixedSize
Size in bytes of the group segment memory required by a workgroup.
Definition: AMDGPUMetadata.h:276
llvm::AMDGPU::HSAMD::Kernel::Attrs::Metadata::mWorkGroupSizeHint
std::vector< uint32_t > mWorkGroupSizeHint
'work_group_size_hint' attribute. Optional.
Definition: AMDGPUMetadata.h:137
llvm::AMDGPU::HSAMD::Kernel::CodeProps::Key::IsXNACKEnabled
constexpr char IsXNACKEnabled[]
Key for Kernel::CodeProps::Metadata::mIsXNACKEnabled.
Definition: AMDGPUMetadata.h:261
llvm::AMDGPU::HSAMD::Kernel::CodeProps::Metadata::mNumVGPRs
uint16_t mNumVGPRs
Total number of VGPRs used by a workitem. Optional.
Definition: AMDGPUMetadata.h:288
llvm::AMDGPU::HSAMD::Kernel::Arg::Key::ActualAccQual
constexpr char ActualAccQual[]
Key for Kernel::Arg::Metadata::mActualAccQual.
Definition: AMDGPUMetadata.h:188
llvm::AMDGPU::HSAMD::ValueKind::HiddenGlobalOffsetX
@ HiddenGlobalOffsetX
llvm::AMDGPU::HSAMD::Kernel::Arg::Key::Size
constexpr char Size[]
Key for Kernel::Arg::Metadata::mSize.
Definition: AMDGPUMetadata.h:172
llvm::AMDGPU::HSAMD::VersionMinorV4
constexpr uint32_t VersionMinorV4
HSA metadata minor version for code object V4.
Definition: AMDGPUMetadata.h:45
llvm::AMDGPU::HSAMD::toString
std::error_code toString(Metadata HSAMetadata, std::string &String)
Converts HSAMetadata to String.
Definition: AMDGPUMetadata.cpp:219