19
19
#include " llvm/ADT/StringRef.h"
20
20
#include " llvm/BinaryFormat/Dwarf.h"
21
21
#include " llvm/ObjectYAML/YAML.h"
22
+ #include " llvm/Support/Compiler.h"
22
23
#include " llvm/Support/YAMLTraits.h"
23
24
#include < cstdint>
24
25
#include < optional>
@@ -255,16 +256,16 @@ struct Data {
255
256
std::optional<std::vector<ListTable<LoclistEntry>>> DebugLoclists;
256
257
std::optional<DebugNamesSection> DebugNames;
257
258
258
- bool isEmpty () const ;
259
+ LLVM_ABI bool isEmpty () const ;
259
260
260
- SetVector<StringRef> getNonEmptySectionNames () const ;
261
+ LLVM_ABI SetVector<StringRef> getNonEmptySectionNames () const ;
261
262
262
263
struct AbbrevTableInfo {
263
264
uint64_t Index;
264
265
uint64_t Offset;
265
266
};
266
- Expected<AbbrevTableInfo> getAbbrevTableInfoByID (uint64_t ID) const ;
267
- StringRef getAbbrevTableContentByIndex (uint64_t Index) const ;
267
+ LLVM_ABI Expected<AbbrevTableInfo> getAbbrevTableInfoByID (uint64_t ID) const ;
268
+ LLVM_ABI StringRef getAbbrevTableContentByIndex (uint64_t Index) const ;
268
269
269
270
private:
270
271
mutable std::unordered_map<uint64_t , AbbrevTableInfo> AbbrevTableInfoMap;
@@ -310,88 +311,90 @@ namespace llvm {
310
311
namespace yaml {
311
312
312
313
template <> struct MappingTraits <DWARFYAML::Data> {
313
- static void mapping (IO &IO, DWARFYAML::Data &DWARF);
314
+ LLVM_ABI static void mapping (IO &IO, DWARFYAML::Data &DWARF);
314
315
};
315
316
316
317
template <> struct MappingTraits <DWARFYAML::AbbrevTable> {
317
- static void mapping (IO &IO, DWARFYAML::AbbrevTable &AbbrevTable);
318
+ LLVM_ABI static void mapping (IO &IO, DWARFYAML::AbbrevTable &AbbrevTable);
318
319
};
319
320
320
321
template <> struct MappingTraits <DWARFYAML::Abbrev> {
321
- static void mapping (IO &IO, DWARFYAML::Abbrev &Abbrev);
322
+ LLVM_ABI static void mapping (IO &IO, DWARFYAML::Abbrev &Abbrev);
322
323
};
323
324
324
325
template <> struct MappingTraits <DWARFYAML::AttributeAbbrev> {
325
- static void mapping (IO &IO, DWARFYAML::AttributeAbbrev &AttAbbrev);
326
+ LLVM_ABI static void mapping (IO &IO, DWARFYAML::AttributeAbbrev &AttAbbrev);
326
327
};
327
328
328
329
template <> struct MappingTraits <DWARFYAML::ARangeDescriptor> {
329
- static void mapping (IO &IO, DWARFYAML::ARangeDescriptor &Descriptor);
330
+ LLVM_ABI static void mapping (IO &IO, DWARFYAML::ARangeDescriptor &Descriptor);
330
331
};
331
332
332
333
template <> struct MappingTraits <DWARFYAML::ARange> {
333
- static void mapping (IO &IO, DWARFYAML::ARange &ARange);
334
+ LLVM_ABI static void mapping (IO &IO, DWARFYAML::ARange &ARange);
334
335
};
335
336
336
337
template <> struct MappingTraits <DWARFYAML::RangeEntry> {
337
- static void mapping (IO &IO, DWARFYAML::RangeEntry &Entry);
338
+ LLVM_ABI static void mapping (IO &IO, DWARFYAML::RangeEntry &Entry);
338
339
};
339
340
340
341
template <> struct MappingTraits <DWARFYAML::Ranges> {
341
- static void mapping (IO &IO, DWARFYAML::Ranges &Ranges);
342
+ LLVM_ABI static void mapping (IO &IO, DWARFYAML::Ranges &Ranges);
342
343
};
343
344
344
345
template <> struct MappingTraits <DWARFYAML::PubEntry> {
345
- static void mapping (IO &IO, DWARFYAML::PubEntry &Entry);
346
+ LLVM_ABI static void mapping (IO &IO, DWARFYAML::PubEntry &Entry);
346
347
};
347
348
348
349
template <> struct MappingTraits <DWARFYAML::PubSection> {
349
- static void mapping (IO &IO, DWARFYAML::PubSection &Section);
350
+ LLVM_ABI static void mapping (IO &IO, DWARFYAML::PubSection &Section);
350
351
};
351
352
352
353
template <> struct MappingTraits <DWARFYAML::Unit> {
353
- static void mapping (IO &IO, DWARFYAML::Unit &Unit);
354
+ LLVM_ABI static void mapping (IO &IO, DWARFYAML::Unit &Unit);
354
355
};
355
356
356
357
template <> struct MappingTraits <DWARFYAML::DebugNamesSection> {
357
- static void mapping (IO &IO, DWARFYAML::DebugNamesSection &);
358
+ LLVM_ABI static void mapping (IO &IO, DWARFYAML::DebugNamesSection &);
358
359
};
359
360
template <> struct MappingTraits <DWARFYAML::DebugNameEntry> {
360
- static void mapping (IO &IO, DWARFYAML::DebugNameEntry &);
361
+ LLVM_ABI static void mapping (IO &IO, DWARFYAML::DebugNameEntry &);
361
362
};
362
363
template <> struct MappingTraits <DWARFYAML::DebugNameAbbreviation> {
363
- static void mapping (IO &IO, DWARFYAML::DebugNameAbbreviation &);
364
+ LLVM_ABI static void mapping (IO &IO, DWARFYAML::DebugNameAbbreviation &);
364
365
};
365
366
template <> struct MappingTraits <DWARFYAML::IdxForm> {
366
- static void mapping (IO &IO, DWARFYAML::IdxForm &);
367
+ LLVM_ABI static void mapping (IO &IO, DWARFYAML::IdxForm &);
367
368
};
368
369
369
370
template <> struct MappingTraits <DWARFYAML::Entry> {
370
- static void mapping (IO &IO, DWARFYAML::Entry &Entry);
371
+ LLVM_ABI static void mapping (IO &IO, DWARFYAML::Entry &Entry);
371
372
};
372
373
373
374
template <> struct MappingTraits <DWARFYAML::FormValue> {
374
- static void mapping (IO &IO, DWARFYAML::FormValue &FormValue);
375
+ LLVM_ABI static void mapping (IO &IO, DWARFYAML::FormValue &FormValue);
375
376
};
376
377
377
378
template <> struct MappingTraits <DWARFYAML::File> {
378
- static void mapping (IO &IO, DWARFYAML::File &File);
379
+ LLVM_ABI static void mapping (IO &IO, DWARFYAML::File &File);
379
380
};
380
381
381
382
template <> struct MappingTraits <DWARFYAML::LineTableOpcode> {
382
- static void mapping (IO &IO, DWARFYAML::LineTableOpcode &LineTableOpcode);
383
+ LLVM_ABI static void mapping (IO &IO,
384
+ DWARFYAML::LineTableOpcode &LineTableOpcode);
383
385
};
384
386
385
387
template <> struct MappingTraits <DWARFYAML::LineTable> {
386
- static void mapping (IO &IO, DWARFYAML::LineTable &LineTable);
388
+ LLVM_ABI static void mapping (IO &IO, DWARFYAML::LineTable &LineTable);
387
389
};
388
390
389
391
template <> struct MappingTraits <DWARFYAML::SegAddrPair> {
390
- static void mapping (IO &IO, DWARFYAML::SegAddrPair &SegAddrPair);
392
+ LLVM_ABI static void mapping (IO &IO, DWARFYAML::SegAddrPair &SegAddrPair);
391
393
};
392
394
393
395
template <> struct MappingTraits <DWARFYAML::DWARFOperation> {
394
- static void mapping (IO &IO, DWARFYAML::DWARFOperation &DWARFOperation);
396
+ LLVM_ABI static void mapping (IO &IO,
397
+ DWARFYAML::DWARFOperation &DWARFOperation);
395
398
};
396
399
397
400
template <typename EntryType>
@@ -407,19 +410,20 @@ struct MappingTraits<DWARFYAML::ListEntries<EntryType>> {
407
410
};
408
411
409
412
template <> struct MappingTraits <DWARFYAML::RnglistEntry> {
410
- static void mapping (IO &IO, DWARFYAML::RnglistEntry &RnglistEntry);
413
+ LLVM_ABI static void mapping (IO &IO, DWARFYAML::RnglistEntry &RnglistEntry);
411
414
};
412
415
413
416
template <> struct MappingTraits <DWARFYAML::LoclistEntry> {
414
- static void mapping (IO &IO, DWARFYAML::LoclistEntry &LoclistEntry);
417
+ LLVM_ABI static void mapping (IO &IO, DWARFYAML::LoclistEntry &LoclistEntry);
415
418
};
416
419
417
420
template <> struct MappingTraits <DWARFYAML::AddrTableEntry> {
418
- static void mapping (IO &IO, DWARFYAML::AddrTableEntry &AddrTable);
421
+ LLVM_ABI static void mapping (IO &IO, DWARFYAML::AddrTableEntry &AddrTable);
419
422
};
420
423
421
424
template <> struct MappingTraits <DWARFYAML::StringOffsetsTable> {
422
- static void mapping (IO &IO, DWARFYAML::StringOffsetsTable &StrOffsetsTable);
425
+ LLVM_ABI static void mapping (IO &IO,
426
+ DWARFYAML::StringOffsetsTable &StrOffsetsTable);
423
427
};
424
428
425
429
template <> struct ScalarEnumerationTraits <dwarf::DwarfFormat> {
0 commit comments