LLVM
20.0.0git
lib
ObjectYAML
GOFFYAML.cpp
Go to the documentation of this file.
1
//===-- GOFFYAML.cpp - GOFF YAMLIO implementation ---------------*- 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 defines classes for handling the YAML representation of GOFF.
10
//
11
//===----------------------------------------------------------------------===//
12
13
#include "
llvm/ObjectYAML/GOFFYAML.h
"
14
#include "
llvm/BinaryFormat/GOFF.h
"
15
#include <string.h>
16
17
namespace
llvm
{
18
namespace
GOFFYAML {
19
20
Object::Object
() {}
21
22
}
// namespace GOFFYAML
23
24
namespace
yaml {
25
26
void
MappingTraits<GOFFYAML::FileHeader>::mapping(
27
IO &IO,
GOFFYAML::FileHeader
&FileHdr) {
28
IO.mapOptional(
"TargetEnvironment"
, FileHdr.
TargetEnvironment
, 0);
29
IO.mapOptional(
"TargetOperatingSystem"
, FileHdr.
TargetOperatingSystem
, 0);
30
IO.mapOptional(
"CCSID"
, FileHdr.
CCSID
, 0);
31
IO.mapOptional(
"CharacterSetName"
, FileHdr.
CharacterSetName
,
""
);
32
IO.mapOptional(
"LanguageProductIdentifier"
, FileHdr.
LanguageProductIdentifier
,
33
""
);
34
IO.mapOptional(
"ArchitectureLevel"
, FileHdr.
ArchitectureLevel
, 1);
35
IO.mapOptional(
"InternalCCSID"
, FileHdr.
InternalCCSID
);
36
IO.mapOptional(
"TargetSoftwareEnvironment"
,
37
FileHdr.
TargetSoftwareEnvironment
);
38
}
39
40
void
MappingTraits<GOFFYAML::Object>::mapping(IO &IO, GOFFYAML::Object &Obj) {
41
IO.mapTag(
"!GOFF"
,
true
);
42
IO.mapRequired(
"FileHeader"
, Obj.Header);
43
}
44
45
}
// namespace yaml
46
}
// namespace llvm
GOFF.h
GOFFYAML.h
llvm
This is an optimization pass for GlobalISel generic memory operations.
Definition:
AddressRanges.h:18
llvm::GOFFYAML::FileHeader
Definition:
GOFFYAML.h:28
llvm::GOFFYAML::FileHeader::CCSID
uint16_t CCSID
Definition:
GOFFYAML.h:31
llvm::GOFFYAML::FileHeader::TargetSoftwareEnvironment
std::optional< uint8_t > TargetSoftwareEnvironment
Definition:
GOFFYAML.h:36
llvm::GOFFYAML::FileHeader::ArchitectureLevel
uint32_t ArchitectureLevel
Definition:
GOFFYAML.h:34
llvm::GOFFYAML::FileHeader::LanguageProductIdentifier
StringRef LanguageProductIdentifier
Definition:
GOFFYAML.h:33
llvm::GOFFYAML::FileHeader::CharacterSetName
StringRef CharacterSetName
Definition:
GOFFYAML.h:32
llvm::GOFFYAML::FileHeader::TargetOperatingSystem
uint32_t TargetOperatingSystem
Definition:
GOFFYAML.h:30
llvm::GOFFYAML::FileHeader::InternalCCSID
std::optional< uint16_t > InternalCCSID
Definition:
GOFFYAML.h:35
llvm::GOFFYAML::FileHeader::TargetEnvironment
uint32_t TargetEnvironment
Definition:
GOFFYAML.h:29
llvm::GOFFYAML::Object::Object
Object()
Definition:
GOFFYAML.cpp:20
Generated on Tue Dec 3 2024 14:21:46 for LLVM by
1.9.6