LLVM 22.0.0git
LVOptions.h
Go to the documentation of this file.
1//===-- LVOptions.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// This file defines the LVOptions class, which is used to record the command
10// line options.
11//
12//===----------------------------------------------------------------------===//
13
14#ifndef LLVM_DEBUGINFO_LOGICALVIEW_CORE_LVOPTIONS_H
15#define LLVM_DEBUGINFO_LOGICALVIEW_CORE_LVOPTIONS_H
16
17#include "llvm/ADT/StringSet.h"
23#include "llvm/Support/Regex.h"
24#include <set>
25#include <string>
26
27namespace llvm {
28namespace logicalview {
29
30// Generate get and set 'bool' functions.
31#define BOOL_FUNCTION(FAMILY, FIELD) \
32 bool get##FAMILY##FIELD() const { return FAMILY.FIELD; } \
33 void set##FAMILY##FIELD() { FAMILY.FIELD = true; } \
34 void reset##FAMILY##FIELD() { FAMILY.FIELD = false; }
35
36// Generate get and set 'unsigned' functions.
37#define UNSIGNED_FUNCTION(FAMILY, FIELD) \
38 unsigned get##FAMILY##FIELD() const { return FAMILY.FIELD; } \
39 void set##FAMILY##FIELD(unsigned Value) { FAMILY.FIELD = Value; } \
40 void reset##FAMILY##FIELD() { FAMILY.FIELD = -1U; }
41
42// Generate get and set 'std::string' functions.
43#define STD_STRING_FUNCTION(FAMILY, FIELD) \
44 std::string get##FAMILY##FIELD() const { return FAMILY.FIELD; } \
45 void set##FAMILY##FIELD(std::string FIELD) { \
46 FAMILY.FIELD = std::move(FIELD); \
47 } \
48 void reset##FAMILY##FIELD() { FAMILY.FIELD = ""; }
49
50// Generate get and set 'std::set' functions.
51#define STDSET_FUNCTION_4(FAMILY, FIELD, TYPE, SET) \
52 bool get##FAMILY##FIELD() const { \
53 return FAMILY.SET.find(TYPE::FIELD) != FAMILY.SET.end(); \
54 } \
55 void set##FAMILY##FIELD() { FAMILY.SET.insert(TYPE::FIELD); } \
56 void reset##FAMILY##FIELD() { FAMILY.SET.erase(TYPE::FIELD); }
57
58#define STDSET_FUNCTION_5(FAMILY, FIELD, ENTRY, TYPE, SET) \
59 bool get##FAMILY##FIELD##ENTRY() const { \
60 return FAMILY.SET.find(TYPE::ENTRY) != FAMILY.SET.end(); \
61 } \
62 void set##FAMILY##FIELD##ENTRY() { FAMILY.SET.insert(TYPE::ENTRY); }
63
64// Generate get and set functions for '--attribute'
65#define ATTRIBUTE_OPTION(FIELD) \
66 STDSET_FUNCTION_4(Attribute, FIELD, LVAttributeKind, Kinds)
67
68// Generate get and set functions for '--output'
69#define OUTPUT_OPTION(FIELD) \
70 STDSET_FUNCTION_4(Output, FIELD, LVOutputKind, Kinds)
71
72// Generate get and set functions for '--print'
73#define PRINT_OPTION(FIELD) STDSET_FUNCTION_4(Print, FIELD, LVPrintKind, Kinds)
74
75// Generate get and set functions for '--warning'
76#define WARNING_OPTION(FIELD) \
77 STDSET_FUNCTION_4(Warning, FIELD, LVWarningKind, Kinds)
78
79// Generate get and set functions for '--compare'
80#define COMPARE_OPTION(FIELD) \
81 STDSET_FUNCTION_4(Compare, FIELD, LVCompareKind, Elements)
82
83// Generate get and set functions for '--report'
84#define REPORT_OPTION(FIELD) \
85 STDSET_FUNCTION_4(Report, FIELD, LVReportKind, Kinds)
86
87// Generate get and set functions for '--internal'
88#define INTERNAL_OPTION(FIELD) \
89 STDSET_FUNCTION_4(Internal, FIELD, LVInternalKind, Kinds)
90
91using LVOffsetSet = std::set<uint64_t>;
92
93enum class LVAttributeKind {
94 All, // --attribute=all
95 Argument, // --attribute=argument
96 Base, // --attribute=base
97 Coverage, // --attribute=coverage
98 Directories, // --attribute=directories
99 Discarded, // --attribute=discarded
100 Discriminator, // --attribute=discriminator
101 Encoded, // --attribute=encoded
102 Extended, // --attribute=extended
103 Filename, // --attribute=filename
104 Files, // --attribute=files
105 Format, // --attribute=format
106 Gaps, // --attribute=gaps
107 Generated, // --attribute=generated
108 Global, // --attribute=global
109 Inserted, // --attribute=inserted
110 Language, // --attribute=language
111 Level, // --attribute=level
112 Linkage, // --attribute=linkage
113 Local, // --attribute=local
114 Location, // --attribute=location
115 Offset, // --attribute=offset
116 Pathname, // --attribute=pathname
117 Producer, // --attribute=producer
118 Publics, // --attribute=publics
119 Qualified, // --attribute=qualified
120 Qualifier, // --attribute=qualifier
121 Range, // --attribute=range
122 Reference, // --attribute=reference
123 Register, // --attribute=register
124 Size, // --attribute=size
125 Standard, // --attribute=standard
126 Subrange, // --attribute=subrange
127 System, // --attribute=system
128 Typename, // --attribute=typename
129 Underlying, // --attribute=underlying
130 Zero // --attribute=zero
131};
132using LVAttributeKindSet = std::set<LVAttributeKind>;
133
134enum class LVCompareKind {
135 All, // --compare=all
136 Lines, // --compare=lines
137 Scopes, // --compare=scopes
138 Symbols, // --compare=symbols
139 Types // --compare=types
140};
141using LVCompareKindSet = std::set<LVCompareKind>;
142
143enum class LVOutputKind {
144 All, // --output=all
145 Split, // --output=split
146 Json, // --output=json
147 Text // --output=text
148};
149using LVOutputKindSet = std::set<LVOutputKind>;
150
151enum class LVPrintKind {
152 All, // --print=all
153 Elements, // --print=elements
154 Instructions, // --print=instructions
155 Lines, // --print=lines
156 Scopes, // --print=scopes
157 Sizes, // --print=sizes
158 Symbols, // --print=symbols
159 Summary, // --print=summary
160 Types, // --print=types
161 Warnings // --print=warnings
162};
163using LVPrintKindSet = std::set<LVPrintKind>;
164
165enum class LVReportKind {
166 All, // --report=all
167 Children, // --report=children
168 List, // --report=list
169 Parents, // --report=parents
170 View // --report=view
171};
172using LVReportKindSet = std::set<LVReportKind>;
173
174enum class LVWarningKind {
175 All, // --warning=all
176 Coverages, // --warning=coverages
177 Lines, // --warning=lines
178 Locations, // --warning=locations
179 Ranges // --warning=ranges
180};
181using LVWarningKindSet = std::set<LVWarningKind>;
182
183enum class LVInternalKind {
184 All, // --internal=all
185 Cmdline, // --internal=cmdline
186 ID, // --internal=id
187 Integrity, // --internal=integrity
188 None, // --internal=none
189 Tag // --internal=tag
190};
191using LVInternalKindSet = std::set<LVInternalKind>;
192
193// The 'Kinds' members are a one-to-one mapping to the associated command
194// options that supports comma separated values. There are other 'bool'
195// members that in very few cases point to a command option (see associated
196// comment). Other cases for 'bool' refers to internal values derivated from
197// the command options.
199 class LVAttribute {
200 public:
201 LVAttributeKindSet Kinds; // --attribute=<Kind>
202 bool Added = false; // Added elements found during comparison.
203 bool AnyLocation = false; // Any kind of location information.
204 bool AnySource = false; // Any kind of source information.
205 bool Missing = false; // Missing elements found during comparison.
206 };
207
208 class LVCompare {
209 public:
210 LVCompareKindSet Elements; // --compare=<kind>
211 bool Context = false; // --compare-context
212 bool Execute = false; // Compare requested.
213 bool Print = false; // Enable any printing.
214 };
215
216 class LVPrint {
217 public:
218 LVPrintKindSet Kinds; // --print=<Kind>
219 bool AnyElement = false; // Request to print any element.
220 bool AnyLine = false; // Print 'lines' or 'instructions'.
221 bool Execute = false; // Print requested.
222 bool Formatting = true; // Disable formatting during printing.
223 bool Offset = false; // Print offsets while formatting is disabled.
224 bool SizesSummary = false; // Print 'sizes' or 'summary'.
225 };
226
227 class LVReport {
228 public:
229 LVReportKindSet Kinds; // --report=<kind>
230 bool AnyView = false; // View, Parents or Children.
231 bool Execute = false; // Report requested.
232 };
233
234 class LVSelect {
235 public:
236 bool IgnoreCase = false; // --select-ignore-case
237 bool UseRegex = false; // --select-use-regex
238 bool Execute = false; // Select requested.
239 bool GenericKind = false; // We have collected generic kinds.
240 bool GenericPattern = false; // We have collected generic patterns.
241 bool OffsetPattern = false; // We have collected offset patterns.
242 StringSet<> Generic; // --select=<Pattern>
243 LVOffsetSet Offsets; // --select-offset=<Offset>
244 LVElementKindSet Elements; // --select-elements=<Kind>
245 LVLineKindSet Lines; // --select-lines=<Kind>
246 LVScopeKindSet Scopes; // --select-scopes=<Kind>
247 LVSymbolKindSet Symbols; // --select-symbols=<Kind>
248 LVTypeKindSelection Types; // --select-types=<Kind>
249 };
250
251 class LVOutput {
252 public:
253 LVOutputKindSet Kinds; // --output=<kind>
254 LVSortMode SortMode = LVSortMode::None; // --output-sort=<SortMode>
255 std::string Folder; // --output-folder=<Folder>
256 unsigned Level = -1U; // --output-level=<level>
257 };
258
259 class LVWarning {
260 public:
261 LVWarningKindSet Kinds; // --warning=<Kind>
262 };
263
264 class LVInternal {
265 public:
266 LVInternalKindSet Kinds; // --internal=<Kind>
267 };
268
269 class LVGeneral {
270 public:
271 bool CollectRanges = false; // Collect ranges information.
272 };
273
274 // Filters the output of the filename associated with the element being
275 // printed in order to see clearly which logical elements belongs to
276 // a particular filename. It is value is reset after the element
277 // that represents the Compile Unit is printed.
278 size_t LastFilenameIndex = 0;
279
280 // Controls the amount of additional spaces to insert when printing
281 // object attributes, in order to get a consistent printing layout.
282 size_t IndentationSize = 0;
283
284 // Calculate the indentation size, so we can use that value when printing
285 // additional attributes to objects, such as location.
286 void calculateIndentationSize();
287
288public:
289 void resetFilenameIndex() { LastFilenameIndex = 0; }
291 bool IndexChanged = (Index != LastFilenameIndex);
292 if (IndexChanged)
293 LastFilenameIndex = Index;
294 return IndexChanged;
295 }
296
297 // Access to command line options, pattern and printing information.
298 LLVM_ABI static LVOptions *getOptions();
299 LLVM_ABI static void setOptions(LVOptions *Options);
300
301 LVOptions() = default;
302 LVOptions(const LVOptions &) = default;
303 LVOptions &operator=(const LVOptions &) = default;
304 ~LVOptions() = default;
305
306 // Some command line options support shortcuts. For example:
307 // The command line option '--print=elements' is a shortcut for:
308 // '--print=instructions,lines,scopes,symbols,types'.
309 // In the case of logical view comparison, some options related to
310 // attributes must be set or reset for a proper comparison.
311 // Resolve any dependencies between command line options.
313 size_t indentationSize() const { return IndentationSize; }
314
315 LVAttribute Attribute;
316 LVCompare Compare;
317 LVOutput Output;
318 LVPrint Print;
319 LVReport Report;
320 LVSelect Select;
321 LVWarning Warning;
322 LVInternal Internal;
323 LVGeneral General;
324
325 // --attribute.
367
368 // --compare.
377
378 // --output.
385 LVSortMode getSortMode() const { return Output.SortMode; }
386 void setSortMode(LVSortMode SortMode) { Output.SortMode = SortMode; }
387
388 // --print.
399 BOOL_FUNCTION(Print, AnyElement);
402 BOOL_FUNCTION(Print, Formatting);
404 BOOL_FUNCTION(Print, SizesSummary);
405
406 // --report.
414
415 // --select.
416 BOOL_FUNCTION(Select, IgnoreCase);
419 BOOL_FUNCTION(Select, GenericKind);
420 BOOL_FUNCTION(Select, GenericPattern);
421 BOOL_FUNCTION(Select, OffsetPattern);
422
423 // --warning.
429
430 // --internal.
437
438 // General shortcuts to some combinations.
439 BOOL_FUNCTION(General, CollectRanges);
440
441 LLVM_ABI void print(raw_ostream &OS) const;
442
443#if !defined(NDEBUG) || defined(LLVM_ENABLE_DUMP)
444 void dump() const { print(dbgs()); }
445#endif
446};
447
448inline LVOptions &options() { return (*LVOptions::getOptions()); }
450
451class LVPatterns final {
452 // Pattern Mode.
453 enum class LVMatchMode {
454 None = 0, // No given pattern.
455 Match, // Perfect match.
456 NoCase, // Ignore case.
457 Regex // Regular expression.
458 };
459
460 // Keep the search pattern information.
461 struct LVMatch {
462 std::string Pattern; // Normal pattern.
463 std::shared_ptr<Regex> RE; // Regular Expression Pattern.
464 LVMatchMode Mode = LVMatchMode::None; // Match mode.
465 };
466
467 using LVMatchInfo = std::vector<LVMatch>;
468 LVMatchInfo GenericMatchInfo;
469 using LVMatchOffsets = std::vector<uint64_t>;
470 LVMatchOffsets OffsetMatchInfo;
471
472 // Element selection.
473 LVElementDispatch ElementDispatch;
474 LVLineDispatch LineDispatch;
475 LVScopeDispatch ScopeDispatch;
476 LVSymbolDispatch SymbolDispatch;
477 LVTypeDispatch TypeDispatch;
478
479 // Element selection request.
480 LVElementRequest ElementRequest;
481 LVLineRequest LineRequest;
482 LVScopeRequest ScopeRequest;
483 LVSymbolRequest SymbolRequest;
484 LVTypeRequest TypeRequest;
485
486 // Check an element printing Request.
487 template <typename T, typename U>
488 bool checkElementRequest(const T *Element, const U &Requests) const {
489 assert(Element && "Element must not be nullptr");
490 for (const auto &Request : Requests)
491 if ((Element->*Request)())
492 return true;
493 // Check generic element requests.
494 for (const LVElementGetFunction &Request : ElementRequest)
495 if ((Element->*Request)())
496 return true;
497 return false;
498 }
499
500 // Add an element printing request based on its kind.
501 template <typename T, typename U, typename V>
502 void addRequest(const T &Selection, const U &Dispatch, V &Request) const {
503 for (const auto &Entry : Selection) {
504 // Find target function to fullfit request.
505 typename U::const_iterator Iter = Dispatch.find(Entry);
506 if (Iter != Dispatch.end())
507 Request.push_back(Iter->second);
508 }
509 }
510
511 LLVM_ABI void addElement(LVElement *Element);
512
513 template <typename T, typename U>
514 void resolveGenericPatternMatch(T *Element, const U &Requests) {
515 assert(Element && "Element must not be nullptr");
516 auto CheckPattern = [this, Element]() -> bool {
517 return (Element->isNamed() &&
518 (matchGenericPattern(Element->getName()) ||
519 matchGenericPattern(Element->getLinkageName()))) ||
520 (Element->isTyped() &&
521 matchGenericPattern(Element->getTypeName()));
522 };
523 auto CheckOffset = [this, Element]() -> bool {
524 return matchOffsetPattern(Element->getOffset());
525 };
526 if ((options().getSelectGenericPattern() && CheckPattern()) ||
527 (options().getSelectOffsetPattern() && CheckOffset()) ||
528 ((Requests.size() || ElementRequest.size()) &&
529 checkElementRequest(Element, Requests)))
530 addElement(Element);
531 }
532
533 template <typename U>
534 void resolveGenericPatternMatch(LVLine *Line, const U &Requests) {
535 assert(Line && "Line must not be nullptr");
536 auto CheckPattern = [this, Line]() -> bool {
537 return matchGenericPattern(Line->lineNumberAsStringStripped()) ||
538 matchGenericPattern(Line->getName()) ||
539 matchGenericPattern(Line->getPathname());
540 };
541 auto CheckOffset = [this, Line]() -> bool {
542 return matchOffsetPattern(Line->getAddress());
543 };
544 if ((options().getSelectGenericPattern() && CheckPattern()) ||
545 (options().getSelectOffsetPattern() && CheckOffset()) ||
546 (Requests.size() && checkElementRequest(Line, Requests)))
547 addElement(Line);
548 }
549
550 Error createMatchEntry(LVMatchInfo &Filters, StringRef Pattern,
551 bool IgnoreCase, bool UseRegex);
552
553public:
555
557 ElementDispatch = LVElement::getDispatch();
558 LineDispatch = LVLine::getDispatch();
559 ScopeDispatch = LVScope::getDispatch();
560 SymbolDispatch = LVSymbol::getDispatch();
561 TypeDispatch = LVType::getDispatch();
562 }
563 LVPatterns(const LVPatterns &) = delete;
564 LVPatterns &operator=(const LVPatterns &) = delete;
565 ~LVPatterns() = default;
566
567 // Clear any existing patterns.
568 void clear() {
569 GenericMatchInfo.clear();
570 OffsetMatchInfo.clear();
571 ElementRequest.clear();
572 LineRequest.clear();
573 ScopeRequest.clear();
574 SymbolRequest.clear();
575 TypeRequest.clear();
576
577 options().resetSelectGenericKind();
578 options().resetSelectGenericPattern();
579 options().resetSelectOffsetPattern();
580 }
581
583 addRequest(Selection, ElementDispatch, ElementRequest);
584 }
586 addRequest(Selection, LineDispatch, LineRequest);
587 }
589 addRequest(Selection, ScopeDispatch, ScopeRequest);
590 }
592 addRequest(Selection, SymbolDispatch, SymbolRequest);
593 }
595 addRequest(Selection, TypeDispatch, TypeRequest);
596 }
597
599
600 LLVM_ABI bool matchPattern(StringRef Input, const LVMatchInfo &MatchInfo);
601 // Match a pattern (--select='pattern').
603 return matchPattern(Input, GenericMatchInfo);
604 }
606 return llvm::is_contained(OffsetMatchInfo, Offset);
607 }
608
610 resolveGenericPatternMatch(Line, LineRequest);
611 }
612
614 resolveGenericPatternMatch(Scope, ScopeRequest);
615 }
616
618 resolveGenericPatternMatch(Symbol, SymbolRequest);
619 }
620
622 resolveGenericPatternMatch(Type, TypeRequest);
623 }
624
625 LLVM_ABI void addPatterns(StringSet<> &Patterns, LVMatchInfo &Filters);
626
627 // Add generic and offset patterns info.
629 LLVM_ABI void addOffsetPatterns(const LVOffsetSet &Patterns);
630
631 // Conditions to print an object.
632 LLVM_ABI bool printElement(const LVLine *Line) const;
633 LLVM_ABI bool printObject(const LVLocation *Location) const;
634 LLVM_ABI bool printElement(const LVScope *Scope) const;
635 LLVM_ABI bool printElement(const LVSymbol *Symbol) const;
636 LLVM_ABI bool printElement(const LVType *Type) const;
637
638 LLVM_ABI void print(raw_ostream &OS) const;
639
640#if !defined(NDEBUG) || defined(LLVM_ENABLE_DUMP)
641 void dump() const { print(dbgs()); }
642#endif
643};
644
646
647} // namespace logicalview
648} // namespace llvm
649
650#endif // LLVM_DEBUGINFO_LOGICALVIEW_CORE_LVOPTIONS_H
@ Generic
assert(UImm &&(UImm !=~static_cast< T >(0)) &&"Invalid immediate!")
amdgpu AMDGPU DAG DAG Pattern Instruction Selection
#define LLVM_ABI
Definition: Compiler.h:213
uint32_t Index
static LVOptions Options
Definition: LVOptions.cpp:25
static bool Execute(ProcessInfo &PI, StringRef Program, ArrayRef< StringRef > Args, std::optional< ArrayRef< StringRef > > Env, ArrayRef< std::optional< StringRef > > Redirects, unsigned MemoryLimit, std::string *ErrMsg, BitVector *AffinityMask, bool DetachProcess)
raw_pwrite_stream & OS
StringSet - A set-like wrapper for the StringMap.
This class represents an incoming formal argument to a Function.
Definition: Argument.h:32
Lightweight error class with error context and mandatory checking.
Definition: Error.h:159
Wrapper class representing virtual and physical registers.
Definition: Register.h:19
StringRef - Represent a constant reference to a string, i.e.
Definition: StringRef.h:55
StringSet - A wrapper for StringMap that provides set-like functionality.
Definition: StringSet.h:25
The instances of the Type class are immutable: once they are created, they are never changed.
Definition: Type.h:45
static LVElementDispatch & getDispatch()
Definition: LVElement.h:377
static LVLineDispatch & getDispatch()
Definition: LVLine.h:88
size_t indentationSize() const
Definition: LVOptions.h:313
LVOptions & operator=(const LVOptions &)=default
BOOL_FUNCTION(Attribute, Missing)
LVSortMode getSortMode() const
Definition: LVOptions.h:385
ATTRIBUTE_OPTION(Discriminator)
BOOL_FUNCTION(Select, Execute)
BOOL_FUNCTION(Select, GenericPattern)
static LLVM_ABI void setOptions(LVOptions *Options)
Definition: LVOptions.cpp:27
BOOL_FUNCTION(Select, GenericKind)
LLVM_ABI void resolveDependencies()
Definition: LVOptions.cpp:29
BOOL_FUNCTION(Print, Formatting)
STD_STRING_FUNCTION(Output, Folder)
BOOL_FUNCTION(Compare, Execute)
UNSIGNED_FUNCTION(Output, Level)
BOOL_FUNCTION(Select, OffsetPattern)
BOOL_FUNCTION(Select, UseRegex)
static LLVM_ABI LVOptions * getOptions()
Definition: LVOptions.cpp:26
BOOL_FUNCTION(Print, AnyLine)
BOOL_FUNCTION(Print, SizesSummary)
LLVM_ABI void print(raw_ostream &OS) const
Definition: LVOptions.cpp:284
BOOL_FUNCTION(Report, Execute)
bool changeFilenameIndex(size_t Index)
Definition: LVOptions.h:290
BOOL_FUNCTION(Compare, Context)
BOOL_FUNCTION(Attribute, AnyLocation)
BOOL_FUNCTION(Print, AnyElement)
void setSortMode(LVSortMode SortMode)
Definition: LVOptions.h:386
BOOL_FUNCTION(Report, AnyView)
LVOptions(const LVOptions &)=default
BOOL_FUNCTION(Select, IgnoreCase)
BOOL_FUNCTION(Attribute, Added)
BOOL_FUNCTION(Attribute, AnySource)
BOOL_FUNCTION(General, CollectRanges)
BOOL_FUNCTION(Compare, Print)
BOOL_FUNCTION(Print, Execute)
LLVM_ABI void addGenericPatterns(StringSet<> &Patterns)
Definition: LVOptions.cpp:441
void resolvePatternMatch(LVType *Type)
Definition: LVOptions.h:621
void resolvePatternMatch(LVLine *Line)
Definition: LVOptions.h:609
void addRequest(LVTypeKindSelection &Selection)
Definition: LVOptions.h:594
bool matchOffsetPattern(LVOffset Offset)
Definition: LVOptions.h:605
void resolvePatternMatch(LVScope *Scope)
Definition: LVOptions.h:613
LLVM_ABI bool matchPattern(StringRef Input, const LVMatchInfo &MatchInfo)
Definition: LVOptions.cpp:507
void addRequest(LVElementKindSet &Selection)
Definition: LVOptions.h:582
void addRequest(LVLineKindSet &Selection)
Definition: LVOptions.h:585
LLVM_ABI bool printObject(const LVLocation *Location) const
Definition: LVOptions.cpp:539
LLVM_ABI void print(raw_ostream &OS) const
Definition: LVOptions.cpp:577
LLVM_ABI bool printElement(const LVLine *Line) const
Definition: LVOptions.cpp:534
LVPatterns(const LVPatterns &)=delete
LLVM_ABI void addPatterns(StringSet<> &Patterns, LVMatchInfo &Filters)
Definition: LVOptions.cpp:457
LLVM_ABI void updateReportOptions()
Definition: LVOptions.cpp:491
bool matchGenericPattern(StringRef Input)
Definition: LVOptions.h:602
LLVM_ABI void addOffsetPatterns(const LVOffsetSet &Patterns)
Definition: LVOptions.cpp:449
void resolvePatternMatch(LVSymbol *Symbol)
Definition: LVOptions.h:617
void addRequest(LVSymbolKindSet &Selection)
Definition: LVOptions.h:591
LVPatterns & operator=(const LVPatterns &)=delete
void addRequest(LVScopeKindSet &Selection)
Definition: LVOptions.h:588
static LLVM_ABI LVPatterns * getPatterns()
Definition: LVOptions.cpp:405
static LVScopeDispatch & getDispatch()
Definition: LVScope.h:322
static LVSymbolDispatch & getDispatch()
Definition: LVSymbol.h:161
static LVTypeDispatch & getDispatch()
Definition: LVType.h:123
This class implements an extremely fast bulk output stream that can only output to a stream.
Definition: raw_ostream.h:53
std::set< LVPrintKind > LVPrintKindSet
Definition: LVOptions.h:163
std::set< LVLineKind > LVLineKindSet
Definition: LVLine.h:36
std::vector< LVSymbolGetFunction > LVSymbolRequest
Definition: LVSymbol.h:35
bool(LVElement::*)() const LVElementGetFunction
Definition: LVObject.h:65
std::set< LVScopeKind > LVScopeKindSet
Definition: LVScope.h:64
void setOptions(LVOptions *Options)
Definition: LVOptions.h:449
std::set< LVTypeKind > LVTypeKindSelection
Definition: LVType.h:47
std::set< LVElementKind > LVElementKindSet
Definition: LVElement.h:67
std::set< uint64_t > LVOffsetSet
Definition: LVOptions.h:91
std::set< LVOutputKind > LVOutputKindSet
Definition: LVOptions.h:149
LVPatterns & patterns()
Definition: LVOptions.h:645
std::map< LVScopeKind, LVScopeGetFunction > LVScopeDispatch
Definition: LVScope.h:65
std::set< LVWarningKind > LVWarningKindSet
Definition: LVOptions.h:181
std::set< LVReportKind > LVReportKindSet
Definition: LVOptions.h:172
std::vector< LVLineGetFunction > LVLineRequest
Definition: LVLine.h:38
std::set< LVSymbolKind > LVSymbolKindSet
Definition: LVSymbol.h:33
std::vector< LVScopeGetFunction > LVScopeRequest
Definition: LVScope.h:66
std::map< LVLineKind, LVLineGetFunction > LVLineDispatch
Definition: LVLine.h:37
std::set< LVInternalKind > LVInternalKindSet
Definition: LVOptions.h:191
std::set< LVAttributeKind > LVAttributeKindSet
Definition: LVOptions.h:132
std::map< LVSymbolKind, LVSymbolGetFunction > LVSymbolDispatch
Definition: LVSymbol.h:34
std::vector< LVElementGetFunction > LVElementRequest
Definition: LVElement.h:69
std::map< LVElementKind, LVElementGetFunction > LVElementDispatch
Definition: LVElement.h:68
LVOptions & options()
Definition: LVOptions.h:448
std::set< LVCompareKind > LVCompareKindSet
Definition: LVOptions.h:141
std::map< LVTypeKind, LVTypeGetFunction > LVTypeDispatch
Definition: LVType.h:48
std::vector< LVTypeGetFunction > LVTypeRequest
Definition: LVType.h:49
This is an optimization pass for GlobalISel generic memory operations.
Definition: AddressRanges.h:18
@ None
Definition: CodeGenData.h:107
LLVM_ABI raw_ostream & dbgs()
dbgs() - This returns a reference to a raw_ostream for debugging messages.
Definition: Debug.cpp:207
bool is_contained(R &&Range, const E &Element)
Returns true if Element is found in Range.
Definition: STLExtras.h:1916