LLVM 24.0.0git
AnalysisOptions.h
Go to the documentation of this file.
1//===----------------------------------------------------------------------===//
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#ifndef LLVM_LIB_ANALYSIS_ANALYSISOPTIONS_H
10#define LLVM_LIB_ANALYSIS_ANALYSISOPTIONS_H
11
12#include "llvm/IR/Function.h"
13#include "llvm/IR/LLVMContext.h"
14#include <cstdint>
15#include <optional>
16
17namespace llvm {
18
20enum class CompressionType : uint16_t;
21} // namespace dxbc::SourceInfo::Contents
22
23// Forward-declared so that Analysis headers can include this one. Fields of
24// these types default to the zero enumerator.
25enum class GVDAGType;
26enum class IR2VecKind;
28enum class PGOViewCountsType;
29
37
43
45
46// Types of dependence test routines.
58
60
61enum class InlinePriorityMode : int { Size, Cost, CostBenefit, ML };
62
64
66
67} // namespace llvm
68
69#define OPTIONS_STRUCT_DECL
70#include "AnalysisOptions.inc"
71
72namespace llvm {
73
74class Loop;
75class Module;
76
77inline const AnalysisOptions &getAnalysisOptions(const LLVMContext &C) {
78 return C.getLibraryOptions().get<AnalysisOptions>();
79}
80
81inline const AnalysisOptions &getAnalysisOptions(const Function &F) {
82 return getAnalysisOptions(F.getContext());
83}
84
85const AnalysisOptions &getAnalysisOptions(const Module &M);
86const AnalysisOptions &getAnalysisOptions(const Loop &L);
87
88} // namespace llvm
89
90#endif // LLVM_LIB_ANALYSIS_ANALYSISOPTIONS_H
static GCRegistry::Add< ShadowStackGC > C("shadow-stack", "Very portable GC for uncooperative code generators")
#define F(x, y, z)
Definition MD5.cpp:54
Machine Check Debug Module
This is an important class for using LLVM in a threaded context.
Definition LLVMContext.h:76
This is an optimization pass for GlobalISel generic memory operations.
InstructionCost Cost
ForceSummaryHotness
const AnalysisOptions & getAnalysisOptions(const LLVMContext &C)
IR2VecKind
IR2Vec computes two kinds of embeddings: Symbolic and Flow-aware.
Definition IR2Vec.h:70
IntrinsicCostStrategy
SkipMLPolicyCriteria
@ Auto
Determine whether to use color based on the command line argument and the raw_ostream.
Definition WithColor.h:43