LLVM
13.0.0git
include
llvm
TextAPI
MachO
Platform.h
Go to the documentation of this file.
1
//===- llvm/TextAPI/MachO/Platform.h - Platform -----------------*- 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
// Defines the Platforms supported by Tapi and helpers.
10
//
11
//===----------------------------------------------------------------------===//
12
#ifndef LLVM_TEXTAPI_MACHO_PLATFORM_H
13
#define LLVM_TEXTAPI_MACHO_PLATFORM_H
14
15
#include "
llvm/ADT/SmallSet.h
"
16
#include "
llvm/BinaryFormat/MachO.h
"
17
18
namespace
llvm
{
19
namespace
MachO {
20
21
/// Defines the list of MachO platforms.
22
enum class
PlatformKind
: unsigned {
23
unknown
,
24
macOS
=
MachO::PLATFORM_MACOS
,
25
iOS
=
MachO::PLATFORM_IOS
,
26
tvOS
=
MachO::PLATFORM_TVOS
,
27
watchOS
=
MachO::PLATFORM_WATCHOS
,
28
bridgeOS
=
MachO::PLATFORM_BRIDGEOS
,
29
macCatalyst
=
MachO::PLATFORM_MACCATALYST
,
30
iOSSimulator
=
MachO::PLATFORM_IOSSIMULATOR
,
31
tvOSSimulator
=
MachO::PLATFORM_TVOSSIMULATOR
,
32
watchOSSimulator
=
MachO::PLATFORM_WATCHOSSIMULATOR
,
33
driverKit
=
MachO::PLATFORM_DRIVERKIT
,
34
};
35
36
using
PlatformSet
=
SmallSet<PlatformKind, 3>
;
37
38
PlatformKind
mapToPlatformKind
(
PlatformKind
Platform,
bool
WantSim);
39
PlatformKind
mapToPlatformKind
(
const
Triple
&
Target
);
40
PlatformSet
mapToPlatformSet
(
ArrayRef<Triple>
Targets);
41
StringRef
getPlatformName
(
PlatformKind
Platform);
42
43
}
// end namespace MachO.
44
}
// end namespace llvm.
45
46
#endif // LLVM_TEXTAPI_MACHO_PLATFORM_H
llvm::MachO::PLATFORM_MACOS
@ PLATFORM_MACOS
Definition:
MachO.h:492
llvm
This class represents lattice values for constants.
Definition:
AllocatorList.h:23
llvm::MachO::PLATFORM_WATCHOSSIMULATOR
@ PLATFORM_WATCHOSSIMULATOR
Definition:
MachO.h:500
llvm::MachO::Target
Definition:
Target.h:24
llvm::Triple
Triple - Helper class for working with autoconf configuration names.
Definition:
Triple.h:45
llvm::MachO::PLATFORM_IOS
@ PLATFORM_IOS
Definition:
MachO.h:493
llvm::MachO::PLATFORM_MACCATALYST
@ PLATFORM_MACCATALYST
Definition:
MachO.h:497
llvm::SmallSet
SmallSet - This maintains a set of unique values, optimizing for the case when the set is small (less...
Definition:
SmallSet.h:134
llvm::MachO::PLATFORM_IOSSIMULATOR
@ PLATFORM_IOSSIMULATOR
Definition:
MachO.h:498
llvm::MachO::PlatformKind::iOS
@ iOS
llvm::MachO::PlatformKind::watchOSSimulator
@ watchOSSimulator
llvm::MachO::PlatformKind::macCatalyst
@ macCatalyst
llvm::MachO::PlatformKind::bridgeOS
@ bridgeOS
llvm::MachO::getPlatformName
StringRef getPlatformName(PlatformKind Platform)
Definition:
Platform.cpp:64
llvm::MachO::PlatformKind::driverKit
@ driverKit
llvm::MachO::PLATFORM_BRIDGEOS
@ PLATFORM_BRIDGEOS
Definition:
MachO.h:496
llvm::MachO::mapToPlatformKind
PlatformKind mapToPlatformKind(PlatformKind Platform, bool WantSim)
Definition:
Platform.cpp:20
llvm::ArrayRef
ArrayRef - Represent a constant reference to an array (0 or more elements consecutively in memory),...
Definition:
APInt.h:32
llvm::StringRef
StringRef - Represent a constant reference to a string, i.e.
Definition:
StringRef.h:57
llvm::MachO::PlatformKind::watchOS
@ watchOS
llvm::MachO::PLATFORM_TVOS
@ PLATFORM_TVOS
Definition:
MachO.h:494
llvm::MachO::PlatformKind::macOS
@ macOS
llvm::MachO::PlatformKind::tvOS
@ tvOS
llvm::MachO::PLATFORM_TVOSSIMULATOR
@ PLATFORM_TVOSSIMULATOR
Definition:
MachO.h:499
llvm::MachO::PLATFORM_WATCHOS
@ PLATFORM_WATCHOS
Definition:
MachO.h:495
llvm::MachO::PlatformKind::iOSSimulator
@ iOSSimulator
llvm::MachO::mapToPlatformSet
PlatformSet mapToPlatformSet(ArrayRef< Triple > Targets)
Definition:
Platform.cpp:57
llvm::MachO::PLATFORM_DRIVERKIT
@ PLATFORM_DRIVERKIT
Definition:
MachO.h:501
llvm::MachO::PlatformKind::tvOSSimulator
@ tvOSSimulator
llvm::MachO::PlatformKind
PlatformKind
Defines the list of MachO platforms.
Definition:
Platform.h:22
MachO.h
llvm::MachO::PlatformKind::unknown
@ unknown
SmallSet.h
Generated on Fri Mar 5 2021 21:24:42 for LLVM by
1.8.17