|
reference, declaration → definition
definition → references, declarations, derived classes, virtual overrides
reference to multiple definitions → definitions
unreferenced
|
Derived Classes
include/llvm/Support/Error.h 324 class ErrorSuccess final : public Error {};
include/llvm/Support/MSVCErrorWorkarounds.h 27 class MSVCPError : public Error {
tools/llvm-mca/CodeRegion.h 82 class CodeRegionParseError final : public Error {};
Declarations
include/llvm/DebugInfo/DWARF/DWARFDebugAddr.h 23 class Error;
include/llvm/DebugInfo/DWARF/DWARFDebugRnglists.h 24 class Error;
include/llvm/IR/GVMaterializer.h 24 class Error;
include/llvm/IR/GlobalValue.h 36 class Error;
include/llvm/IR/Module.h 44 class Error;
include/llvm/LTO/Config.h 26 class Error;
include/llvm/LTO/LTO.h 36 class Error;
include/llvm/LTO/LTOBackend.h 30 class Error;
include/llvm/Linker/IRMover.h 17 class Error;
include/llvm/Support/Compression.h 20 class Error;
include/llvm/Support/FormatVariadicDetails.h 19 class Error;
include/llvm/TextAPI/ELF/TBEHandler.h 25 class Error;
lib/Bitcode/Reader/MetadataLoader.h 26 class Error;
tools/lld/include/lld/Common/LLVM.h 27 class Error;
tools/lldb/include/lldb/Host/LZMA.h 15 class Error;
tools/llvm-objcopy/COFF/COFFObjcopy.h 13 class Error;
tools/llvm-objcopy/ELF/ELFObjcopy.h 13 class Error;
tools/llvm-objcopy/MachO/MachOObjcopy.h 13 class Error;
tools/llvm-objcopy/MachO/MachOWriter.h 17 class Error;
References
examples/Kaleidoscope/BuildingAJIT/Chapter1/KaleidoscopeJIT.h 71 Error addModule(std::unique_ptr<Module> M) {
examples/Kaleidoscope/BuildingAJIT/Chapter2/KaleidoscopeJIT.h 78 Error addModule(std::unique_ptr<Module> M) {
examples/Kaleidoscope/BuildingAJIT/Chapter3/KaleidoscopeJIT.h 106 else if (auto Err = Sym.takeError())
examples/Kaleidoscope/BuildingAJIT/Chapter4/KaleidoscopeJIT.h 99 else if (auto Err = Sym.takeError())
136 Error addFunctionAST(std::unique_ptr<FunctionAST> FnAST) {
163 if (auto Err = IndirectStubsMgr->updatePointer(
185 if (auto Err = IndirectStubsMgr->createStub(
189 return Error::success();
examples/Kaleidoscope/BuildingAJIT/Chapter5/KaleidoscopeJIT.h 106 else if (auto Err = Sym.takeError())
149 Error addFunctionAST(std::unique_ptr<FunctionAST> FnAST) {
176 if (auto Err = IndirectStubsMgr->updatePointer(
198 if (auto Err = IndirectStubsMgr->createStub(
202 return Error::success();
205 Error executeRemoteExpr(JITTargetAddress ExprAddr) {
examples/Kaleidoscope/BuildingAJIT/Chapter5/RemoteJITUtils.h 33 llvm::Error readBytes(char *Dst, unsigned Size) override {
48 return llvm::Error::success();
51 llvm::Error appendBytes(const char *Src, unsigned Size) override {
66 return llvm::Error::success();
69 llvm::Error send() override { return llvm::Error::success(); }
69 llvm::Error send() override { return llvm::Error::success(); }
examples/SpeculativeJIT/SpeculativeJIT.cpp 79 Error addModule(JITDylib &JD, ThreadSafeModule TSM) {
include/llvm/ADT/FunctionExtras.h 52 static constexpr bool value = sizeof(T) <= (2 * sizeof(void *));
74 using CallPtrT = ReturnT (*)(void *CallableAddr,
75 AdjustedParamT<ParamTs>... Params);
156 static ReturnT CallImpl(void *CallableAddr, AdjustedParamT<ParamTs>... Params) {
156 static ReturnT CallImpl(void *CallableAddr, AdjustedParamT<ParamTs>... Params) {
158 std::forward<ParamTs>(Params)...);
276 ReturnT operator()(ParamTs... Params) {
276 ReturnT operator()(ParamTs... Params) {
include/llvm/ADT/Optional.h 39 T value;
72 T &getValue() LLVM_LVALUE_FUNCTION noexcept {
76 T const &getValue() const LLVM_LVALUE_FUNCTION noexcept {
81 T &&getValue() && noexcept {
89 ::new ((void *)std::addressof(value)) T(std::forward<Args>(args)...);
106 ::new ((void *)std::addressof(value)) T(std::move(y));
216 optional_detail::OptionalStorage<T> Storage;
219 using value_type = T;
224 Optional(const T &y) : Storage(optional_detail::in_place_t{}, y) {}
227 Optional(T &&y) : Storage(optional_detail::in_place_t{}, std::move(y)) {}
230 Optional &operator=(T &&y) {
241 static inline Optional create(const T *y) {
245 Optional &operator=(const T &y) {
253 const T *getPointer() const { return &Storage.getValue(); }
254 T *getPointer() { return &Storage.getValue(); }
255 const T &getValue() const LLVM_LVALUE_FUNCTION { return Storage.getValue(); }
256 T &getValue() LLVM_LVALUE_FUNCTION { return Storage.getValue(); }
260 const T *operator->() const { return getPointer(); }
261 T *operator->() { return getPointer(); }
262 const T &operator*() const LLVM_LVALUE_FUNCTION { return getValue(); }
263 T &operator*() LLVM_LVALUE_FUNCTION { return getValue(); }
266 constexpr T getValueOr(U &&value) const LLVM_LVALUE_FUNCTION {
271 T &&getValue() && { return std::move(Storage.getValue()); }
272 T &&operator*() && { return std::move(Storage.getValue()); }
275 T getValueOr(U &&value) && {
include/llvm/ADT/STLExtras.h 108 Ret (*callback)(intptr_t callable, Params ...params) = nullptr;
108 Ret (*callback)(intptr_t callable, Params ...params) = nullptr;
112 static Ret callback_fn(intptr_t callable, Params ...params) {
112 static Ret callback_fn(intptr_t callable, Params ...params) {
114 std::forward<Params>(params)...);
129 Ret operator()(Params ...params) const {
129 Ret operator()(Params ...params) const {
130 return callback(callable, std::forward<Params>(params)...);
1002 std::is_same<T, U>::value || is_one_of<T, Ts...>::value;
1002 std::is_same<T, U>::value || is_one_of<T, Ts...>::value;
include/llvm/ADT/fallible_iterator.h 84 static fallible_iterator itr(Underlying I, Error &Err) {
129 if (auto Err = I.inc())
145 if (auto Err = I.dec())
197 fallible_iterator(Underlying I, Error *Err)
200 Error *getErrPtr() const { return ErrState.getPointer(); }
206 void handleError(Error Err) {
213 *getErrPtr() = Error::success();
217 mutable PointerIntPair<Error *, 1> ErrState;
223 fallible_iterator<Underlying> make_fallible_itr(Underlying I, Error &Err) {
236 make_fallible_range(Underlying I, Underlying E, Error &Err) {
include/llvm/ADT/iterator_range.h 38 iterator_range(Container &&c)
include/llvm/Bitcode/BitcodeAnalyzer.h 87 Error analyze(Optional<BCDumpOptions> O = None,
94 Error parseBlock(unsigned BlockID, unsigned IndentLevel,
98 Error decodeMetadataStringsBlob(StringRef Indent, ArrayRef<uint64_t> Record,
include/llvm/Bitcode/BitcodeReader.h 38 std::error_code errorToErrorCodeAndEmitErrors(LLVMContext &Ctx, Error Err);
114 Error readSummary(ModuleSummaryIndex &CombinedIndex, StringRef ModulePath,
177 Error readModuleSummaryIndex(MemoryBufferRef Buffer,
include/llvm/Bitstream/BitstreamReader.h 130 Error JumpToBit(uint64_t BitNo) {
142 return Error::success();
147 return Error::success();
163 Error fillCurWord() {
186 return Error::success();
211 if (Error fillResult = fillCurWord())
427 if (Error Err = ReadAbbrevRecord())
450 if (Error Err = SkipBlock())
465 Error SkipBlock() {
490 if (Error Res = JumpToBit(SkipTo))
493 return Error::success();
497 Error EnterSubBlock(unsigned BlockID, unsigned *NumWordsP = nullptr);
541 Error ReadAbbrevRecord();
include/llvm/DebugInfo/CodeView/CVRecord.h 72 Error forEachCodeViewRecord(ArrayRef<uint8_t> StreamBuffer, Func F) {
88 if (auto EC = F(R))
91 return Error::success();
102 if (auto EC = Reader.readObject(Prefix))
109 if (auto EC = Reader.readBytes(RawData, Prefix->RecordLen + sizeof(uint16_t)))
118 Error operator()(BinaryStreamRef Stream, uint32_t &Len,
125 return Error::success();
include/llvm/DebugInfo/CodeView/CVSymbolVisitor.h 26 Error visitSymbolRecord(CVSymbol &Record);
27 Error visitSymbolRecord(CVSymbol &Record, uint32_t Offset);
28 Error visitSymbolStream(const CVSymbolArray &Symbols);
29 Error visitSymbolStream(const CVSymbolArray &Symbols, uint32_t InitialOffset);
include/llvm/DebugInfo/CodeView/CVTypeVisitor.h 30 Error visitTypeRecord(CVType &Record, TypeIndex Index,
33 Error visitTypeRecord(CVType &Record, TypeVisitorCallbacks &Callbacks,
36 Error visitMemberRecord(CVMemberRecord Record, TypeVisitorCallbacks &Callbacks,
38 Error visitMemberRecord(TypeLeafKind Kind, ArrayRef<uint8_t> Record,
41 Error visitMemberRecordStream(ArrayRef<uint8_t> FieldList,
44 Error visitTypeStream(const CVTypeArray &Types, TypeVisitorCallbacks &Callbacks,
46 Error visitTypeStream(CVTypeRange Types, TypeVisitorCallbacks &Callbacks);
47 Error visitTypeStream(TypeCollection &Types, TypeVisitorCallbacks &Callbacks);
include/llvm/DebugInfo/CodeView/CodeViewRecordIO.h 63 Error beginRecord(Optional<uint32_t> MaxLength);
64 Error endRecord();
66 Error mapInteger(TypeIndex &TypeInd, const Twine &Comment = "");
80 template <typename T> Error mapObject(T &Value) {
86 return Error::success();
93 if (auto EC = Reader->readObject(ValuePtr))
96 return Error::success();
99 template <typename T> Error mapInteger(T &Value, const Twine &Comment = "") {
104 return Error::success();
113 template <typename T> Error mapEnum(T &Value, const Twine &Comment = "") {
123 if (auto EC = mapInteger(X, Comment))
129 return Error::success();
132 Error mapEncodedInteger(int64_t &Value, const Twine &Comment = "");
133 Error mapEncodedInteger(uint64_t &Value, const Twine &Comment = "");
134 Error mapEncodedInteger(APSInt &Value, const Twine &Comment = "");
135 Error mapStringZ(StringRef &Value, const Twine &Comment = "");
136 Error mapGuid(GUID &Guid, const Twine &Comment = "");
138 Error mapStringZVectorZ(std::vector<StringRef> &Value,
142 Error mapVectorN(T &Items, const ElementMapper &Mapper,
152 if (auto EC = Mapper(*this, X))
157 if (auto EC = Writer->writeInteger(Size))
161 if (auto EC = Mapper(*this, X))
165 if (auto EC = Reader->readInteger(Size))
169 if (auto EC = Mapper(*this, Item))
175 return Error::success();
179 Error mapVectorTail(T &Items, const ElementMapper &Mapper,
184 if (auto EC = Mapper(*this, Item))
191 if (auto EC = Mapper(*this, Field))
196 return Error::success();
199 Error mapByteVectorTail(ArrayRef<uint8_t> &Bytes, const Twine &Comment = "");
200 Error mapByteVectorTail(std::vector<uint8_t> &Bytes,
203 Error padToAlignment(uint32_t Align);
204 Error skipPadding();
222 Error writeEncodedSignedInteger(const int64_t &Value);
223 Error writeEncodedUnsignedInteger(const uint64_t &Value);
include/llvm/DebugInfo/CodeView/DebugChecksumsSubsection.h 43 Error operator()(BinaryStreamRef Stream, uint32_t &Len,
63 Error initialize(BinaryStreamReader Reader);
64 Error initialize(BinaryStreamRef Stream);
87 Error commit(BinaryStreamWriter &Writer) const override;
include/llvm/DebugInfo/CodeView/DebugCrossExSubsection.h 36 Error initialize(BinaryStreamReader Reader);
37 Error initialize(BinaryStreamRef Stream);
58 Error commit(BinaryStreamWriter &Writer) const override;
include/llvm/DebugInfo/CodeView/DebugCrossImpSubsection.h 39 Error operator()(BinaryStreamRef Stream, uint32_t &Len,
59 Error initialize(BinaryStreamReader Reader);
60 Error initialize(BinaryStreamRef Stream);
83 Error commit(BinaryStreamWriter &Writer) const override;
include/llvm/DebugInfo/CodeView/DebugFrameDataSubsection.h 28 Error initialize(BinaryStreamReader Reader);
29 Error initialize(BinaryStreamRef Stream);
51 Error commit(BinaryStreamWriter &Writer) const override;
include/llvm/DebugInfo/CodeView/DebugInlineeLinesSubsection.h 53 Error operator()(BinaryStreamRef Stream, uint32_t &Len,
72 Error initialize(BinaryStreamReader Reader);
73 Error initialize(BinaryStreamRef Section) {
102 Error commit(BinaryStreamWriter &Writer) const override;
include/llvm/DebugInfo/CodeView/DebugLinesSubsection.h 72 Error operator()(BinaryStreamRef Stream, uint32_t &Len,
91 Error initialize(BinaryStreamReader Reader);
129 Error commit(BinaryStreamWriter &Writer) const override;
include/llvm/DebugInfo/CodeView/DebugStringTableSubsection.h 39 Error initialize(BinaryStreamRef Contents);
40 Error initialize(BinaryStreamReader &Reader);
74 Error commit(BinaryStreamWriter &Writer) const override;
include/llvm/DebugInfo/CodeView/DebugSubsection.h 41 virtual Error commit(BinaryStreamWriter &Writer) const = 0;
include/llvm/DebugInfo/CodeView/DebugSubsectionRecord.h 41 static Error initialize(BinaryStreamRef Stream, DebugSubsectionRecord &Info,
66 Error commit(BinaryStreamWriter &Writer) const;
81 Error operator()(BinaryStreamRef Stream, uint32_t &Length,
86 if (auto EC = codeview::DebugSubsectionRecord::initialize(
90 return Error::success();
include/llvm/DebugInfo/CodeView/DebugSubsectionVisitor.h 39 virtual Error visitUnknown(DebugUnknownSubsectionRef &Unknown) {
40 return Error::success();
42 virtual Error visitLines(DebugLinesSubsectionRef &Lines,
44 virtual Error visitFileChecksums(DebugChecksumsSubsectionRef &Checksums,
46 virtual Error visitInlineeLines(DebugInlineeLinesSubsectionRef &Inlinees,
48 virtual Error
51 virtual Error
55 virtual Error visitStringTable(DebugStringTableSubsectionRef &ST,
58 virtual Error visitSymbols(DebugSymbolsSubsectionRef &CSE,
61 virtual Error visitFrameData(DebugFrameDataSubsectionRef &FD,
63 virtual Error visitCOFFSymbolRVAs(DebugSymbolRVASubsectionRef &RVAs,
67 Error visitDebugSubsection(const DebugSubsectionRecord &R,
73 Error visitDebugSubsections(T &&FragmentRange, DebugSubsectionVisitor &V,
78 if (auto EC = visitDebugSubsection(L, V, State))
81 return Error::success();
86 Error visitDebugSubsections(T &&FragmentRange, DebugSubsectionVisitor &V) {
93 Error visitDebugSubsections(T &&FragmentRange, DebugSubsectionVisitor &V,
101 Error visitDebugSubsections(T &&FragmentRange, DebugSubsectionVisitor &V,
include/llvm/DebugInfo/CodeView/DebugSymbolRVASubsection.h 39 Error initialize(BinaryStreamReader &Reader);
53 Error commit(BinaryStreamWriter &Writer) const override;
include/llvm/DebugInfo/CodeView/DebugSymbolsSubsection.h 27 Error initialize(BinaryStreamReader Reader);
44 Error commit(BinaryStreamWriter &Writer) const override;
include/llvm/DebugInfo/CodeView/LazyRandomTypeCollection.h 84 Error ensureTypeExists(TypeIndex Index);
87 Error visitRangeForType(TypeIndex TI);
88 Error fullScanForType(TypeIndex TI);
include/llvm/DebugInfo/CodeView/RecordSerialization.h 46 inline Error consume(BinaryStreamReader &Reader) { return Error::success(); }
46 inline Error consume(BinaryStreamReader &Reader) { return Error::success(); }
52 Error consume(BinaryStreamReader &Reader, APSInt &Num);
55 Error consume_numeric(BinaryStreamReader &Reader, uint64_t &Value);
58 Error consume(BinaryStreamReader &Reader, uint32_t &Item);
59 Error consume(BinaryStreamReader &Reader, int32_t &Item);
62 Error consume(BinaryStreamReader &Reader, StringRef &Item);
64 Error consume(StringRef &Data, APSInt &Num);
65 Error consume(StringRef &Data, uint32_t &Item);
69 template <typename T> Error consume(BinaryStreamReader &Reader, T *&Item) {
76 Error deserialize(BinaryStreamReader &Reader) const {
78 return Error::success();
94 Error deserialize(BinaryStreamReader &Reader) const {
105 Error deserialize(BinaryStreamReader &Reader) const {
113 return Error::success();
123 Error deserialize(BinaryStreamReader &Reader) const {
130 if (auto EC = Reader.readCString(Field))
143 Error deserialize(BinaryStreamReader &Reader) const {
154 Error deserialize(BinaryStreamReader &Reader) const {
186 Error consume(BinaryStreamReader &Reader,
192 Error consume(BinaryStreamReader &Reader,
197 inline Error consume(BinaryStreamReader &Reader,
203 Error consume(BinaryStreamReader &Reader,
209 Error consume(BinaryStreamReader &Reader,
215 Error consume(BinaryStreamReader &Reader,
221 Error consume(BinaryStreamReader &Reader, T &&X, U &&Y, Args &&... Rest) {
include/llvm/DebugInfo/CodeView/SymbolDeserializer.h 36 template <typename T> static Error deserializeAs(CVSymbol Symbol, T &Record) {
40 if (auto EC = S.visitSymbolBegin(Symbol))
42 if (auto EC = S.visitKnownRecord(Symbol, Record))
44 if (auto EC = S.visitSymbolEnd(Symbol))
46 return Error::success();
50 if (auto EC = deserializeAs<T>(Symbol, Record))
59 Error visitSymbolBegin(CVSymbol &Record, uint32_t Offset) override {
63 Error visitSymbolBegin(CVSymbol &Record) override {
68 Error visitSymbolEnd(CVSymbol &Record) override {
70 auto EC = Mapping->Mapping.visitSymbolEnd(Record);
83 template <typename T> Error visitKnownRecordImpl(CVSymbol &CVR, T &Record) {
87 if (auto EC = Mapping->Mapping.visitKnownRecord(CVR, Record))
89 return Error::success();
include/llvm/DebugInfo/CodeView/SymbolDumper.h 39 Error dump(CVRecord<SymbolKind> &Record);
43 Error dump(const CVSymbolArray &Symbols);
include/llvm/DebugInfo/CodeView/SymbolRecordMapping.h 29 Error visitSymbolBegin(CVSymbol &Record) override;
30 Error visitSymbolEnd(CVSymbol &Record) override;
include/llvm/DebugInfo/CodeView/SymbolSerializer.h 39 Error writeRecordPrefix(SymbolKind Kind) {
43 if (auto EC = Writer.writeObject(Prefix))
45 return Error::success();
63 Error visitSymbolBegin(CVSymbol &Record) override;
64 Error visitSymbolEnd(CVSymbol &Record) override;
75 Error visitKnownRecordImpl(CVSymbol &CVR, RecordKind &Record) {
include/llvm/DebugInfo/CodeView/SymbolVisitorCallbackPipeline.h 24 Error visitUnknownSymbol(CVSymbol &Record) override {
26 if (auto EC = Visitor->visitUnknownSymbol(Record))
29 return Error::success();
32 Error visitSymbolBegin(CVSymbol &Record, uint32_t Offset) override {
34 if (auto EC = Visitor->visitSymbolBegin(Record, Offset))
37 return Error::success();
40 Error visitSymbolBegin(CVSymbol &Record) override {
42 if (auto EC = Visitor->visitSymbolBegin(Record))
45 return Error::success();
48 Error visitSymbolEnd(CVSymbol &Record) override {
50 if (auto EC = Visitor->visitSymbolEnd(Record))
53 return Error::success();
include/llvm/DebugInfo/CodeView/SymbolVisitorCallbacks.h 25 virtual Error visitUnknownSymbol(CVSymbol &Record) {
26 return Error::success();
32 virtual Error visitSymbolBegin(CVSymbol &Record, uint32_t Offset) {
33 return Error::success();
35 virtual Error visitSymbolBegin(CVSymbol &Record) { return Error::success(); }
35 virtual Error visitSymbolBegin(CVSymbol &Record) { return Error::success(); }
36 virtual Error visitSymbolEnd(CVSymbol &Record) { return Error::success(); }
36 virtual Error visitSymbolEnd(CVSymbol &Record) { return Error::success(); }
include/llvm/DebugInfo/CodeView/TypeDeserializer.h 42 template <typename T> static Error deserializeAs(CVType &CVT, T &Record) {
45 if (auto EC = I.Mapping.visitTypeBegin(CVT))
47 if (auto EC = I.Mapping.visitKnownRecord(CVT, Record))
49 if (auto EC = I.Mapping.visitTypeEnd(CVT))
51 return Error::success();
62 if (auto EC = deserializeAs<T>(CVT, Record))
67 Error visitTypeBegin(CVType &Record) override {
73 Error visitTypeBegin(CVType &Record, TypeIndex Index) override {
77 Error visitTypeEnd(CVType &Record) override {
79 auto EC = Mapping->Mapping.visitTypeEnd(Record);
95 Error visitKnownRecordImpl(CVType &CVR, RecordType &Record) {
125 Error visitMemberBegin(CVMemberRecord &Record) override {
130 Error visitMemberEnd(CVMemberRecord &Record) override {
131 if (auto EC = Mapping.Mapping.visitMemberEnd(Record))
133 return Error::success();
147 Error visitKnownMemberImpl(CVMemberRecord &CVR, RecordType &Record) {
148 if (auto EC = Mapping.Mapping.visitKnownMember(CVR, Record))
154 if (auto EC = Mapping.Reader.readBytes(CVR.Data, RecordLength))
157 return Error::success();
include/llvm/DebugInfo/CodeView/TypeDumpVisitor.h 43 Error visitUnknownType(CVType &Record) override;
44 Error visitUnknownMember(CVMemberRecord &Record) override;
48 Error visitTypeBegin(CVType &Record) override;
49 Error visitTypeBegin(CVType &Record, TypeIndex Index) override;
50 Error visitTypeEnd(CVType &Record) override;
51 Error visitMemberBegin(CVMemberRecord &Record) override;
52 Error visitMemberEnd(CVMemberRecord &Record) override;
include/llvm/DebugInfo/CodeView/TypeRecordMapping.h 30 Error visitTypeBegin(CVType &Record) override;
31 Error visitTypeBegin(CVType &Record, TypeIndex Index) override;
32 Error visitTypeEnd(CVType &Record) override;
34 Error visitMemberBegin(CVMemberRecord &Record) override;
35 Error visitMemberEnd(CVMemberRecord &Record) override;
include/llvm/DebugInfo/CodeView/TypeStreamMerger.h 38 Error mergeTypeRecords(MergingTypeTableBuilder &Dest,
63 Error mergeIdRecords(MergingTypeTableBuilder &Dest, ArrayRef<TypeIndex> Types,
82 Error mergeTypeAndIdRecords(MergingTypeTableBuilder &DestIds,
88 Error mergeTypeAndIdRecords(GlobalTypeTableBuilder &DestIds,
95 Error mergeTypeRecords(GlobalTypeTableBuilder &Dest,
101 Error mergeIdRecords(GlobalTypeTableBuilder &Dest, ArrayRef<TypeIndex> Types,
include/llvm/DebugInfo/CodeView/TypeVisitorCallbackPipeline.h 25 Error visitUnknownType(CVRecord<TypeLeafKind> &Record) override {
27 if (auto EC = Visitor->visitUnknownType(Record))
30 return Error::success();
33 Error visitUnknownMember(CVMemberRecord &Record) override {
35 if (auto EC = Visitor->visitUnknownMember(Record))
38 return Error::success();
41 Error visitTypeBegin(CVType &Record) override {
43 if (auto EC = Visitor->visitTypeBegin(Record))
46 return Error::success();
49 Error visitTypeBegin(CVType &Record, TypeIndex Index) override {
51 if (auto EC = Visitor->visitTypeBegin(Record, Index))
54 return Error::success();
57 Error visitTypeEnd(CVType &Record) override {
59 if (auto EC = Visitor->visitTypeEnd(Record))
62 return Error::success();
65 Error visitMemberBegin(CVMemberRecord &Record) override {
67 if (auto EC = Visitor->visitMemberBegin(Record))
70 return Error::success();
73 Error visitMemberEnd(CVMemberRecord &Record) override {
75 if (auto EC = Visitor->visitMemberEnd(Record))
78 return Error::success();
99 template <typename T> Error visitKnownRecordImpl(CVType &CVR, T &Record) {
101 if (auto EC = Visitor->visitKnownRecord(CVR, Record))
104 return Error::success();
108 Error visitKnownMemberImpl(CVMemberRecord &CVMR, T &Record) {
110 if (auto EC = Visitor->visitKnownMember(CVMR, Record))
113 return Error::success();
include/llvm/DebugInfo/CodeView/TypeVisitorCallbacks.h 23 virtual Error visitUnknownType(CVType &Record) { return Error::success(); }
23 virtual Error visitUnknownType(CVType &Record) { return Error::success(); }
31 virtual Error visitTypeBegin(CVType &Record) { return Error::success(); }
31 virtual Error visitTypeBegin(CVType &Record) { return Error::success(); }
32 virtual Error visitTypeBegin(CVType &Record, TypeIndex Index) {
33 return Error::success();
35 virtual Error visitTypeEnd(CVType &Record) { return Error::success(); }
35 virtual Error visitTypeEnd(CVType &Record) { return Error::success(); }
37 virtual Error visitUnknownMember(CVMemberRecord &Record) {
38 return Error::success();
41 virtual Error visitMemberBegin(CVMemberRecord &Record) {
42 return Error::success();
45 virtual Error visitMemberEnd(CVMemberRecord &Record) {
46 return Error::success();
include/llvm/DebugInfo/DWARF/DWARFAcceleratorTable.h 74 virtual Error extract() = 0;
177 Error extract() override;
248 Error extract(const DWARFDataExtractor &AS, uint64_t *Offset);
462 Error extract();
582 Error extract() override;
include/llvm/DebugInfo/DWARF/DWARFContext.h 301 std::function<void(Error)> RecoverableErrorCallback);
348 static ErrorPolicy defaultErrorHandler(Error E);
351 function_ref<ErrorPolicy(Error)> HandleError = defaultErrorHandler,
361 Error loadRegisterInfo(const object::ObjectFile &Obj);
368 static void dumpWarning(Error Warning);
include/llvm/DebugInfo/DWARF/DWARFDataExtractor.h 40 Error *Err = nullptr) const;
include/llvm/DebugInfo/DWARF/DWARFDebugAddr.h 57 Error extract(DWARFDataExtractor Data, uint64_t *OffsetPtr,
59 std::function<void(Error)> WarnCallback);
include/llvm/DebugInfo/DWARF/DWARFDebugFrame.h 72 Error parse(DWARFDataExtractor Data, uint64_t *Offset, uint64_t EndOffset);
include/llvm/DebugInfo/DWARF/DWARFDebugLine.h 140 Error parse(const DWARFDataExtractor &DebugLineData, uint64_t *OffsetPtr,
283 Error parse(
286 std::function<void(Error)> RecoverableErrorCallback,
315 std::function<void(Error)> RecoverableErrorCallback);
338 function_ref<void(Error)> RecoverableErrorCallback,
339 function_ref<void(Error)> UnrecoverableErrorCallback,
347 void skip(function_ref<void(Error)> ErrorCallback);
include/llvm/DebugInfo/DWARF/DWARFDebugRangeList.h 71 Error extract(const DWARFDataExtractor &data, uint64_t *offset_ptr);
include/llvm/DebugInfo/DWARF/DWARFDebugRnglists.h 37 Error extract(DWARFDataExtractor Data, uint64_t End, uint64_t *OffsetPtr);
include/llvm/DebugInfo/DWARF/DWARFListTable.h 49 Error extract(DWARFDataExtractor Data, uint64_t HeaderOffset, uint64_t End,
126 Error extract(DWARFDataExtractor Data, uint64_t *OffsetPtr);
159 Error extractHeaderAndOffsets(DWARFDataExtractor Data, uint64_t *OffsetPtr) {
163 Error extract(DWARFDataExtractor Data, uint64_t *OffsetPtr);
192 Error DWARFListTableBase<DWARFListType>::extract(DWARFDataExtractor Data,
195 if (Error E = extractHeaderAndOffsets(Data, OffsetPtr))
203 if (Error E = CurrentList.extract(Data, getHeaderOffset(), End, OffsetPtr,
213 return Error::success();
217 Error DWARFListType<ListEntryType>::extract(DWARFDataExtractor Data,
229 if (Error E = Entry.extract(Data, End, OffsetPtr))
233 return Error::success();
280 if (Error E =
include/llvm/DebugInfo/DWARF/DWARFUnit.h 326 Error extractRangeList(uint64_t RangeListOffset,
500 Error tryExtractDIEsIfNeeded(bool CUDieOnly);
include/llvm/DebugInfo/GSYM/GsymCreator.h 152 llvm::Error save(StringRef Path, llvm::support::endianness ByteOrder) const;
158 llvm::Error encode(FileWriter &O) const;
201 llvm::Error finalize(llvm::raw_ostream &OS);
include/llvm/DebugInfo/GSYM/GsymReader.h 50 llvm::Error parse();
include/llvm/DebugInfo/GSYM/Header.h 101 llvm::Error checkForError() const;
120 llvm::Error encode(FileWriter &O) const;
include/llvm/DebugInfo/GSYM/InlineInfo.h 119 llvm::Error encode(FileWriter &O, uint64_t BaseAddr) const;
include/llvm/DebugInfo/GSYM/LineTable.h 149 llvm::Error encode(FileWriter &O, uint64_t BaseAddr) const;
include/llvm/DebugInfo/MSF/IMSFFile.h 34 virtual Error setBlockData(uint32_t BlockIndex, uint32_t Offset,
include/llvm/DebugInfo/MSF/MSFBuilder.h 63 Error setBlockMapAddr(uint32_t Addr);
64 Error setDirectoryBlocksHint(ArrayRef<uint32_t> DirBlocks);
84 Error setStreamSize(uint32_t Idx, uint32_t Size);
124 Error allocateBlocks(uint32_t NumBlocks, MutableArrayRef<uint32_t> Blocks);
include/llvm/DebugInfo/MSF/MSFCommon.h 156 Error validateSuperBlock(const SuperBlock &SB);
include/llvm/DebugInfo/MSF/MappedBlockStream.h 63 Error readBytes(uint32_t Offset, uint32_t Size,
65 Error readLongestContiguousChunk(uint32_t Offset,
86 Error readBytes(uint32_t Offset, MutableArrayRef<uint8_t> Buffer);
130 Error readBytes(uint32_t Offset, uint32_t Size,
132 Error readLongestContiguousChunk(uint32_t Offset,
136 Error writeBytes(uint32_t Offset, ArrayRef<uint8_t> Buffer) override;
138 Error commit() override;
include/llvm/DebugInfo/PDB/Native/DbiModuleDescriptor.h 32 static Error initialize(BinaryStreamRef Stream, DbiModuleDescriptor &Info);
60 Error operator()(BinaryStreamRef Stream, uint32_t &Length,
62 if (auto EC = pdb::DbiModuleDescriptor::initialize(Stream, Info))
65 return Error::success();
include/llvm/DebugInfo/PDB/Native/DbiModuleDescriptorBuilder.h 78 Error finalizeMsfLayout();
80 Error commit(BinaryStreamWriter &ModiWriter, const msf::MSFLayout &MsfLayout,
include/llvm/DebugInfo/PDB/Native/DbiModuleList.h 72 Error initialize(BinaryStreamRef ModInfo, BinaryStreamRef FileInfo);
85 Error initializeModInfo(BinaryStreamRef ModInfo);
86 Error initializeFileInfo(BinaryStreamRef FileInfo);
include/llvm/DebugInfo/PDB/Native/DbiStream.h 43 Error reload(PDBFile *Pdb);
94 Error initializeSectionContributionData();
95 Error initializeSectionHeadersData(PDBFile *Pdb);
96 Error initializeSectionMapData();
97 Error initializeOldFpoRecords(PDBFile *Pdb);
98 Error initializeNewFpoRecords(PDBFile *Pdb);
include/llvm/DebugInfo/PDB/Native/DbiStreamBuilder.h 63 Error addDbgStream(pdb::DbgHeaderType Type, ArrayRef<uint8_t> Data);
76 Error addModuleSourceFile(DbiModuleDescriptorBuilder &Module, StringRef File);
79 Error finalizeMsfLayout();
81 Error commit(const msf::MSFLayout &Layout, WritableBinaryStreamRef MsfBuffer);
93 std::function<Error(BinaryStreamWriter &)> WriteFn;
98 Error finalize();
107 Error generateFileInfoSubstream();
include/llvm/DebugInfo/PDB/Native/GSIStreamBuilder.h 50 Error finalizeMsfLayout();
52 Error commit(const msf::MSFLayout &Layout, WritableBinaryStreamRef Buffer);
68 Error commitSymbolRecordStream(WritableBinaryStreamRef Stream);
69 Error commitPublicsHashStream(WritableBinaryStreamRef Stream);
70 Error commitGlobalsHashStream(WritableBinaryStreamRef Stream);
include/llvm/DebugInfo/PDB/Native/GlobalsStream.h 58 Error read(BinaryStreamReader &Reader);
75 Error reload();
include/llvm/DebugInfo/PDB/Native/HashTable.h 31 Error readSparseBitVector(BinaryStreamReader &Stream, SparseBitVector<> &V);
32 Error writeSparseBitVector(BinaryStreamWriter &Writer, SparseBitVector<> &Vec);
119 Error load(BinaryStreamReader &Stream) {
121 if (auto EC = Stream.readObject(H))
132 if (auto EC = readSparseBitVector(Stream, Present))
138 if (auto EC = readSparseBitVector(Stream, Deleted))
145 if (auto EC = Stream.readInteger(Buckets[P].first))
148 if (auto EC = Stream.readObject(Value))
153 return Error::success();
183 Error commit(BinaryStreamWriter &Writer) const {
187 if (auto EC = Writer.writeObject(H))
190 if (auto EC = writeSparseBitVector(Writer, Present))
193 if (auto EC = writeSparseBitVector(Writer, Deleted))
197 if (auto EC = Writer.writeInteger(Entry.first))
199 if (auto EC = Writer.writeObject(Entry.second))
202 return Error::success();
include/llvm/DebugInfo/PDB/Native/InfoStream.h 34 Error reload();
include/llvm/DebugInfo/PDB/Native/InfoStreamBuilder.h 55 Error finalizeMsfLayout();
57 Error commit(const msf::MSFLayout &Layout,
include/llvm/DebugInfo/PDB/Native/InjectedSourceStream.h 27 Error reload(const PDBStringTable &Strings);
include/llvm/DebugInfo/PDB/Native/ModuleDebugStream.h 38 Error reload();
65 Error commit();
71 Error reloadSerialize(BinaryStreamReader &Reader);
include/llvm/DebugInfo/PDB/Native/NamedStreamMap.h 44 Error load(BinaryStreamReader &Stream);
45 Error commit(BinaryStreamWriter &Writer) const;
include/llvm/DebugInfo/PDB/Native/NativeSession.h 34 static Error createFromPdb(std::unique_ptr<MemoryBuffer> MB,
36 static Error createFromExe(StringRef Path,
include/llvm/DebugInfo/PDB/Native/PDBFile.h 72 Error setBlockData(uint32_t BlockIndex, uint32_t Offset,
97 Error parseFileHeaders();
98 Error parseStreamData();
include/llvm/DebugInfo/PDB/Native/PDBFileBuilder.h 45 Error initialize(uint32_t BlockSize);
57 Error commit(StringRef Filename, codeview::GUID *Guid);
60 Error addNamedStream(StringRef Name, StringRef Data);
80 Error finalizeMsfLayout();
include/llvm/DebugInfo/PDB/Native/PDBStringTable.h 35 Error reload(BinaryStreamReader &Reader);
50 Error readHeader(BinaryStreamReader &Reader);
51 Error readStrings(BinaryStreamReader &Reader);
52 Error readHashTable(BinaryStreamReader &Reader);
53 Error readEpilogue(BinaryStreamReader &Reader);
include/llvm/DebugInfo/PDB/Native/PDBStringTableBuilder.h 54 Error commit(BinaryStreamWriter &Writer) const;
60 Error writeHeader(BinaryStreamWriter &Writer) const;
61 Error writeStrings(BinaryStreamWriter &Writer) const;
62 Error writeHashTable(BinaryStreamWriter &Writer) const;
63 Error writeEpilogue(BinaryStreamWriter &Writer) const;
include/llvm/DebugInfo/PDB/Native/PublicsStream.h 31 Error reload();
include/llvm/DebugInfo/PDB/Native/SymbolCache.h 65 if (auto EC =
include/llvm/DebugInfo/PDB/Native/SymbolStream.h 27 Error reload();
38 Error commit();
include/llvm/DebugInfo/PDB/Native/TpiStream.h 39 Error reload();
69 Error commit();
include/llvm/DebugInfo/PDB/Native/TpiStreamBuilder.h 58 Error finalizeMsfLayout();
62 Error commit(const msf::MSFLayout &Layout, WritableBinaryStreamRef Buffer);
69 Error finalize();
include/llvm/DebugInfo/PDB/PDB.h 22 Error loadDataForPDB(PDB_ReaderType Type, StringRef Path,
25 Error loadDataForEXE(PDB_ReaderType Type, StringRef Path,
include/llvm/ExecutionEngine/JITLink/EHFrameSupport.h 25 Error registerEHFrameSection(const void *EHFrameSectionAddr,
29 Error deregisterEHFrameSection(const void *EHFrameSectionAddr,
36 virtual Error registerEHFrames(JITTargetAddress EHFrameSectionAddr,
38 virtual Error deregisterEHFrames(JITTargetAddress EHFrameSectionAddr,
55 Error registerEHFrames(JITTargetAddress EHFrameSectionAddr,
62 Error deregisterEHFrames(JITTargetAddress EHFrameSectionAddr,
include/llvm/ExecutionEngine/JITLink/JITLink.h 912 using LinkGraphPassFunction = std::function<Error(LinkGraph &)>;
992 virtual void notifyFailed(Error Err) = 0;
1029 virtual Error modifyPassConfig(const Triple &TT, PassConfiguration &Config);
1034 Error markAllSymbolsLive(LinkGraph &G);
include/llvm/ExecutionEngine/JITLink/JITLinkMemoryManager.h 61 using FinalizeContinuation = std::function<void(Error)>;
78 virtual Error deallocate() = 0;
include/llvm/ExecutionEngine/JITSymbol.h 230 JITSymbol(Error Err)
287 Error takeError() {
290 return Error::success();
314 Error Err;
include/llvm/ExecutionEngine/Orc/CompileOnDemandLayer.h 235 else if (auto Err = Sym.takeError())
240 Error removeModulesFromBaseLayer(BaseLayerT &BaseLayer) {
242 if (auto Err = BaseLayer.removeModule(BLK))
244 return Error::success();
305 Error addModule(VModuleKey K, std::unique_ptr<Module> M) {
317 Error addExtraModule(VModuleKey K, std::unique_ptr<Module> M) {
325 Error removeModule(VModuleKey K) {
328 auto Err = I->second.removeModulesFromBaseLayer(BaseLayer);
343 else if (auto Err = Sym.takeError())
365 Error updatePointer(std::string FuncName, JITTargetAddress FnBodyAddr) {
376 return Error::success();
383 Error addLogicalModule(LogicalDylib &LD, std::unique_ptr<Module> SrcMPtr) {
407 else if (auto Err = Sym.takeError())
435 if (auto Err = LD.StubsMgr->createStubs(StubInits))
444 return Error::success();
520 else if (auto Err = Sym.takeError())
562 if (auto Err = BaseLayer.addModule(LD.K, std::move(GVsM)))
567 return Error::success();
608 if (auto EC = LD.StubsMgr->updatePointer(FnName, FnBodyAddr))
613 } else if (auto Err = FnBodySym.takeError())
731 if (auto Err = BaseLayer.addModule(std::move(K), std::move(M)))
include/llvm/ExecutionEngine/Orc/Core.h 215 Error notifyResolved(const SymbolMap &Symbols);
227 Error notifyEmitted();
235 Error defineMaterializing(const SymbolFlagsMap &SymbolFlags);
478 void handleFailed(Error Err);
583 Error define(std::unique_ptr<MaterializationUnitType> &&MU);
593 Error define(std::unique_ptr<MaterializationUnitType> &MU);
605 Error remove(const SymbolNameSet &Names);
710 Error defineImpl(MaterializationUnit &MU);
715 Error lodgeQuery(std::shared_ptr<AsynchronousSymbolQuery> &Q,
719 Error lodgeQueryImpl(std::shared_ptr<AsynchronousSymbolQuery> &Q,
734 Error defineMaterializing(const SymbolFlagsMap &SymbolFlags);
743 Error resolve(const SymbolMap &Resolved);
745 Error emit(const SymbolFlagsMap &Emitted);
767 using ErrorReporter = std::function<void(Error)>;
785 template <typename Func> auto runSessionLocked(Func &&F) -> decltype(F()) {
826 void reportError(Error Err) { ReportError(std::move(Err)); }
835 void legacyFailQuery(AsynchronousSymbolQuery &Q, Error Err);
916 static void logErrorsToStdErr(Error Err) {
959 Error JITDylib::define(std::unique_ptr<MaterializationUnitType> &&MU) {
962 if (auto Err = defineImpl(*MU))
970 return Error::success();
975 Error JITDylib::define(std::unique_ptr<MaterializationUnitType> &MU) {
979 if (auto Err = defineImpl(*MU))
987 return Error::success();
include/llvm/ExecutionEngine/Orc/ExecutionUtils.h 115 Error runViaLayer(JITLayerT &JITLayer) const {
127 if (auto Err = CtorDtorSym.takeError())
133 return Error::success();
150 Error run();
235 Error enable(JITDylib &JD, MangleAndInterner &Mangler);
306 Error &Err);
include/llvm/ExecutionEngine/Orc/GlobalMappingLayer.h 55 Error removeModule(ModuleHandleT H) { return BaseLayer.removeModule(H); }
99 Error emitAndFinalize(ModuleHandleT H) {
include/llvm/ExecutionEngine/Orc/IRCompileLayer.h 92 Error addModule(VModuleKey K, std::unique_ptr<Module> M) {
93 if (auto Err = BaseLayer.addObject(std::move(K), Compile(*M)))
97 return Error::success();
101 Error removeModule(VModuleKey K) { return BaseLayer.removeObject(K); }
127 Error emitAndFinalize(VModuleKey K) { return BaseLayer.emitAndFinalize(K); }
include/llvm/ExecutionEngine/Orc/IRTransformLayer.h 78 Error addModule(VModuleKey K, std::unique_ptr<Module> M) {
83 Error removeModule(VModuleKey K) { return BaseLayer.removeModule(K); }
109 Error emitAndFinalize(VModuleKey K) { return BaseLayer.emitAndFinalize(K); }
include/llvm/ExecutionEngine/Orc/IndirectionUtils.h 77 Error Err = Error::success();
77 Error Err = Error::success();
92 if (auto Err = grow())
116 Error &Err)
143 Error grow() {
173 return Error::success();
228 Error Err = Error::success();
228 Error Err = Error::success();
242 Error &Err)
268 virtual Error createStub(StringRef StubName, JITTargetAddress StubAddr,
273 virtual Error createStubs(const StubInitsMap &StubInits) = 0;
284 virtual Error updatePointer(StringRef Name, JITTargetAddress NewAddr) = 0;
295 Error createStub(StringRef StubName, JITTargetAddress StubAddr,
298 if (auto Err = reserveStubs(1))
303 return Error::success();
306 Error createStubs(const StubInitsMap &StubInits) override {
308 if (auto Err = reserveStubs(StubInits.size()))
315 return Error::success();
347 Error updatePointer(StringRef Name, JITTargetAddress NewAddr) override {
357 return Error::success();
361 Error reserveStubs(unsigned NumStubs) {
363 return Error::success();
368 if (auto Err =
374 return Error::success();
include/llvm/ExecutionEngine/Orc/LLJIT.h 71 Error defineAbsolute(StringRef Name, JITEvaluatedSymbol Address);
74 Error addIRModule(JITDylib &JD, ThreadSafeModule TSM);
77 Error addIRModule(ThreadSafeModule TSM) {
82 Error addObjectFile(JITDylib &JD, std::unique_ptr<MemoryBuffer> Obj);
85 Error addObjectFile(std::unique_ptr<MemoryBuffer> Obj) {
112 Error runConstructors() { return CtorRunner.run(); }
115 Error runDestructors() { return DtorRunner.run(); }
128 LLJIT(LLJITBuilderState &S, Error &Err);
132 Error applyDataLayout(Module &M);
168 Error addLazyIRModule(JITDylib &JD, ThreadSafeModule M);
171 Error addLazyIRModule(ThreadSafeModule M) {
178 LLLazyJIT(LLLazyJITBuilderState &S, Error &Err);
201 Error prepareForConstruction();
259 if (auto Err = impl().prepareForConstruction())
262 Error Err = Error::success();
262 Error Err = Error::success();
290 Error prepareForConstruction();
include/llvm/ExecutionEngine/Orc/Layer.h 51 virtual Error add(JITDylib &JD, ThreadSafeModule TSM,
123 virtual Error add(JITDylib &JD, std::unique_ptr<MemoryBuffer> O,
include/llvm/ExecutionEngine/Orc/LazyEmittingLayer.h 59 if (auto Err = this->emitToBaseLayer(B))
65 else if (auto Err = Sym.takeError())
86 Error removeModuleFromBaseLayer(BaseLayerT& BaseLayer) {
88 : Error::success();
127 Error emitToBaseLayer(BaseLayerT &BaseLayer) {
205 Error addModule(VModuleKey K, std::unique_ptr<Module> M) {
209 return Error::success();
216 Error removeModule(VModuleKey K) {
254 Error emitAndFinalize(VModuleKey K) {
include/llvm/ExecutionEngine/Orc/LazyReexports.h 47 virtual Error operator()(JITDylib &SourceJD,
60 Error operator()(JITDylib &SourceJD, const SymbolStringPtr &SymbolName,
117 template <typename ORCABI> Error init() {
127 return Error::success();
139 if (auto Err = LLCTM->init<ORCABI>())
include/llvm/ExecutionEngine/Orc/Legacy.h 125 } else if (auto Err = Sym.takeError())
158 } else if (auto Err = Sym.takeError()) {
176 using ErrorReporter = std::function<void(Error)>;
207 std::function<void(Error)> ErrorReporter) {
include/llvm/ExecutionEngine/Orc/ObjectLinkingLayer.h 67 virtual Error notifyEmitted(MaterializationResponsibility &MR) {
68 return Error::success();
70 virtual Error notifyRemovingModule(VModuleKey K) {
71 return Error::success();
73 virtual Error notifyRemovingAllModules() { return Error::success(); }
73 virtual Error notifyRemovingAllModules() { return Error::success(); }
142 Error notifyEmitted(MaterializationResponsibility &MR, AllocPtr Alloc);
144 Error removeModule(VModuleKey K);
145 Error removeAllModules();
160 Error notifyEmitted(MaterializationResponsibility &MR) override;
163 Error notifyRemovingModule(VModuleKey K) override;
164 Error notifyRemovingAllModules() override;
include/llvm/ExecutionEngine/Orc/ObjectTransformLayer.h 69 template <typename ObjectPtr> Error addObject(VModuleKey K, ObjectPtr Obj) {
74 Error removeObject(VModuleKey K) { return BaseLayer.removeObject(K); }
99 Error emitAndFinalize(VModuleKey K) { return BaseLayer.emitAndFinalize(K); }
include/llvm/ExecutionEngine/Orc/OrcABISupport.h 66 static Error emitIndirectStubsBlock(IndirectStubsInfo &StubsInfo,
143 static Error emitIndirectStubsBlock(IndirectStubsInfo &StubsInfo,
169 static Error emitIndirectStubsBlock(IndirectStubsInfo &StubsInfo,
236 static Error emitIndirectStubsBlock(IndirectStubsInfo &StubsInfo,
266 static Error emitIndirectStubsBlock(IndirectStubsInfo &StubsInfo,unsigned MinStubs, void *InitialPtrVal);
309 static Error emitIndirectStubsBlock(IndirectStubsInfo &StubsInfo,unsigned MinStubs, void *InitialPtrVal);
include/llvm/ExecutionEngine/Orc/OrcRemoteTargetClient.h 198 if (auto Err = Client.registerEHFrames(EHFrame.Addr, EHFrame.Size)) {
343 Error createStub(StringRef StubName, JITTargetAddress StubAddr,
345 if (auto Err = reserveStubs(1))
351 Error createStubs(const StubInitsMap &StubInits) override {
352 if (auto Err = reserveStubs(StubInits.size()))
356 if (auto Err = createStubInternal(Entry.first(), Entry.second.first,
360 return Error::success();
384 Error updatePointer(StringRef Name, JITTargetAddress NewAddr) override {
400 Error reserveStubs(unsigned NumStubs) {
402 return Error::success();
420 return Error::success();
423 Error createStubInternal(StringRef StubName, JITTargetAddress InitAddr,
459 if (auto Err = grow())
469 Error grow() {
481 return Error::success();
505 Error Err = Error::success();
505 Error Err = Error::success();
532 Error callVoidVoid(JITTargetAddress Addr) {
543 if (auto Err = callB<mem::CreateRemoteAllocator>(Id))
554 if (auto Err = callB<stubs::CreateIndirectStubsOwner>(Id))
564 if (auto Err = callB<stubs::EmitResolverBlock>())
583 Error terminateSession() { return callB<utils::TerminateSession>(); }
587 Error &Err)
602 Err = Error::success();
608 if (auto Err = callB<eh::RegisterEHFrames>(Addr, Size))
613 if (auto Err = callB<mem::DestroyRemoteAllocator>(Id)) {
623 if (auto Err = callB<stubs::DestroyIndirectStubsOwner>(Id))
647 Error registerEHFrames(JITTargetAddress &RAddr, uint32_t Size) {
664 if (auto Err = callB<mem::SetProtections>(Id, RemoteSegAddr, ProtFlags)) {
672 if (auto Err = callB<mem::WriteMem>(DirectBufferWriter(Src, Addr, Size))) {
679 Error writePointer(JITTargetAddress Addr, JITTargetAddress PtrVal) {
683 static Error doNothing() { return Error::success(); }
683 static Error doNothing() { return Error::success(); }
686 std::function<void(Error)> ReportError;
include/llvm/ExecutionEngine/Orc/OrcRemoteTargetRPCAPI.h 88 static Error serialize(ChannelT &C, const JITSymbolFlags &Flags) {
92 static Error deserialize(ChannelT &C, JITSymbolFlags &Flags) {
95 if (auto Err = deserializeSeq(C, JITFlags, TargetFlags))
99 return Error::success();
114 static Error serialize(ChannelT &C, const remote::DirectBufferWriter &DBW) {
115 if (auto EC = serializeSeq(C, DBW.getDst()))
117 if (auto EC = serializeSeq(C, DBW.getSize()))
122 static Error deserialize(ChannelT &C, remote::DirectBufferWriter &DBW) {
124 if (auto EC = deserializeSeq(C, Dst))
127 if (auto EC = deserializeSeq(C, Size))
include/llvm/ExecutionEngine/Orc/OrcRemoteTargetServer.h 121 Error allocate(void *&Addr, size_t Size, uint32_t Align) {
131 return Error::success();
134 Error setProtections(void *block, unsigned Flags) {
146 static Error doNothing() { return Error::success(); }
146 static Error doNothing() { return Error::success(); }
193 Error handleCallVoidVoid(JITTargetAddress Addr) {
203 return Error::success();
206 Error handleCreateRemoteAllocator(ResourceIdMgr::ResourceId Id) {
213 return Error::success();
216 Error handleCreateIndirectStubsOwner(ResourceIdMgr::ResourceId Id) {
223 return Error::success();
226 Error handleDeregisterEHFrames(JITTargetAddress TAddr, uint32_t Size) {
232 return Error::success();
235 Error handleDestroyRemoteAllocator(ResourceIdMgr::ResourceId Id) {
242 return Error::success();
245 Error handleDestroyIndirectStubsOwner(ResourceIdMgr::ResourceId Id) {
251 return Error::success();
266 if (auto Err =
282 Error handleEmitResolverBlock() {
367 Error handleRegisterEHFrames(JITTargetAddress TAddr, uint32_t Size) {
373 return Error::success();
384 if (auto Err = Allocator.allocate(LocalAllocAddr, Size, Align))
397 Error handleSetProtections(ResourceIdMgr::ResourceId Id,
413 Error handleTerminateSession() {
415 return Error::success();
418 Error handleWriteMem(DirectBufferWriter DBW) {
421 return Error::success();
424 Error handleWritePtr(JITTargetAddress Addr, JITTargetAddress PtrVal) {
430 return Error::success();
include/llvm/ExecutionEngine/Orc/RPCSerialization.h 248 static Error emitSeparator(ChannelT &C) { return Error::success(); }
248 static Error emitSeparator(ChannelT &C) { return Error::success(); }
249 static Error consumeSeparator(ChannelT &C) { return Error::success(); }
249 static Error consumeSeparator(ChannelT &C) { return Error::success(); }
267 static Error serialize(ChannelT &C) { return Error::success(); }
267 static Error serialize(ChannelT &C) { return Error::success(); }
268 static Error deserialize(ChannelT &C) { return Error::success(); }
268 static Error deserialize(ChannelT &C) { return Error::success(); }
276 static Error serialize(ChannelT &C, CArgT &&CArg) {
276 static Error serialize(ChannelT &C, CArgT &&CArg) {
277 return SerializationTraits<ChannelT, ArgT,
278 typename std::decay<CArgT>::type>::
279 serialize(C, std::forward<CArgT>(CArg));
283 static Error deserialize(ChannelT &C, CArgT &CArg) {
283 static Error deserialize(ChannelT &C, CArgT &CArg) {
284 return SerializationTraits<ChannelT, ArgT, CArgT>::deserialize(C, CArg);
284 return SerializationTraits<ChannelT, ArgT, CArgT>::deserialize(C, CArg);
293 static Error serialize(ChannelT &C, CArgT &&CArg,
295 if (auto Err =
299 if (auto Err = SequenceTraits<ChannelT>::emitSeparator(C))
306 static Error deserialize(ChannelT &C, CArgT &CArg,
308 if (auto Err =
311 if (auto Err = SequenceTraits<ChannelT>::consumeSeparator(C))
318 Error serializeSeq(ChannelT &C, ArgTs &&... Args) {
318 Error serializeSeq(ChannelT &C, ArgTs &&... Args) {
319 return SequenceSerialization<ChannelT, typename std::decay<ArgTs>::type...>::
320 serialize(C, std::forward<ArgTs>(Args)...);
324 Error deserializeSeq(ChannelT &C, ArgTs &... Args) {
324 Error deserializeSeq(ChannelT &C, ArgTs &... Args) {
325 return SequenceSerialization<ChannelT, ArgTs...>::deserialize(C, Args...);
329 class SerializationTraits<ChannelT, Error> {
333 std::function<Error(ChannelT &C, const ErrorInfoBase&)>;
336 std::function<Error(ChannelT &C, Error &Err)>;
336 std::function<Error(ChannelT &C, Error &Err)>;
367 if (auto Err = serializeSeq(C, *KeyName))
374 static Error serialize(ChannelT &C, Error &&Err) {
374 static Error serialize(ChannelT &C, Error &&Err) {
389 static Error deserialize(ChannelT &C, Error &Err) {
389 static Error deserialize(ChannelT &C, Error &Err) {
393 if (auto Err = deserializeSeq(C, Key))
398 Err = Error::success();
399 return Error::success();
409 static Error serializeAsStringError(ChannelT &C, const ErrorInfoBase &EIB) {
433 typename SerializationTraits<ChannelT, Error>::WrappedErrorSerializer>
438 typename SerializationTraits<ChannelT, Error>::WrappedErrorDeserializer>
447 SerializationTraits<ChannelT, Error>::template registerErrorType<ErrorInfoT>(
466 if (auto E2 = deserializeSeq(C, Msg))
472 return Error::success();
483 static Error serialize(ChannelT &C, Expected<T2> &&ValOrErr) {
485 if (auto Err = serializeSeq(C, true))
489 if (auto Err = serializeSeq(C, false))
494 static Error deserialize(ChannelT &C, Expected<T2> &ValOrErr) {
497 if (auto Err = deserializeSeq(C, HasValue))
501 Error Err = Error::success();
501 Error Err = Error::success();
502 if (auto E2 = deserializeSeq(C, Err))
505 return Error::success();
514 static Error serialize(ChannelT &C, T2 &&Val) {
521 class SerializationTraits<ChannelT, Expected<T>, Error> {
524 static Error serialize(ChannelT &C, Error &&Err) {
524 static Error serialize(ChannelT &C, Error &&Err) {
533 static Error serialize(ChannelT &C, const std::pair<T3, T4> &V) {
534 if (auto Err = SerializationTraits<ChannelT, T1, T3>::serialize(C, V.first))
539 static Error deserialize(ChannelT &C, std::pair<T3, T4> &V) {
540 if (auto Err =
553 static Error serialize(ChannelT &C, const std::tuple<ArgTs...> &V) {
558 static Error deserialize(ChannelT &C, std::tuple<ArgTs...> &V) {
565 static Error serializeTupleHelper(ChannelT &C, const std::tuple<ArgTs...> &V,
572 static Error deserializeTupleHelper(ChannelT &C, std::tuple<ArgTs...> &V,
584 static Error serialize(ChannelT &C, const std::vector<T> &V) {
585 if (auto Err = serializeSeq(C, static_cast<uint64_t>(V.size())))
589 if (auto Err = serializeSeq(C, E))
592 return Error::success();
596 static Error deserialize(ChannelT &C, std::vector<T> &V) {
601 if (auto Err = deserializeSeq(C, Count))
606 if (auto Err = deserializeSeq(C, E))
609 return Error::success();
617 static Error serialize(ChannelT &C, const std::set<T2> &S) {
618 if (auto Err = serializeSeq(C, static_cast<uint64_t>(S.size())))
622 if (auto Err = SerializationTraits<ChannelT, T, T2>::serialize(C, E))
625 return Error::success();
629 static Error deserialize(ChannelT &C, std::set<T2> &S) {
633 if (auto Err = deserializeSeq(C, Count))
638 if (auto Err = SerializationTraits<ChannelT, T, T2>::deserialize(C, Val))
647 return Error::success();
655 static Error serialize(ChannelT &C, const std::map<K2, V2> &M) {
656 if (auto Err = serializeSeq(C, static_cast<uint64_t>(M.size())))
660 if (auto Err =
663 if (auto Err =
668 return Error::success();
672 static Error deserialize(ChannelT &C, std::map<K2, V2> &M) {
676 if (auto Err = deserializeSeq(C, Count))
681 if (auto Err =
685 if (auto Err =
695 return Error::success();
include/llvm/ExecutionEngine/Orc/RPCUtils.h 147 using Type = RetT(ArgTs...);
150 using ReturnType = RetT;
157 << RPCTypeName<RetT>::getName() << " " << DerivedFunc::getName()
249 using ErrorReturnType = Error;
323 static Error sendResult(ChannelT &C, const FunctionIdT &ResponseId,
330 if (auto Err = C.startSendMessage(ResponseId, SeqNo))
334 if (auto Err =
341 if (auto Err = C.endSendMessage())
347 static Error sendResult(ChannelT &C, const FunctionIdT &ResponseId,
348 SequenceNumberT SeqNo, Error Err) {
351 if (auto Err2 = C.startSendMessage(ResponseId, SeqNo))
353 if (auto Err2 = serializeSeq(C, std::move(Err)))
355 if (auto Err2 = C.endSendMessage())
369 static Error sendResult(ChannelT &C, const FunctionIdT &ResponseId,
372 if (auto Err = ResultOrErr.takeError())
376 if (auto Err = C.startSendMessage(ResponseId, SeqNo))
380 if (auto Err =
386 if (auto Err = C.endSendMessage())
393 static Error sendResult(ChannelT &C, const FunctionIdT &ResponseId,
394 SequenceNumberT SeqNo, Error Err) {
397 if (auto Err2 = C.startSendMessage(ResponseId, SeqNo))
399 if (auto Err2 = C.endSendMessage())
411 Error respond(ChannelT &C, const FunctionIdT &ResponseId,
421 Error respond(ChannelT &C, const FunctionIdT &ResponseId, SequenceNumberT SeqNo,
422 Error Err) {
423 return RespondHelper<SupportsErrorReturn<WireRetT>::value>::
440 using Type = Error;
445 using Type = Error;
450 using Type = Error;
458 class AsyncHandlerTraits<Error(std::function<Error(Expected<ResultT>)>, ArgTs...)> {
458 class AsyncHandlerTraits<Error(std::function<Error(Expected<ResultT>)>, ArgTs...)> {
460 using Type = Error(ArgTs...);
465 class AsyncHandlerTraits<Error(std::function<Error(Error)>, ArgTs...)> {
465 class AsyncHandlerTraits<Error(std::function<Error(Error)>, ArgTs...)> {
465 class AsyncHandlerTraits<Error(std::function<Error(Error)>, ArgTs...)> {
467 using Type = Error(ArgTs...);
468 using ResultType = Error;
472 class AsyncHandlerTraits<ErrorSuccess(std::function<Error(Error)>, ArgTs...)> {
472 class AsyncHandlerTraits<ErrorSuccess(std::function<Error(Error)>, ArgTs...)> {
474 using Type = Error(ArgTs...);
475 using ResultType = Error;
479 class AsyncHandlerTraits<void(std::function<Error(Error)>, ArgTs...)> {
479 class AsyncHandlerTraits<void(std::function<Error(Error)>, ArgTs...)> {
481 using Type = Error(ArgTs...);
482 using ResultType = Error;
486 class AsyncHandlerTraits<Error(ResponseHandlerT, ArgTs...)> :
487 public AsyncHandlerTraits<Error(typename std::decay<ResponseHandlerT>::type,
504 using Type = RetT(ArgTs...);
507 using ReturnType = RetT;
511 static typename WrappedHandlerReturn<RetT>::Type
519 static Error unpackAndRunAsync(HandlerT &Handler, ResponderT &Responder,
529 Error>::type
532 return Error::success();
545 static Error serializeArgs(ChannelT &C, const CArgTs... CArgs) {
551 static Error deserializeArgs(ChannelT &C, std::tuple<CArgTs...> &Args) {
557 static Error deserializeArgsHelper(ChannelT &C, std::tuple<CArgTs...> &Args,
589 : public HandlerTraits<RetT(ArgTs...)> {};
595 : public HandlerTraits<RetT(ArgTs...)> {};
600 template <typename ArgT> class ResponseHandlerArg<Error(Expected<ArgT>)> {
615 using ArgType = Error;
620 using ArgType = Error;
633 virtual Error handleResponse(ChannelT &C) = 0;
639 static Error createAbandonedResponseError() {
652 Error handleResponse(ChannelT &C) override {
656 if (auto Err =
660 if (auto Err = C.endReceiveMessage())
688 Error handleResponse(ChannelT &C) override {
689 if (auto Err = C.endReceiveMessage())
691 return Handler(Error::success());
715 Error handleResponse(ChannelT &C) override {
720 if (auto Err =
724 if (auto Err = C.endReceiveMessage())
732 if (auto Err = Handler(this->createAbandonedResponseError())) {
743 class ResponseHandlerImpl<ChannelT, Error, HandlerT>
750 Error handleResponse(ChannelT &C) override {
751 Error Result = Error::success();
751 Error Result = Error::success();
752 if (auto Err = SerializationTraits<ChannelT, Error, Error>::deserialize(
752 if (auto Err = SerializationTraits<ChannelT, Error, Error>::deserialize(
752 if (auto Err = SerializationTraits<ChannelT, Error, Error>::deserialize(
757 if (auto Err = C.endReceiveMessage()) {
767 if (auto Err = Handler(this->createAbandonedResponseError())) {
780 return std::make_unique<ResponseHandlerImpl<ChannelT, FuncRetT, HandlerT>>(
792 RetT operator()(ArgTs &&... Args) {
804 Error operator()() { return Error::success(); }
804 Error operator()() { return Error::success(); }
813 Error operator()(ArgT &ArgVal, ArgTs &... ArgVals) {
899 std::is_same<decltype(T::serialize(std::declval<ChannelT &>(),
901 Error>::value,
918 std::is_same<decltype(T::deserialize(std::declval<ChannelT &>(),
920 Error>::value,
1002 template <typename Func> Error negotiateFunction(bool Retry = false) {
1012 Error appendCallAsync(HandlerT Handler, const ArgTs &... Args) {
1047 if (auto Err = C.startSendMessage(FnId, SeqNo)) {
1053 if (auto Err = detail::HandlerTraits<typename Func::Type>::serializeArgs(
1060 if (auto Err = C.endSendMessage()) {
1065 return Error::success();
1068 Error sendAppendedCalls() { return C.send(); };
1071 Error callAsync(HandlerT Handler, const ArgTs &... Args) {
1072 if (auto Err = appendCallAsync<Func>(std::move(Handler), Args...))
1078 Error handleOne() {
1081 if (auto Err = C.startReceiveMessage(FnId, SeqNo)) {
1186 Error handleResponse(SequenceNumberT SeqNo) {
1211 if (auto Err = PRHandler->handleResponse(C)) {
1216 return Error::success();
1261 using WrappedHandlerFn = std::function<Error(ChannelT &, SequenceNumberT)>;
1275 if (auto Err =
1286 if (auto Err = Channel.endReceiveMessage())
1309 if (auto Err =
1320 if (auto Err = Channel.endReceiveMessage())
1422 return Error::success();
1463 Error handlerLoop() {
1467 return Error::success();
1512 typename detail::ResultTraits<AltRetT>::ErrorReturnType
1515 using ResultType = typename detail::ResultTraits<AltRetT>::ErrorReturnType;
1516 auto Result = detail::ResultTraits<AltRetT>::createBlankErrorReturnValue();
1516 auto Result = detail::ResultTraits<AltRetT>::createBlankErrorReturnValue();
1522 if (auto Err = this->template appendCallAsync<Func>(
1526 return Error::success();
1534 if (auto Err = this->C.send()) {
1541 if (auto Err = this->handleOne()) {
1559 Error operator()(HandlerT Handler, const ArgTs &... Args) const {
1584 Error call(const AsyncDispatcher &AsyncDispatch, HandlerT Handler,
1640 static Error negotiate(RPCEndpoint &R) {
1641 return Error::success();
1657 static Error negotiate(RPCEndpoint &R) {
1658 if (auto Err = R.template negotiateFunction<Func>())
1678 static Error negotiate(RPCEndpoint &R) {
1679 if (auto Err = APICalls<InnerFuncs...>::negotiate(R))
include/llvm/ExecutionEngine/Orc/RTDyldObjectLinkingLayer.h 117 Error onObjLoad(VModuleKey K, MaterializationResponsibility &R,
124 MaterializationResponsibility &R, Error Err);
156 virtual Error finalize() = 0;
232 Error finalize() override {
268 return Error::success();
276 if (auto Err = this->finalize())
389 Error addObject(VModuleKey K, ObjectPtr ObjBuffer) {
404 return Error::success();
415 Error removeObject(VModuleKey K) {
419 return Error::success();
430 else if (auto Err = Sym.takeError())
460 Error emitAndFinalize(VModuleKey K) {
include/llvm/ExecutionEngine/Orc/RawByteChannel.h 31 virtual Error readBytes(char *Dst, unsigned Size) = 0;
34 virtual Error appendBytes(const char *Src, unsigned Size) = 0;
37 virtual Error send() = 0;
42 Error startSendMessage(const FunctionIdT &FnId, const SequenceIdT &SeqNo) {
44 if (auto Err = serializeSeq(*this, FnId, SeqNo)) {
48 return Error::success();
53 Error endSendMessage() {
55 return Error::success();
61 Error startReceiveMessage(FunctionIdT &FnId, SequenceNumberT &SeqNo) {
63 if (auto Err = deserializeSeq(*this, FnId, SeqNo)) {
67 return Error::success();
72 Error endReceiveMessage() {
74 return Error::success();
98 static Error serialize(ChannelT &C, T V) {
103 static Error deserialize(ChannelT &C, T &V) {
104 if (auto Err = C.readBytes(reinterpret_cast<char *>(&V), sizeof(T)))
107 return Error::success();
116 static Error serialize(ChannelT &C, bool V) {
118 if (auto Err =
121 return Error::success();
124 static Error deserialize(ChannelT &C, bool &V) {
126 if (auto Err = C.readBytes(reinterpret_cast<char *>(&Tmp), 1))
129 return Error::success();
139 static Error serialize(RawByteChannel &C, StringRef S) {
140 if (auto Err = serializeSeq(C, static_cast<uint64_t>(S.size())))
153 static Error serialize(RawByteChannel &C, const char *S) {
165 static Error serialize(RawByteChannel &C, const std::string &S) {
171 static Error deserialize(RawByteChannel &C, std::string &S) {
173 if (auto Err = deserializeSeq(C, Count))
include/llvm/ExecutionEngine/Orc/RemoteObjectLayer.h 53 : public rpc::Function<RemoveObject, Error(ObjHandleT)> {
75 Error(ObjHandleT)> {
95 : public rpc::Function<ReleaseRemoteSymbol, Error(RemoteSymbolId)> {
115 std::function<void(Error)> ReportError)
175 Error teeLog(Error Err) {
175 Error teeLog(Error Err) {
185 Error badRemoteSymbolIdError(RemoteSymbolId Id) {
189 Error badObjectHandleError(ObjHandleT H) {
202 } else if (auto Err = Sym.takeError())
225 std::function<void(Error)> ReportError;
231 if (auto Err = Remote.template callB<ReleaseRemoteSymbol>(Id))
242 Error handleReleaseRemoteSymbol(RemoteSymbolId Id) {
246 return Error::success();
319 std::function<void(Error)> ReportError)
346 Error removeObject(ObjHandleT H) {
365 Error emitAndFinalize(ObjHandleT H) {
432 std::function<void(Error)> ReportError)
489 Error removeObject(ObjHandleT H) {
492 if (auto Err = BaseLayer.removeObject(HI->second))
494 return Error::success();
503 else if (auto Err = Sym.takeError())
514 else if (auto Err = Sym.takeError())
521 Error emitAndFinalize(ObjHandleT H) {
524 if (auto Err = BaseLayer.emitAndFinalize(HI->second))
526 return Error::success();
538 RPCEndpoint &Remote, std::function<void(Error)> ReportError)
549 std::function<void(Error)> ReportError)
include/llvm/ExecutionEngine/Orc/Speculation.h 116 if (auto Err = Result.takeError())
133 Error addSpeculationRuntime(JITDylib &JD, MangleAndInterner &Mangle);
include/llvm/ExecutionEngine/Orc/ThreadSafeModule.h 134 auto withModuleDo(Func &&F) -> decltype(F(std::declval<Module &>())) {
include/llvm/ExecutionEngine/RuntimeDyld.h 275 unique_function<Error(std::unique_ptr<LoadedObjectInfo>,
278 unique_function<void(Error)> OnEmitted);
299 unique_function<Error(std::unique_ptr<RuntimeDyld::LoadedObjectInfo>,
302 unique_function<void(Error)> OnEmitted);
include/llvm/IR/GVMaterializer.h 37 virtual Error materialize(GlobalValue *GV) = 0;
41 virtual Error materializeModule() = 0;
43 virtual Error materializeMetadata() = 0;
include/llvm/IR/GlobalValue.h 525 Error materialize();
include/llvm/IR/Module.h 512 llvm::Error materialize(GlobalValue *GV);
516 llvm::Error materializeAll();
518 llvm::Error materializeMetadata();
include/llvm/IR/RemarkStreamer.h 53 Error setFilter(StringRef Filter);
65 RemarkSetupErrorInfo(Error E) {
78 using RemarkSetupErrorInfo<RemarkSetupFileError>::RemarkSetupErrorInfo;
83 using RemarkSetupErrorInfo<RemarkSetupPatternError>::RemarkSetupErrorInfo;
88 using RemarkSetupErrorInfo<RemarkSetupFormatError>::RemarkSetupErrorInfo;
101 Error setupOptimizationRemarks(LLVMContext &Context, raw_ostream &OS,
include/llvm/LTO/Config.h 205 Error addSaveTemps(std::string OutputFileName,
include/llvm/LTO/LTO.h 284 Error add(std::unique_ptr<InputFile> Obj, ArrayRef<SymbolResolution> Res);
299 Error run(AddStreamFn AddStream, NativeObjectCache Cache = nullptr);
407 Error addModule(InputFile &Input, unsigned ModI,
413 Error linkRegularLTO(RegularLTOState::AddedModule Mod,
416 Error addThinLTO(BitcodeModule BM, ArrayRef<InputFile::Symbol> Syms,
419 Error runRegularLTO(AddStreamFn AddStream);
420 Error runThinLTO(AddStreamFn AddStream, NativeObjectCache Cache,
423 Error checkPartiallySplit();
include/llvm/LTO/LTOBackend.h 38 Error backend(Config &C, AddStreamFn AddStream,
43 Error thinBackend(Config &C, unsigned Task, AddStreamFn AddStream, Module &M,
include/llvm/Linker/IRMover.h 75 Error move(std::unique_ptr<Module> Src, ArrayRef<GlobalValue *> ValuesToLink,
include/llvm/MCA/InstrBuilder.h 59 Error verifyInstrDesc(const InstrDesc &ID, const MCInst &MCI) const;
include/llvm/MCA/Pipeline.h 61 Error runCycle();
include/llvm/MCA/Stages/DispatchStage.h 62 Error dispatch(InstRef IR);
78 Error cycleStart() override;
79 Error execute(InstRef &IR) override;
include/llvm/MCA/Stages/EntryStage.h 43 Error execute(InstRef &IR) override;
44 Error cycleStart() override;
45 Error cycleEnd() override;
include/llvm/MCA/Stages/ExecuteStage.h 37 Error issueInstruction(InstRef &IR);
41 Error issueReadyInstructions();
44 Error handleInstructionEliminated(InstRef &IR);
71 Error cycleStart() override;
72 Error cycleEnd() override;
73 Error execute(InstRef &IR) override;
include/llvm/MCA/Stages/InstructionTables.h 40 Error execute(InstRef &IR) override;
include/llvm/MCA/Stages/MicroOpQueueStage.h 61 Error moveInstructions();
80 Error execute(InstRef &IR) override;
81 Error cycleStart() override;
82 Error cycleEnd() override;
include/llvm/MCA/Stages/RetireStage.h 41 Error cycleStart() override;
42 Error execute(InstRef &IR) override;
include/llvm/MCA/Stages/Stage.h 49 virtual Error cycleStart() { return ErrorSuccess(); }
52 virtual Error cycleEnd() { return ErrorSuccess(); }
55 virtual Error execute(InstRef &IR) = 0;
70 Error moveToTheNextStage(InstRef &IR) {
include/llvm/Object/Archive.h 42 uint64_t Size, Error *Err);
101 Child(const Archive *Parent, const char *Start, Error *Err);
167 Error inc() {
172 return Error::success();
221 Archive(MemoryBufferRef Source, Error &Err);
239 child_iterator child_begin(Error &Err, bool SkipInternal = true) const;
241 iterator_range<child_iterator> children(Error &Err,
include/llvm/Object/ArchiveWriter.h 41 Error writeArchive(StringRef ArcName, ArrayRef<NewArchiveMember> NewMembers,
include/llvm/Object/COFF.h 1017 if (Error E = S.takeError())
1043 Error getSectionContents(const coff_section *Sec,
1210 Error load(const COFFObjectFile *O);
1211 Error load(const COFFObjectFile *O, const SectionRef &S);
include/llvm/Object/COFFImportFile.h 39 Error printSymbolName(raw_ostream &OS, DataRefImpl Symb) const override {
43 return Error::success();
106 Error writeImportLibrary(StringRef ImportName, StringRef Path,
include/llvm/Object/Decompressor.h 32 template <class T> Error resizeAndDecompress(T &Out) {
39 Error decompress(MutableArrayRef<char> Buffer);
56 Error consumeCompressedGnuHeader();
57 Error consumeCompressedZLibHeader(bool Is64Bit, bool IsLittleEndian);
include/llvm/Object/ELF.h 47 static inline Error createError(const Twine &Err) {
67 static inline Error defaultWarningHandler(const Twine &Msg) {
107 using WarningHandler = llvm::function_ref<Error(const Twine &Msg)>;
217 Elf_Note_Iterator notes_begin(const Elf_Phdr &Phdr, Error &Err) const {
236 Elf_Note_Iterator notes_begin(const Elf_Shdr &Shdr, Error &Err) const {
262 Error &Err) const {
274 Error &Err) const {
594 if (Error E = WarnHandler("invalid sh_type for string table section " +
include/llvm/Object/ELFObjectFile.h 67 virtual Error getBuildAttributes(ARMAttributeParser &Attributes) const = 0;
368 Error getBuildAttributes(ARMAttributeParser &Attributes) const override {
381 return Error::success();
387 return Error::success();
948 if (Error E = EFOrErr.takeError())
include/llvm/Object/ELFTypes.h 630 Error *Err = nullptr;
651 *Err = Error::success();
660 *Err = Error::success();
665 explicit Elf_Note_Iterator_Impl(Error &Err) : Err(&Err) {}
666 Elf_Note_Iterator_Impl(const uint8_t *Start, size_t Size, Error &Err)
include/llvm/Object/Error.h 81 Error isNotObjectErrorInvalidFileType(llvm::Error Err);
81 Error isNotObjectErrorInvalidFileType(llvm::Error Err);
include/llvm/Object/IRObjectFile.h 40 Error printSymbolName(raw_ostream &OS, DataRefImpl Symb) const override;
include/llvm/Object/IRSymtab.h 160 Error build(ArrayRef<Module *> Mods, SmallVector<char, 0> &Symtab,
include/llvm/Object/MachO.h 74 ExportEntry(Error *Err, const MachOObjectFile *O, ArrayRef<uint8_t> Trie);
114 Error *E;
169 MachORebaseEntry(Error *Err, const MachOObjectFile *O,
190 Error *E;
215 MachOBindEntry(Error *Err, const MachOObjectFile *O,
242 Error *E;
281 Error checkSymbolTable() const;
380 iterator_range<export_iterator> exports(Error &Err) const;
383 static iterator_range<export_iterator> exports(Error &Err,
389 iterator_range<rebase_iterator> rebaseTable(Error &Err);
392 static iterator_range<rebase_iterator> rebaseTable(Error &Err,
398 iterator_range<bind_iterator> bindTable(Error &Err);
401 iterator_range<bind_iterator> lazyBindTable(Error &Err);
404 iterator_range<bind_iterator> weakBindTable(Error &Err);
407 static iterator_range<bind_iterator> bindTable(Error &Err,
652 Error &Err, uint32_t UniversalCputype = 0,
include/llvm/Object/MachOUniversal.h 139 MachOUniversalBinary(MemoryBufferRef Souce, Error &Err);
include/llvm/Object/Minidump.h 144 static Error createError(StringRef Str) {
148 static Error createEOFError() {
include/llvm/Object/ObjectFile.h 242 Error printSymbolName(raw_ostream &OS,
include/llvm/Object/SymbolicFile.h 129 Error printName(raw_ostream &OS) const;
148 virtual Error printSymbolName(raw_ostream &OS, DataRefImpl Symb) const = 0;
195 inline Error BasicSymbolRef::printName(raw_ostream &OS) const {
include/llvm/Object/TapiFile.h 34 Error printSymbolName(raw_ostream &OS, DataRefImpl DRI) const override;
include/llvm/Object/TapiUniversal.h 82 TapiUniversal(MemoryBufferRef Source, Error &Err);
include/llvm/Object/Wasm.h 121 WasmObjectFile(MemoryBufferRef Object, Error &Err);
233 Error parseSection(WasmSection &Sec);
234 Error parseCustomSection(WasmSection &Sec, ReadContext &Ctx);
237 Error parseTypeSection(ReadContext &Ctx);
238 Error parseImportSection(ReadContext &Ctx);
239 Error parseFunctionSection(ReadContext &Ctx);
240 Error parseTableSection(ReadContext &Ctx);
241 Error parseMemorySection(ReadContext &Ctx);
242 Error parseGlobalSection(ReadContext &Ctx);
243 Error parseEventSection(ReadContext &Ctx);
244 Error parseExportSection(ReadContext &Ctx);
245 Error parseStartSection(ReadContext &Ctx);
246 Error parseElemSection(ReadContext &Ctx);
247 Error parseCodeSection(ReadContext &Ctx);
248 Error parseDataSection(ReadContext &Ctx);
249 Error parseDataCountSection(ReadContext &Ctx);
252 Error parseDylinkSection(ReadContext &Ctx);
253 Error parseNameSection(ReadContext &Ctx);
254 Error parseLinkingSection(ReadContext &Ctx);
255 Error parseLinkingSectionSymtab(ReadContext &Ctx);
256 Error parseLinkingSectionComdat(ReadContext &Ctx);
257 Error parseProducersSection(ReadContext &Ctx);
258 Error parseTargetFeaturesSection(ReadContext &Ctx);
259 Error parseRelocSection(StringRef Name, ReadContext &Ctx);
include/llvm/Object/WindowsResource.h 100 Error moveNext(bool &End);
119 Error loadNext();
157 Error parse(WindowsResource *WR, std::vector<std::string> &Duplicates);
158 Error parse(ResourceSectionRef &RSR, StringRef Filename,
246 Error addChildren(TreeNode &Node, ResourceSectionRef &RSR,
include/llvm/Passes/PassBuilder.h 439 Error parsePassPipeline(ModulePassManager &MPM, StringRef PipelineText,
450 Error parsePassPipeline(CGSCCPassManager &CGPM, StringRef PipelineText,
453 Error parsePassPipeline(FunctionPassManager &FPM, StringRef PipelineText,
456 Error parsePassPipeline(LoopPassManager &LPM, StringRef PipelineText,
476 Error parseAAPipeline(AAManager &AA, StringRef PipelineText);
642 Error parseModulePass(ModulePassManager &MPM, const PipelineElement &E,
644 Error parseCGSCCPass(CGSCCPassManager &CGPM, const PipelineElement &E,
646 Error parseFunctionPass(FunctionPassManager &FPM, const PipelineElement &E,
648 Error parseLoopPass(LoopPassManager &LPM, const PipelineElement &E,
652 Error parseLoopPassPipeline(LoopPassManager &LPM,
655 Error parseFunctionPassPipeline(FunctionPassManager &FPM,
658 Error parseCGSCCPassPipeline(CGSCCPassManager &CGPM,
661 Error parseModulePassPipeline(ModulePassManager &MPM,
include/llvm/ProfileData/Coverage/CoverageMapping.h 522 Error loadFunctionRecord(const CoverageMappingRecord &Record,
713 Error getFuncName(InstrProfSymtab &ProfileNames, StringRef &FuncName) const {
719 return Error::success();
744 Error getFuncName(InstrProfSymtab &ProfileNames, StringRef &FuncName) const {
747 return Error::success();
include/llvm/ProfileData/Coverage/CoverageMappingReader.h 78 auto E = make_error<CoverageMapError>(ReadErr);
86 auto E = make_error<CoverageMapError>(ReadErr);
98 virtual Error readNextRecord(CoverageMappingRecord &Record) = 0;
110 Error readULEB128(uint64_t &Result);
111 Error readIntMax(uint64_t &Result, uint64_t MaxPlus1);
112 Error readSize(uint64_t &Result);
113 Error readString(StringRef &Result);
127 Error read();
161 Error read();
164 Error decodeCounter(unsigned Value, Counter &C);
165 Error readCounter(Counter &C);
166 Error
216 Error readNextRecord(CoverageMappingRecord &Record) override;
include/llvm/ProfileData/InstrProf.h 210 Error collectPGOFuncNameStrings(ArrayRef<std::string> NameStrs,
215 Error collectPGOFuncNameStrings(ArrayRef<GlobalVariable *> NameVars,
221 Error readPGOFuncNameStrings(StringRef NameStrings, InstrProfSymtab &Symtab);
319 static instrprof_error take(Error E) {
380 Error takeError() {
382 return Error::success();
383 auto E = make_error<InstrProfError>(FirstError);
444 Error create(object::SectionRef &Section);
448 inline Error create(StringRef D, uint64_t BaseAddr);
453 inline Error create(StringRef NameStrings);
459 Error create(Module &M, bool InLTO = false);
463 template <typename NameIterRange> Error create(const NameIterRange &IterRange);
467 Error addFuncName(StringRef FuncName) {
476 return Error::success();
519 Error InstrProfSymtab::create(StringRef D, uint64_t BaseAddr) {
522 return Error::success();
525 Error InstrProfSymtab::create(StringRef NameStrings) {
530 Error InstrProfSymtab::create(const NameIterRange &IterRange) {
532 if (Error E = addFuncName(Name))
536 return Error::success();
633 Error accumulateCounts(const std::string &BaseFilename,
include/llvm/ProfileData/InstrProfData.inc 372 Error checkIntegrity();
include/llvm/ProfileData/InstrProfReader.h 69 virtual Error readHeader() = 0;
72 virtual Error readNextRecord(NamedInstrProfRecord &Record) = 0;
101 Error error(instrprof_error Err) {
104 return Error::success();
108 Error error(Error &&E) { return error(InstrProfError::take(std::move(E))); }
108 Error error(Error &&E) { return error(InstrProfError::take(std::move(E))); }
111 Error success() { return error(instrprof_error::success); }
121 Error getError() {
124 return Error::success();
152 Error readValueProfileData(InstrProfRecord &Record);
168 Error readHeader() override;
171 Error readNextRecord(NamedInstrProfRecord &Record) override;
216 Error readHeader() override;
217 Error readNextRecord(NamedInstrProfRecord &Record) override;
233 Error createSymtab(InstrProfSymtab &Symtab);
234 Error readNextHeader(const char *CurrentPos);
235 Error readHeader(const RawInstrProf::Header &Header);
255 Error readName(NamedInstrProfRecord &Record);
256 Error readFuncHash(NamedInstrProfRecord &Record);
257 Error readRawCounts(InstrProfRecord &Record);
258 Error readValueProfilingData(InstrProfRecord &Record);
352 virtual Error getRecords(ArrayRef<NamedInstrProfRecord> &Data) = 0;
355 virtual Error getRecords(StringRef FuncName,
363 virtual Error populateSymtab(InstrProfSymtab &) = 0;
388 Error getRecords(ArrayRef<NamedInstrProfRecord> &Data) override;
389 Error getRecords(StringRef FuncName,
411 Error populateSymtab(InstrProfSymtab &Symtab) override {
420 virtual Error populateRemappings() { return Error::success(); }
420 virtual Error populateRemappings() { return Error::success(); }
421 virtual Error getRecords(StringRef FuncName,
469 Error readHeader() override;
471 Error readNextRecord(NamedInstrProfRecord &Record) override;
478 Error getFunctionCounts(StringRef FuncName, uint64_t FuncHash,
include/llvm/ProfileData/InstrProfWriter.h 54 function_ref<void(Error)> Warn);
55 void addRecord(NamedInstrProfRecord &&I, function_ref<void(Error)> Warn) {
61 function_ref<void(Error)> Warn);
67 Error writeText(raw_fd_ostream &OS);
79 Error setIsIRLevelProfile(bool IsIRLevel, bool WithCS) {
85 return Error::success();
97 return Error::success();
111 uint64_t Weight, function_ref<void(Error)> Warn);
include/llvm/Remarks/BitstreamRemarkParser.h 50 Error parse();
85 Error parse();
100 Error parseBlockInfoBlock();
include/llvm/Support/BinaryByteStream.h 41 Error readBytes(uint32_t Offset, uint32_t Size,
43 if (auto EC = checkOffsetForRead(Offset, Size))
46 return Error::success();
49 Error readLongestContiguousChunk(uint32_t Offset,
51 if (auto EC = checkOffsetForRead(Offset, 1))
54 return Error::success();
100 Error readBytes(uint32_t Offset, uint32_t Size,
105 Error readLongestContiguousChunk(uint32_t Offset,
112 Error writeBytes(uint32_t Offset, ArrayRef<uint8_t> Buffer) override {
114 return Error::success();
116 if (auto EC = checkOffsetForWrite(Offset, Buffer.size()))
121 return Error::success();
124 Error commit() override { return Error::success(); }
124 Error commit() override { return Error::success(); }
148 Error readBytes(uint32_t Offset, uint32_t Size,
150 if (auto EC = checkOffsetForWrite(Offset, Buffer.size()))
154 return Error::success();
161 Error readLongestContiguousChunk(uint32_t Offset,
163 if (auto EC = checkOffsetForWrite(Offset, 1))
167 return Error::success();
172 Error writeBytes(uint32_t Offset, ArrayRef<uint8_t> Buffer) override {
174 return Error::success();
190 return Error::success();
193 Error commit() override { return Error::success(); }
193 Error commit() override { return Error::success(); }
217 Error commit() override {
221 return Error::success();
243 Error readBytes(uint32_t Offset, uint32_t Size,
248 Error readLongestContiguousChunk(uint32_t Offset,
255 Error writeBytes(uint32_t Offset, ArrayRef<uint8_t> Data) override {
259 Error commit() override { return Impl.commit(); }
include/llvm/Support/BinaryItemStream.h 41 Error readBytes(uint32_t Offset, uint32_t Size,
47 if (auto EC = checkOffsetForRead(Offset, Size))
52 return Error::success();
55 Error readLongestContiguousChunk(uint32_t Offset,
61 return Error::success();
include/llvm/Support/BinaryStream.h 44 virtual Error readBytes(uint32_t Offset, uint32_t Size,
49 virtual Error readLongestContiguousChunk(uint32_t Offset,
59 Error checkOffsetForRead(uint32_t Offset, uint32_t DataSize) {
64 return Error::success();
80 virtual Error writeBytes(uint32_t Offset, ArrayRef<uint8_t> Data) = 0;
83 virtual Error commit() = 0;
89 Error checkOffsetForWrite(uint32_t Offset, uint32_t DataSize) {
95 return Error::success();
include/llvm/Support/BinaryStreamArray.h 46 Error operator()(BinaryStreamRef Stream, uint32_t &Len,
164 auto EC = Extract(IterRef, ThisLen, ThisValue);
213 auto EC = Extract(IterRef, ThisLen, ThisValue);
283 if (auto EC = Stream.readBytes(Off, sizeof(T), Data)) {
include/llvm/Support/BinaryStreamReader.h 57 Error readLongestContiguousChunk(ArrayRef<uint8_t> &Buffer);
66 Error readBytes(ArrayRef<uint8_t> &Buffer, uint32_t Size);
75 template <typename T> Error readInteger(T &Dest) {
80 if (auto EC = readBytes(Bytes, sizeof(T)))
85 return Error::success();
89 template <typename T> Error readEnum(T &Dest) {
93 if (auto EC = readInteger(N))
96 return Error::success();
103 Error readULEB128(uint64_t &Dest);
109 Error readSLEB128(int64_t &Dest);
117 Error readCString(StringRef &Dest);
124 Error readWideString(ArrayRef<UTF16> &Dest);
132 Error readFixedString(StringRef &Dest, uint32_t Length);
140 Error readStreamRef(BinaryStreamRef &Ref);
149 Error readStreamRef(BinaryStreamRef &Ref, uint32_t Length);
158 Error readSubstream(BinarySubstreamRef &Stream, uint32_t Size);
169 template <typename T> Error readObject(const T *&Dest) {
171 if (auto EC = readBytes(Buffer, sizeof(T)))
174 return Error::success();
187 Error readArray(ArrayRef<T> &Array, uint32_t NumElements) {
191 return Error::success();
198 if (auto EC = readBytes(Bytes, NumElements * sizeof(T)))
205 return Error::success();
217 Error readArray(VarStreamArray<T, U> &Array, uint32_t Size,
220 if (auto EC = readStreamRef(S, Size))
223 return Error::success();
235 Error readArray(FixedStreamArray<T> &Array, uint32_t NumItems) {
238 return Error::success();
246 if (auto EC = readStreamRef(View, NumItems * sizeof(T)))
250 return Error::success();
263 Error skip(uint32_t Amount);
271 Error padToAlignment(uint32_t Align);
include/llvm/Support/BinaryStreamRef.h 135 Error checkOffsetForRead(uint32_t Offset, uint32_t DataSize) const {
140 return Error::success();
188 Error readBytes(uint32_t Offset, uint32_t Size,
196 Error readLongestContiguousChunk(uint32_t Offset,
230 Error checkOffsetForWrite(uint32_t Offset, uint32_t DataSize) const {
236 return Error::success();
263 Error writeBytes(uint32_t Offset, ArrayRef<uint8_t> Data) const;
269 Error commit();
include/llvm/Support/BinaryStreamWriter.h 56 Error writeBytes(ArrayRef<uint8_t> Buffer);
64 template <typename T> Error writeInteger(T Value) {
74 template <typename T> Error writeEnum(T Num) {
87 Error writeULEB128(uint64_t Value);
94 Error writeSLEB128(int64_t Value);
103 Error writeCString(StringRef Str);
111 Error writeFixedString(StringRef Str);
119 Error writeStreamRef(BinaryStreamRef Ref);
127 Error writeStreamRef(BinaryStreamRef Ref, uint32_t Size);
135 template <typename T> Error writeObject(const T &Obj) {
151 template <typename T> Error writeArray(ArrayRef<T> Array) {
153 return Error::success();
168 Error writeArray(VarStreamArray<T, U> Array) {
176 template <typename T> Error writeArray(FixedStreamArray<T> Array) {
187 Error padToAlignment(uint32_t Align);
include/llvm/Support/Compression.h 32 Error compress(StringRef InputBuffer, SmallVectorImpl<char> &CompressedBuffer,
35 Error uncompress(StringRef InputBuffer, char *UncompressedBuffer,
38 Error uncompress(StringRef InputBuffer,
include/llvm/Support/DataExtractor.h 56 Error Err;
62 explicit Cursor(uint64_t Offset) : Offset(Offset), Err(Error::success()) {}
75 Error takeError() { return std::move(Err); }
175 Error *Err = nullptr) const;
255 uint8_t getU8(uint64_t *offset_ptr, Error *Err = nullptr) const;
329 uint16_t getU16(uint64_t *offset_ptr, Error *Err = nullptr) const;
398 uint32_t getU32(uint64_t *offset_ptr, Error *Err = nullptr) const;
450 uint64_t getU64(uint64_t *offset_ptr, Error *Err = nullptr) const;
522 uint64_t getULEB128(uint64_t *offset_ptr, llvm::Error *Err = nullptr) const;
570 static Error &getError(Cursor &C) { return C.Err; }
include/llvm/Support/Error.h 165 friend Error handleErrors(Error E, HandlerTs &&... Handlers);
165 friend Error handleErrors(Error E, HandlerTs &&... Handlers);
172 friend LLVMErrorRef wrap(Error);
186 Error(const Error &Other) = delete;
191 Error(Error &&Other) {
204 Error &operator=(const Error &Other) = delete;
204 Error &operator=(const Error &Other) = delete;
210 Error &operator=(Error &&Other) {
210 Error &operator=(Error &&Other) {
310 friend raw_ostream &operator<<(raw_ostream &OS, const Error &E) {
324 class ErrorSuccess final : public Error {};
330 template <typename ErrT, typename... ArgTs> Error make_error(ArgTs &&... Args) {
330 template <typename ErrT, typename... ArgTs> Error make_error(ArgTs &&... Args) {
331 return Error(std::make_unique<ErrT>(std::forward<ArgTs>(Args)...));
331 return Error(std::make_unique<ErrT>(std::forward<ArgTs>(Args)...));
363 friend Error handleErrors(Error E, HandlerTs &&... Handlers);
363 friend Error handleErrors(Error E, HandlerTs &&... Handlers);
366 friend Error joinErrors(Error, Error);
366 friend Error joinErrors(Error, Error);
366 friend Error joinErrors(Error, Error);
391 static Error join(Error E1, Error E2) {
391 static Error join(Error E1, Error E2) {
391 static Error join(Error E1, Error E2) {
423 inline Error joinErrors(Error E1, Error E2) {
423 inline Error joinErrors(Error E1, Error E2) {
423 inline Error joinErrors(Error E1, Error E2) {
455 Expected(Error Err)
474 Expected(OtherT &&Val,
475 typename std::enable_if<std::is_convertible<OtherT, T>::value>::type
552 Error takeError() {
556 return HasError ? Error(std::move(*getErrorStorage())) : Error::success();
556 return HasError ? Error(std::move(*getErrorStorage())) : Error::success();
687 LLVM_ATTRIBUTE_NORETURN void report_fatal_error(Error Err,
703 inline void cantFail(Error Err, const char *Msg = nullptr) {
740 auto E = ValOrErr.takeError();
771 auto E = ValOrErr.takeError();
787 template <typename ErrT> class ErrorHandlerTraits<Error (&)(ErrT &)> {
794 static Error apply(HandlerT &&H, std::unique_ptr<ErrorInfoBase> E) {
808 static Error apply(HandlerT &&H, std::unique_ptr<ErrorInfoBase> E) {
811 return Error::success();
817 class ErrorHandlerTraits<Error (&)(std::unique_ptr<ErrT>)> {
824 static Error apply(HandlerT &&H, std::unique_ptr<ErrorInfoBase> E) {
840 static Error apply(HandlerT &&H, std::unique_ptr<ErrorInfoBase> E) {
844 return Error::success();
851 : public ErrorHandlerTraits<RetT (&)(ErrT &)> {};
856 : public ErrorHandlerTraits<RetT (&)(ErrT &)> {};
861 : public ErrorHandlerTraits<RetT (&)(ErrT &)> {};
866 : public ErrorHandlerTraits<RetT (&)(ErrT &)> {};
872 : public ErrorHandlerTraits<RetT (&)(std::unique_ptr<ErrT>)> {};
878 : public ErrorHandlerTraits<RetT (&)(std::unique_ptr<ErrT>)> {};
880 inline Error handleErrorImpl(std::unique_ptr<ErrorInfoBase> Payload) {
885 Error handleErrorImpl(std::unique_ptr<ErrorInfoBase> Payload,
901 Error handleErrors(Error E, HandlerTs &&... Hs) {
901 Error handleErrors(Error E, HandlerTs &&... Hs) {
903 return Error::success();
909 Error R;
924 void handleAllErrors(Error E, HandlerTs &&... Handlers) {
930 inline void handleAllErrors(Error E) {
964 if (auto Err = handleErrors(ValOrErr.takeError(),
982 void logAllUnhandledErrors(Error E, raw_ostream &OS, Twine ErrorBanner = {});
986 inline std::string toString(Error E) {
1001 inline void consumeError(Error Err) {
1024 inline bool errorToBool(Error Err) {
1057 ErrorAsOutParameter(Error *Err) : Err(Err) {
1066 *Err = Error::success();
1070 Error *Err;
1100 friend Error errorCodeToError(std::error_code);
1128 Error errorCodeToError(std::error_code EC);
1134 std::error_code errorToErrorCode(Error Err);
1145 if (auto Err = E.takeError())
1197 inline Error createStringError(std::error_code EC, char const *Fmt,
1205 Error createStringError(std::error_code EC, char const *Msg);
1207 inline Error createStringError(std::error_code EC, const Twine &S) {
1212 inline Error createStringError(std::errc EC, char const *Fmt,
1223 friend Error createFileError(const Twine &, Error);
1223 friend Error createFileError(const Twine &, Error);
1224 friend Error createFileError(const Twine &, size_t, Error);
1224 friend Error createFileError(const Twine &, size_t, Error);
1235 Error takeError() { return Error(std::move(Err)); }
1253 static Error build(const Twine &F, Optional<size_t> Line, Error E) {
1253 static Error build(const Twine &F, Optional<size_t> Line, Error E) {
1265 inline Error createFileError(const Twine &F, Error E) {
1265 inline Error createFileError(const Twine &F, Error E) {
1271 inline Error createFileError(const Twine &F, size_t Line, Error E) {
1271 inline Error createFileError(const Twine &F, size_t Line, Error E) {
1277 inline Error createFileError(const Twine &F, std::error_code EC) {
1283 inline Error createFileError(const Twine &F, size_t Line, std::error_code EC) {
1287 Error createFileError(const Twine &F, ErrorSuccess) = delete;
1304 void setExitCodeMapper(std::function<int(const Error &)> GetExitCode) {
1309 void operator()(Error Err) const { checkError(std::move(Err)); }
1326 void checkError(Error Err) const {
1335 std::function<int(const Error &)> GetExitCode;
1339 inline LLVMErrorRef wrap(Error Err) {
1344 inline Error unwrap(LLVMErrorRef ErrRef) {
include/llvm/Support/FileOutputBuffer.h 66 virtual Error commit() = 0;
include/llvm/Support/FileSystem.h 863 Error keep(const Twine &Name);
866 Error keep();
869 Error discard();
include/llvm/Support/FileUtilities.h 107 llvm::Error writeFileAtomically(StringRef TempPathModel, StringRef FinalPath,
110 llvm::Error
112 std::function<llvm::Error(llvm::raw_ostream &)> Writer);
include/llvm/Support/FormatAdapters.h 22 explicit FormatAdapter(T &&Item) : Item(std::forward<T>(Item)) {}
22 explicit FormatAdapter(T &&Item) : Item(std::forward<T>(Item)) {}
24 T Item;
75 class ErrorAdapter : public FormatAdapter<Error> {
77 ErrorAdapter(Error &&Item) : FormatAdapter(std::move(Item)) {}
103 inline detail::ErrorAdapter fmt_consume(Error &&Item) {
include/llvm/Support/FormatVariadic.h 253 inline auto formatv(const char *Fmt, Ts &&... Vals) -> formatv_object<decltype(
include/llvm/Support/FormatVariadicDetails.h 48 explicit stream_operator_format_adapter(T &&Item)
145 build_format_adapter(T &&Item) {
150 !std::is_same<llvm::Error, typename std::remove_cv<T>::type>::value,
include/llvm/Support/MSVCErrorWorkarounds.h 27 class MSVCPError : public Error {
38 MSVCPError(Error Err) : Error(std::move(Err)) {}
57 MSVCPExpected(Error Err) : Expected<T>(std::move(Err)) {}
include/llvm/Support/PointerLikeTypeTraits.h 56 static inline void *getAsVoidPointer(T *P) { return P; }
57 static inline T *getFromVoidPointer(void *P) { return static_cast<T *>(P); }
59 enum { NumLowBitsAvailable = detail::ConstantLog2<alignof(T)>::value };
include/llvm/Support/ScopedPrinter.h 61 template <class T> const std::string to_string(const T &Value) {
include/llvm/Support/SymbolRemappingReader.h 101 Error read(MemoryBuffer &B);
include/llvm/Support/YAMLTraits.h 313 using Signature_enumeration = void (*)(class IO&, T&);
322 (sizeof(test<ScalarEnumerationTraits<T>>(nullptr)) == 1);
329 using Signature_bitset = void (*)(class IO&, T&);
337 static bool const value = (sizeof(test<ScalarBitSetTraits<T>>(nullptr)) == 1);
344 using Signature_input = StringRef (*)(StringRef, void*, T&);
345 using Signature_output = void (*)(const T&, void*, raw_ostream&);
357 (sizeof(test<ScalarTraits<T>>(nullptr, nullptr, nullptr)) == 1);
364 using Signature_input = StringRef (*)(StringRef, void *, T &);
365 using Signature_output = void (*)(const T &, void *, raw_ostream &);
375 (sizeof(test<BlockScalarTraits<T>>(nullptr, nullptr)) == 1);
380 using Signature_input = StringRef (*)(StringRef, StringRef, void *, T &);
381 using Signature_output = void (*)(const T &, void *, raw_ostream &,
383 using Signature_mustQuote = QuotingType (*)(const T &, StringRef);
393 (sizeof(test<TaggedScalarTraits<T>>(nullptr, nullptr, nullptr)) == 1);
412 using Signature_mapping = void (*)(class IO &, T &);
419 static bool const value = (sizeof(test<MappingTraits<T>>(nullptr)) == 1);
452 using Signature_size = size_t (*)(class IO&, T&);
460 static bool const value = (sizeof(test<SequenceTraits<T>>(nullptr)) == 1);
467 using Signature_input = void (*)(IO &io, StringRef key, T &v);
476 (sizeof(test<CustomMappingTraits<T>>(nullptr)) == 1);
516 using Signature_size = size_t (*)(class IO &, T &);
524 static bool const value = (sizeof(test<DocumentListTraits<T>>(nullptr))==1);
528 using Signature_getKind = NodeKind (*)(const T &);
535 static bool const value = (sizeof(test<PolymorphicTraits<T>>(nullptr)) == 1);
1869 inline typename std::enable_if<missingTraits<T, EmptyContext>::value,
1871 operator<<(Output &yout, T &seq) {
include/llvm/Support/type_traits.h 76 T t;
83 T t;
91 T t;
101 ::llvm::detail::copy_construction_triviality_helper<T>> {};
112 ::llvm::detail::move_construction_triviality_helper<T>> {};
130 static auto get(F*) -> decltype(std::declval<F &>() = std::declval<F &&>(), std::true_type{});
130 static auto get(F*) -> decltype(std::declval<F &>() = std::declval<F &&>(), std::true_type{});
130 static auto get(F*) -> decltype(std::declval<F &>() = std::declval<F &&>(), std::true_type{});
145 std::is_copy_constructible<detail::trivial_helper<T>>::value;
147 !std::is_copy_constructible<T>::value;
151 std::is_move_constructible<detail::trivial_helper<T>>::value;
153 !std::is_move_constructible<T>::value;
157 is_copy_assignable<detail::trivial_helper<T>>::value;
159 !is_copy_assignable<T>::value;
163 is_move_assignable<detail::trivial_helper<T>>::value;
165 !is_move_assignable<T>::value;
169 std::is_destructible<detail::trivial_helper<T>>::value;
include/llvm/Testing/Support/Error.h 21 ErrorHolder TakeError(Error Err);
include/llvm/TextAPI/ELF/TBEHandler.h 39 Error writeTBEToOutputStream(raw_ostream &OS, const ELFStub &Stub);
include/llvm/TextAPI/MachO/TextAPIWriter.h 23 static Error writeToStream(raw_ostream &os, const InterfaceFile &);
include/llvm/WindowsManifest/WindowsManifestMerger.h 52 Error merge(const MemoryBuffer &Manifest);
include/llvm/XRay/BlockIndexer.h 46 Error visit(BufferExtents &) override;
47 Error visit(WallclockRecord &) override;
48 Error visit(NewCPUIDRecord &) override;
49 Error visit(TSCWrapRecord &) override;
50 Error visit(CustomEventRecord &) override;
51 Error visit(CallArgRecord &) override;
52 Error visit(PIDRecord &) override;
53 Error visit(NewBufferRecord &) override;
54 Error visit(EndBufferRecord &) override;
55 Error visit(FunctionRecord &) override;
56 Error visit(CustomEventRecordV5 &) override;
57 Error visit(TypedEventRecord &) override;
62 Error flush();
include/llvm/XRay/BlockPrinter.h 42 Error visit(BufferExtents &) override;
43 Error visit(WallclockRecord &) override;
44 Error visit(NewCPUIDRecord &) override;
45 Error visit(TSCWrapRecord &) override;
46 Error visit(CustomEventRecord &) override;
47 Error visit(CallArgRecord &) override;
48 Error visit(PIDRecord &) override;
49 Error visit(NewBufferRecord &) override;
50 Error visit(EndBufferRecord &) override;
51 Error visit(FunctionRecord &) override;
52 Error visit(CustomEventRecordV5 &) override;
53 Error visit(TypedEventRecord &) override;
include/llvm/XRay/BlockVerifier.h 48 Error transition(State To);
51 Error visit(BufferExtents &) override;
52 Error visit(WallclockRecord &) override;
53 Error visit(NewCPUIDRecord &) override;
54 Error visit(TSCWrapRecord &) override;
55 Error visit(CustomEventRecord &) override;
56 Error visit(CallArgRecord &) override;
57 Error visit(PIDRecord &) override;
58 Error visit(NewBufferRecord &) override;
59 Error visit(EndBufferRecord &) override;
60 Error visit(FunctionRecord &) override;
61 Error visit(CustomEventRecordV5 &) override;
62 Error visit(TypedEventRecord &) override;
64 Error verify();
include/llvm/XRay/FDRRecordConsumer.h 22 virtual Error consume(std::unique_ptr<Record> R) = 0;
35 Error consume(std::unique_ptr<Record> R) override;
48 Error consume(std::unique_ptr<Record> R) override;
include/llvm/XRay/FDRRecords.h 66 virtual Error apply(RecordVisitor &V) = 0;
126 Error apply(RecordVisitor &V) override;
151 Error apply(RecordVisitor &V) override;
177 Error apply(RecordVisitor &V) override;
199 Error apply(RecordVisitor &V) override;
228 Error apply(RecordVisitor &V) override;
255 Error apply(RecordVisitor &V) override;
284 Error apply(RecordVisitor &V) override;
306 Error apply(RecordVisitor &V) override;
329 Error apply(RecordVisitor &V) override;
352 Error apply(RecordVisitor &V) override;
365 Error apply(RecordVisitor &V) override;
392 Error apply(RecordVisitor &V) override;
404 virtual Error visit(BufferExtents &) = 0;
405 virtual Error visit(WallclockRecord &) = 0;
406 virtual Error visit(NewCPUIDRecord &) = 0;
407 virtual Error visit(TSCWrapRecord &) = 0;
408 virtual Error visit(CustomEventRecord &) = 0;
409 virtual Error visit(CallArgRecord &) = 0;
410 virtual Error visit(PIDRecord &) = 0;
411 virtual Error visit(NewBufferRecord &) = 0;
412 virtual Error visit(EndBufferRecord &) = 0;
413 virtual Error visit(FunctionRecord &) = 0;
414 virtual Error visit(CustomEventRecordV5 &) = 0;
415 virtual Error visit(TypedEventRecord &) = 0;
432 Error visit(BufferExtents &) override;
433 Error visit(WallclockRecord &) override;
434 Error visit(NewCPUIDRecord &) override;
435 Error visit(TSCWrapRecord &) override;
436 Error visit(CustomEventRecord &) override;
437 Error visit(CallArgRecord &) override;
438 Error visit(PIDRecord &) override;
439 Error visit(NewBufferRecord &) override;
440 Error visit(EndBufferRecord &) override;
441 Error visit(FunctionRecord &) override;
442 Error visit(CustomEventRecordV5 &) override;
443 Error visit(TypedEventRecord &) override;
include/llvm/XRay/FDRTraceExpander.h 41 Error visit(BufferExtents &) override;
42 Error visit(WallclockRecord &) override;
43 Error visit(NewCPUIDRecord &) override;
44 Error visit(TSCWrapRecord &) override;
45 Error visit(CustomEventRecord &) override;
46 Error visit(CallArgRecord &) override;
47 Error visit(PIDRecord &) override;
48 Error visit(NewBufferRecord &) override;
49 Error visit(EndBufferRecord &) override;
50 Error visit(FunctionRecord &) override;
51 Error visit(CustomEventRecordV5 &) override;
52 Error visit(TypedEventRecord &) override;
56 Error flush();
include/llvm/XRay/FDRTraceWriter.h 35 Error visit(BufferExtents &) override;
36 Error visit(WallclockRecord &) override;
37 Error visit(NewCPUIDRecord &) override;
38 Error visit(TSCWrapRecord &) override;
39 Error visit(CustomEventRecord &) override;
40 Error visit(CallArgRecord &) override;
41 Error visit(PIDRecord &) override;
42 Error visit(NewBufferRecord &) override;
43 Error visit(EndBufferRecord &) override;
44 Error visit(FunctionRecord &) override;
45 Error visit(CustomEventRecordV5 &) override;
46 Error visit(TypedEventRecord &) override;
include/llvm/XRay/Profile.h 83 Error addBlock(Block &&B);
include/llvm/XRay/RecordPrinter.h 32 Error visit(BufferExtents &) override;
33 Error visit(WallclockRecord &) override;
34 Error visit(NewCPUIDRecord &) override;
35 Error visit(TSCWrapRecord &) override;
36 Error visit(CustomEventRecord &) override;
37 Error visit(CallArgRecord &) override;
38 Error visit(PIDRecord &) override;
39 Error visit(NewBufferRecord &) override;
40 Error visit(EndBufferRecord &) override;
41 Error visit(FunctionRecord &) override;
42 Error visit(CustomEventRecordV5 &) override;
43 Error visit(TypedEventRecord &) override;
lib/Bitcode/Reader/BitReader.cpp 43 if (Error Err = ModuleOrErr.takeError()) {
89 if (Error Err = ModuleOrErr.takeError()) {
lib/Bitcode/Reader/BitcodeAnalyzer.cpp 19 static Error reportError(StringRef Message) {
413 return Error::success();
417 if (Error Err = tryRead(Signature[0], 8))
419 if (Error Err = tryRead(Signature[1], 8))
424 if (Error Err = tryRead(Signature[2], 8))
426 if (Error Err = tryRead(Signature[3], 8))
431 if (Error Err = tryRead(Signature[2], 8))
433 if (Error Err = tryRead(Signature[3], 8))
438 if (Error Err = tryRead(Signature[2], 8))
440 if (Error Err = tryRead(Signature[3], 8))
445 if (Error Err = tryRead(Signature[2], 4))
447 if (Error Err = tryRead(Signature[3], 4))
449 if (Error Err = tryRead(Signature[4], 4))
451 if (Error Err = tryRead(Signature[5], 4))
501 Error BitcodeAnalyzer::decodeMetadataStringsBlob(StringRef Indent,
537 return Error::success();
547 Error BitcodeAnalyzer::analyze(Optional<BCDumpOptions> O,
588 if (Error Err = BlockInfoCursor.SkipBlock())
605 if (Error E = parseBlock(MaybeBlockID.get(), 0, O, CheckHash))
610 return Error::success();
724 Error BitcodeAnalyzer::parseBlock(unsigned BlockID, unsigned IndentLevel,
749 if (Error Err = Stream.JumpToBit(BlockBitStart))
757 if (Error Err = Stream.EnterSubBlock(BlockID, &NumWords))
809 return Error::success();
814 if (Error E = parseBlock(Entry.ID, IndentLevel + 1, O, CheckHash))
829 if (Error Err = Stream.ReadAbbrevRecord())
955 if (Error E = decodeMetadataStringsBlob(Indent, Record, Blob, O->OS))
982 if (Error Err = Stream.JumpToBit(CurrentRecordPos))
lib/Bitcode/Reader/BitcodeReader.cpp 103 static Error error(const Twine &Message) {
108 static Error hasInvalidBitcodeHeader(BitstreamCursor &Stream) {
126 return Error::success();
143 if (Error Err = hasInvalidBitcodeHeader(Stream))
174 if (Error Err = Stream.EnterSubBlock(bitc::IDENTIFICATION_BLOCK_ID))
246 if (Error Err = Stream.SkipBlock())
259 if (Error Err = Stream.EnterSubBlock(bitc::MODULE_BLOCK_ID))
326 if (Error Err = Stream.SkipBlock())
340 if (Error Err = Stream.EnterSubBlock(bitc::MODULE_BLOCK_ID))
404 if (Error Err = Stream.SkipBlock())
447 Error error(const Twine &Message);
452 Error BitcodeReaderBase::error(const Twine &Message) {
573 Error materializeForwardReferencedFunctions();
575 Error materialize(GlobalValue *GV) override;
576 Error materializeModule() override;
581 Error parseBitcodeInto(Module *M, bool ShouldLazyLoadMetadata = false,
587 Error materializeMetadata() override;
725 Error parseAlignmentValue(uint64_t Exponent, MaybeAlign &Alignment);
726 Error parseAttrKind(uint64_t Code, Attribute::AttrKind *Kind);
727 Error parseModule(uint64_t ResumeBit, bool ShouldLazyLoadMetadata = false);
729 Error parseComdatRecord(ArrayRef<uint64_t> Record);
730 Error parseGlobalVarRecord(ArrayRef<uint64_t> Record);
731 Error parseFunctionRecord(ArrayRef<uint64_t> Record);
732 Error parseGlobalIndirectSymbolRecord(unsigned BitCode,
735 Error parseAttributeBlock();
736 Error parseAttributeGroupBlock();
737 Error parseTypeTable();
738 Error parseTypeTableBody();
739 Error parseOperandBundleTags();
740 Error parseSyncScopeNames();
746 Error parseValueSymbolTable(uint64_t Offset = 0);
747 Error parseGlobalValueSymbolTable();
748 Error parseConstants();
749 Error rememberAndSkipFunctionBodies();
750 Error rememberAndSkipFunctionBody();
752 Error rememberAndSkipMetadata();
753 Error typeCheckLoadStoreInst(Type *ValType, Type *PtrType);
754 Error parseFunctionBody(Function *F);
755 Error globalCleanup();
756 Error resolveGlobalAndIndirectSymbolInits();
757 Error parseUseLists();
758 Error findFunctionInStream(
815 Error parseModule();
821 Error parseValueSymbolTable(
829 Error parseEntireSummary(unsigned ID);
830 Error parseModuleStringTable();
845 Error Err) {
865 Error BitcodeReader::materializeForwardReferencedFunctions() {
867 return Error::success();
888 if (Error Err = materialize(F))
895 return Error::success();
1348 Error BitcodeReader::parseAttributeBlock() {
1349 if (Error Err = Stream.EnterSubBlock(bitc::PARAMATTR_BLOCK_ID))
1371 return Error::success();
1546 Error BitcodeReader::parseAlignmentValue(uint64_t Exponent,
1553 return Error::success();
1556 Error BitcodeReader::parseAttrKind(uint64_t Code, Attribute::AttrKind *Kind) {
1560 return Error::success();
1563 Error BitcodeReader::parseAttributeGroupBlock() {
1564 if (Error Err = Stream.EnterSubBlock(bitc::PARAMATTR_GROUP_BLOCK_ID))
1584 return Error::success();
1609 if (Error Err = parseAttrKind(Record[++i], &Kind))
1621 if (Error Err = parseAttrKind(Record[++i], &Kind))
1656 if (Error Err = parseAttrKind(Record[++i], &Kind))
1670 Error BitcodeReader::parseTypeTable() {
1671 if (Error Err = Stream.EnterSubBlock(bitc::TYPE_BLOCK_ID_NEW))
1677 Error BitcodeReader::parseTypeTableBody() {
1700 return Error::success();
1921 Error BitcodeReader::parseOperandBundleTags() {
1922 if (Error Err = Stream.EnterSubBlock(bitc::OPERAND_BUNDLE_TAGS_BLOCK_ID))
1941 return Error::success();
1963 Error BitcodeReader::parseSyncScopeNames() {
1964 if (Error Err = Stream.EnterSubBlock(bitc::SYNC_SCOPE_NAMES_BLOCK_ID))
1984 return Error::success();
2042 if (Error JumpFailed = Stream.JumpToBit(Offset * 32))
2069 Error BitcodeReader::parseGlobalValueSymbolTable() {
2073 if (Error Err = Stream.EnterSubBlock(bitc::VALUE_SYMTAB_BLOCK_ID))
2088 return Error::success();
2108 Error BitcodeReader::parseValueSymbolTable(uint64_t Offset) {
2120 if (Error Err = parseGlobalValueSymbolTable())
2122 if (Error JumpFailed = Stream.JumpToBit(CurrentBit))
2124 return Error::success();
2144 if (Error Err = Stream.EnterSubBlock(bitc::VALUE_SYMTAB_BLOCK_ID))
2166 if (Error JumpFailed = Stream.JumpToBit(CurrentBit))
2168 return Error::success();
2184 if (Error Err = ValOrErr.takeError())
2192 if (Error Err = ValOrErr.takeError())
2229 Error BitcodeReader::resolveGlobalAndIndirectSymbolInits() {
2312 return Error::success();
2323 Error BitcodeReader::parseConstants() {
2324 if (Error Err = Stream.EnterSubBlock(bitc::CONSTANTS_BLOCK_ID))
2351 return Error::success();
2829 Error BitcodeReader::parseUseLists() {
2830 if (Error Err = Stream.EnterSubBlock(bitc::USELIST_BLOCK_ID))
2847 return Error::success();
2902 Error BitcodeReader::rememberAndSkipMetadata() {
2908 if (Error Err = Stream.SkipBlock())
2910 return Error::success();
2913 Error BitcodeReader::materializeMetadata() {
2916 if (Error JumpFailed = Stream.JumpToBit(BitPos))
2918 if (Error Err = MDLoader->parseModuleMetadata())
2932 return Error::success();
2939 Error BitcodeReader::rememberAndSkipFunctionBody() {
2955 if (Error Err = Stream.SkipBlock())
2957 return Error::success();
2960 Error BitcodeReader::globalCleanup() {
2962 if (Error Err = resolveGlobalAndIndirectSymbolInits())
2995 return Error::success();
3002 Error BitcodeReader::rememberAndSkipFunctionBodies() {
3003 if (Error JumpFailed = Stream.JumpToBit(NextUnreadBit))
3032 if (Error Err = rememberAndSkipFunctionBody())
3035 return Error::success();
3054 Error BitcodeReader::parseComdatRecord(ArrayRef<uint64_t> Record) {
3076 return Error::success();
3086 Error BitcodeReader::parseGlobalVarRecord(ArrayRef<uint64_t> Record) {
3116 if (Error Err = parseAlignmentValue(Record[4], Alignment))
3189 return Error::success();
3192 Error BitcodeReader::parseFunctionRecord(ArrayRef<uint64_t> Record) {
3247 if (Error Err = parseAlignmentValue(Record[5], Alignment))
3315 return Error::success();
3318 Error BitcodeReader::parseGlobalIndirectSymbolRecord(
3399 return Error::success();
3402 Error BitcodeReader::parseModule(uint64_t ResumeBit,
3405 if (Error JumpFailed = Stream.JumpToBit(ResumeBit))
3407 } else if (Error Err = Stream.EnterSubBlock(bitc::MODULE_BLOCK_ID))
3428 if (Error Err = Stream.SkipBlock())
3436 if (Error Err = parseAttributeBlock())
3440 if (Error Err = parseAttributeGroupBlock())
3444 if (Error Err = parseTypeTable())
3455 if (Error Err = parseValueSymbolTable())
3462 if (Error Err = Stream.SkipBlock())
3467 if (Error Err = parseConstants())
3469 if (Error Err = resolveGlobalAndIndirectSymbolInits())
3474 if (Error Err = rememberAndSkipMetadata())
3479 if (Error Err = MDLoader->parseModuleMetadata())
3483 if (Error Err = MDLoader->parseMetadataKinds())
3491 if (Error Err = globalCleanup())
3501 if (Error Err = BitcodeReader::parseValueSymbolTable(VSTOffset))
3515 if (Error Err = Stream.SkipBlock())
3525 if (Error Err = rememberAndSkipFunctionBody())
3540 if (Error Err = parseUseLists())
3544 if (Error Err = parseOperandBundleTags())
3548 if (Error Err = parseSyncScopeNames())
3616 if (Error Err = parseComdatRecord(Record))
3620 if (Error Err = parseGlobalVarRecord(Record))
3624 if (Error Err = parseFunctionRecord(Record))
3630 if (Error Err = parseGlobalIndirectSymbolRecord(BitCode, Record))
3659 Error BitcodeReader::parseBitcodeInto(Module *M, bool ShouldLazyLoadMetadata,
3667 Error BitcodeReader::typeCheckLoadStoreInst(Type *ValType, Type *PtrType) {
3677 return Error::success();
3694 Error BitcodeReader::parseFunctionBody(Function *F) {
3695 if (Error Err = Stream.EnterSubBlock(bitc::FUNCTION_BLOCK_ID))
3748 if (Error Err = Stream.SkipBlock())
3752 if (Error Err = parseConstants())
3757 if (Error Err = parseValueSymbolTable())
3761 if (Error Err = MDLoader->parseMetadataAttachment(*F, InstructionList))
3767 if (Error Err = MDLoader->parseFunctionMetadata())
3771 if (Error Err = parseUseLists())
4754 if (Error Err = parseAlignmentValue(AlignRecord & ~FlagMask, Align)) {
4789 if (Error Err = typeCheckLoadStoreInst(Ty, Op->getType()))
4793 if (Error Err = parseAlignmentValue(Record[OpNum], Align))
4817 if (Error Err = typeCheckLoadStoreInst(Ty, Op->getType()))
4830 if (Error Err = parseAlignmentValue(Record[OpNum], Align))
4849 if (Error Err = typeCheckLoadStoreInst(Val->getType(), Ptr->getType()))
4852 if (Error Err = parseAlignmentValue(Record[OpNum], Align))
4873 if (Error Err = typeCheckLoadStoreInst(Val->getType(), Ptr->getType()))
4885 if (Error Err = parseAlignmentValue(Record[OpNum], Align))
4922 if (Error Err = typeCheckLoadStoreInst(Cmp->getType(), Ptr->getType()))
5188 return Error::success();
5192 Error BitcodeReader::findFunctionInStream(
5203 if (Error Err = rememberAndSkipFunctionBodies())
5206 return Error::success();
5221 Error BitcodeReader::materialize(GlobalValue *GV) {
5225 return Error::success();
5232 if (Error Err = findFunctionInStream(F, DFII))
5236 if (Error Err = materializeMetadata())
5240 if (Error JumpFailed = Stream.JumpToBit(DFII->second))
5242 if (Error Err = parseFunctionBody(F))
5287 Error BitcodeReader::materializeModule() {
5288 if (Error Err = materializeMetadata())
5297 if (Error Err = materialize(&F))
5304 if (Error Err = parseModule(LastFunctionBlockBit > NextUnreadBit
5341 return Error::success();
5396 Error ModuleSummaryIndexBitcodeReader::parseValueSymbolTable(
5401 return Error::success();
5409 if (Error Err = Stream.EnterSubBlock(bitc::VALUE_SYMTAB_BLOCK_ID))
5429 if (Error JumpFailed = Stream.JumpToBit(CurrentBit))
5431 return Error::success();
5489 Error ModuleSummaryIndexBitcodeReader::parseModule() {
5490 if (Error Err = Stream.EnterSubBlock(bitc::MODULE_BLOCK_ID))
5508 return Error::success();
5513 if (Error Err = Stream.SkipBlock())
5527 if (Error Err = Stream.SkipBlock())
5542 if (Error Err = parseValueSymbolTable(VSTOffset, ValueIdToLinkageMap))
5547 if (Error Err = parseEntireSummary(Entry.ID))
5551 if (Error Err = parseModuleStringTable())
5566 if (Error Err = parseVersionRecord(Record).takeError())
5745 Error ModuleSummaryIndexBitcodeReader::parseEntireSummary(unsigned ID) {
5746 if (Error Err = Stream.EnterSubBlock(ID))
5797 return Error::success();
6180 Error ModuleSummaryIndexBitcodeReader::parseModuleStringTable() {
6181 if (Error Err = Stream.EnterSubBlock(bitc::MODULE_STRTAB_BLOCK_ID))
6200 return Error::success();
6276 if (Error Err = Stream.EnterSubBlock(Block))
6294 if (Error Err = Stream.SkipBlock())
6355 if (Error Err = Stream.SkipBlock())
6372 if (Error Err = Stream.SkipBlock())
6421 if (Error Err = Stream.SkipBlock())
6449 if (Error JumpFailed = Stream.JumpToBit(IdentificationBit))
6459 if (Error JumpFailed = Stream.JumpToBit(ModuleBit))
6469 if (Error Err =
6475 if (Error Err = M->materializeAll())
6479 if (Error Err = R->materializeForwardReferencedFunctions())
6495 Error BitcodeModule::readSummary(ModuleSummaryIndex &CombinedIndex,
6498 if (Error JumpFailed = Stream.JumpToBit(ModuleBit))
6509 if (Error JumpFailed = Stream.JumpToBit(ModuleBit))
6516 if (Error Err = R.parseModule())
6524 if (Error Err = Stream.EnterSubBlock(ID))
6570 if (Error JumpFailed = Stream.JumpToBit(ModuleBit))
6573 if (Error Err = Stream.EnterSubBlock(bitc::MODULE_BLOCK_ID))
6609 if (Error Err = Stream.SkipBlock())
6693 Error llvm::readModuleSummaryIndex(MemoryBufferRef Buffer,
lib/Bitcode/Reader/MetadataLoader.cpp 416 static Error error(const Twine &Message) {
472 Error parseOneMetadata(SmallVectorImpl<uint64_t> &Record, unsigned Code,
475 Error parseMetadataStrings(ArrayRef<uint64_t> Record, StringRef Blob,
477 Error parseGlobalObjectAttachment(GlobalObject &GO,
479 Error parseMetadataKindRecord(SmallVectorImpl<uint64_t> &Record);
548 Error upgradeDIExpression(uint64_t FromVersion,
626 return Error::success();
644 Error parseMetadata(bool ModuleLevel);
670 Error parseMetadataAttachment(
673 Error parseMetadataKinds();
713 if (Error Err = IndexCursor.JumpToBit(CurrentPos))
727 if (auto Err = parseMetadataStrings(Record, Blob, IndexNextMDString))
734 if (Error Err = IndexCursor.JumpToBit(CurrentPos))
746 if (Error Err = IndexCursor.JumpToBit(BeginPos + Offset))
780 if (Error Err = IndexCursor.JumpToBit(CurrentPos))
825 if (Error Err = IndexCursor.JumpToBit(CurrentPos))
839 if (Error Err = parseGlobalObjectAttachment(
892 Error MetadataLoader::MetadataLoaderImpl::parseMetadata(bool ModuleLevel) {
900 if (Error Err = Stream.EnterSubBlock(bitc::METADATA_BLOCK_ID))
926 if (Error Err = IndexCursor.JumpToBit(EntryPos))
928 if (Error Err = Stream.SkipBlock()) {
932 return Error::success();
934 return Error::success();
955 return Error::success();
967 if (Error Err = parseOneMetadata(Record, MaybeCode.get(), Placeholders,
996 if (Error Err = IndexCursor.JumpToBit(
1009 if (Error Err =
1051 Error MetadataLoader::MetadataLoaderImpl::parseOneMetadata(
1824 if (Error Err = upgradeDIExpression(Version, Elts, Buffer))
1895 if (Error Err = parseMetadataStrings(Record, Blob, CreateNextMDString))
1906 if (Error Err = parseGlobalObjectAttachment(
1914 if (Error Err = parseMetadataKindRecord(Record))
1919 return Error::success();
1923 Error MetadataLoader::MetadataLoaderImpl::parseMetadataStrings(
1958 return Error::success();
1961 Error MetadataLoader::MetadataLoaderImpl::parseGlobalObjectAttachment(
1973 return Error::success();
1977 Error MetadataLoader::MetadataLoaderImpl::parseMetadataAttachment(
1979 if (Error Err = Stream.EnterSubBlock(bitc::METADATA_ATTACHMENT_ID))
1997 return Error::success();
2018 if (Error Err = parseGlobalObjectAttachment(F, Record))
2067 Error MetadataLoader::MetadataLoaderImpl::parseMetadataKindRecord(
2078 return Error::success();
2082 Error MetadataLoader::MetadataLoaderImpl::parseMetadataKinds() {
2083 if (Error Err = Stream.EnterSubBlock(bitc::METADATA_KIND_BLOCK_ID))
2100 return Error::success();
2116 if (Error Err = parseMetadataKindRecord(Record))
2139 Error MetadataLoader::parseMetadata(bool ModuleLevel) {
2155 Error MetadataLoader::parseMetadataAttachment(
2160 Error MetadataLoader::parseMetadataKinds() {
lib/Bitcode/Reader/MetadataLoader.h 38 Error parseMetadata(bool ModuleLevel);
49 Error parseModuleMetadata() { return parseMetadata(true); }
52 Error parseFunctionMetadata() { return parseMetadata(false); }
71 Error parseMetadataAttachment(
75 Error parseMetadataKinds();
lib/Bitcode/Writer/BitcodeWriter.cpp 4401 if (Error E = irsymtab::build(Mods, Symtab, StrtabBuilder, Alloc)) {
lib/Bitstream/Reader/BitstreamReader.cpp 21 Error BitstreamCursor::EnterSubBlock(unsigned BlockID, unsigned *NumWordsP) {
64 return Error::success();
91 static Error skipAbbreviatedField(BitstreamCursor &Cursor,
166 if (Error Err = skipAbbreviatedField(*this, Op))
189 if (Error Err = JumpToBit(GetCurrentBitNo() +
203 if (Error Err = JumpToBit(GetCurrentBitNo() + NumElts * 6))
229 if (Error Err = JumpToBit(NewEnd))
358 if (Error Err = JumpToBit(NewEnd))
375 Error BitstreamCursor::ReadAbbrevRecord() {
428 return Error::success();
433 if (llvm::Error Err = EnterSubBlock(bitc::BLOCKINFO_BLOCK_ID))
463 if (Error Err = ReadAbbrevRecord())
lib/CodeGen/AsmPrinter/CodeViewDebug.cpp 658 Error E = codeview::visitTypeRecord(Record, *B, Pipeline);
lib/DebugInfo/CodeView/CVSymbolVisitor.cpp 21 static Error visitKnownRecord(CVSymbol &Record,
25 if (auto EC = Callbacks.visitKnownRecord(Record, KnownRecord))
27 return Error::success();
30 static Error finishVisitation(CVSymbol &Record,
34 if (auto EC = Callbacks.visitUnknownSymbol(Record))
48 if (auto EC = Callbacks.visitSymbolEnd(Record))
51 return Error::success();
54 Error CVSymbolVisitor::visitSymbolRecord(CVSymbol &Record) {
55 if (auto EC = Callbacks.visitSymbolBegin(Record))
60 Error CVSymbolVisitor::visitSymbolRecord(CVSymbol &Record, uint32_t Offset) {
61 if (auto EC = Callbacks.visitSymbolBegin(Record, Offset))
66 Error CVSymbolVisitor::visitSymbolStream(const CVSymbolArray &Symbols) {
68 if (auto EC = visitSymbolRecord(I))
71 return Error::success();
74 Error CVSymbolVisitor::visitSymbolStream(const CVSymbolArray &Symbols,
77 if (auto EC = visitSymbolRecord(I, InitialOffset + Symbols.skew()))
81 return Error::success();
lib/DebugInfo/CodeView/CVTypeVisitor.cpp 24 static Error visitKnownRecord(CVType &Record, TypeVisitorCallbacks &Callbacks) {
27 if (auto EC = Callbacks.visitKnownRecord(Record, KnownRecord))
29 return Error::success();
33 static Error visitKnownMember(CVMemberRecord &Record,
37 if (auto EC = Callbacks.visitKnownMember(Record, KnownRecord))
39 return Error::success();
42 static Error visitMemberRecord(CVMemberRecord &Record,
44 if (auto EC = Callbacks.visitMemberBegin(Record))
49 if (auto EC = Callbacks.visitUnknownMember(Record))
65 if (auto EC = Callbacks.visitMemberEnd(Record))
68 return Error::success();
77 Error visitTypeRecord(CVType &Record, TypeIndex Index);
78 Error visitTypeRecord(CVType &Record);
81 Error visitTypeStream(const CVTypeArray &Types);
82 Error visitTypeStream(CVTypeRange Types);
83 Error visitTypeStream(TypeCollection &Types);
85 Error visitMemberRecord(CVMemberRecord Record);
86 Error visitFieldListMemberStream(BinaryStreamReader &Stream);
89 Error finishVisitation(CVType &Record);
98 Error CVTypeVisitor::finishVisitation(CVType &Record) {
101 if (auto EC = Callbacks.visitUnknownType(Record))
117 if (auto EC = Callbacks.visitTypeEnd(Record))
120 return Error::success();
123 Error CVTypeVisitor::visitTypeRecord(CVType &Record, TypeIndex Index) {
124 if (auto EC = Callbacks.visitTypeBegin(Record, Index))
130 Error CVTypeVisitor::visitTypeRecord(CVType &Record) {
131 if (auto EC = Callbacks.visitTypeBegin(Record))
137 Error CVTypeVisitor::visitMemberRecord(CVMemberRecord Record) {
142 Error CVTypeVisitor::visitTypeStream(const CVTypeArray &Types) {
144 if (auto EC = visitTypeRecord(I))
147 return Error::success();
150 Error CVTypeVisitor::visitTypeStream(CVTypeRange Types) {
152 if (auto EC = visitTypeRecord(I))
155 return Error::success();
158 Error CVTypeVisitor::visitTypeStream(TypeCollection &Types) {
162 if (auto EC = visitTypeRecord(Type, *I))
166 return Error::success();
169 Error CVTypeVisitor::visitFieldListMemberStream(BinaryStreamReader &Reader) {
172 if (auto EC = Reader.readEnum(Leaf))
177 if (auto EC = ::visitMemberRecord(Record, Callbacks))
181 return Error::success();
218 Error llvm::codeview::visitTypeRecord(CVType &Record, TypeIndex Index,
225 Error llvm::codeview::visitTypeRecord(CVType &Record,
232 Error llvm::codeview::visitTypeStream(const CVTypeArray &Types,
239 Error llvm::codeview::visitTypeStream(CVTypeRange Types,
245 Error llvm::codeview::visitTypeStream(TypeCollection &Types,
254 Error llvm::codeview::visitMemberRecord(CVMemberRecord Record,
261 Error llvm::codeview::visitMemberRecord(TypeLeafKind Kind,
270 Error llvm::codeview::visitMemberRecordStream(ArrayRef<uint8_t> FieldList,
lib/DebugInfo/CodeView/CodeViewRecordIO.cpp 18 Error CodeViewRecordIO::beginRecord(Optional<uint32_t> MaxLength) {
23 return Error::success();
26 Error CodeViewRecordIO::endRecord() {
43 return Error::success();
54 return Error::success();
79 Error CodeViewRecordIO::padToAlignment(uint32_t Align) {
85 Error CodeViewRecordIO::skipPadding() {
89 return Error::success();
93 return Error::success();
100 Error CodeViewRecordIO::mapByteVectorTail(ArrayRef<uint8_t> &Bytes,
107 if (auto EC = Writer->writeBytes(Bytes))
110 if (auto EC = Reader->readBytes(Bytes, Reader->bytesRemaining()))
113 return Error::success();
116 Error CodeViewRecordIO::mapByteVectorTail(std::vector<uint8_t> &Bytes,
119 if (auto EC = mapByteVectorTail(BytesRef, Comment))
124 return Error::success();
127 Error CodeViewRecordIO::mapInteger(TypeIndex &TypeInd, const Twine &Comment) {
137 if (auto EC = Writer->writeInteger(TypeInd.getIndex()))
141 if (auto EC = Reader->readInteger(I))
145 return Error::success();
148 Error CodeViewRecordIO::mapEncodedInteger(int64_t &Value,
157 if (auto EC = writeEncodedUnsignedInteger(static_cast<uint64_t>(Value)))
160 if (auto EC = writeEncodedSignedInteger(Value))
165 if (auto EC = consume(*Reader, N))
170 return Error::success();
173 Error CodeViewRecordIO::mapEncodedInteger(uint64_t &Value,
178 if (auto EC = writeEncodedUnsignedInteger(Value))
182 if (auto EC = consume(*Reader, N))
186 return Error::success();
189 Error CodeViewRecordIO::mapEncodedInteger(APSInt &Value, const Twine &Comment) {
201 return Error::success();
204 Error CodeViewRecordIO::mapStringZ(StringRef &Value, const Twine &Comment) {
213 if (auto EC = Writer->writeCString(S))
216 if (auto EC = Reader->readCString(Value))
219 return Error::success();
222 Error CodeViewRecordIO::mapGuid(GUID &Guid, const Twine &Comment) {
231 return Error::success();
238 if (auto EC = Writer->writeBytes(Guid.Guid))
242 if (auto EC = Reader->readBytes(GuidBytes, GuidSize))
246 return Error::success();
249 Error CodeViewRecordIO::mapStringZVectorZ(std::vector<StringRef> &Value,
255 if (auto EC = mapStringZ(V))
259 if (auto EC = mapInteger(FinalZero))
263 if (auto EC = mapStringZ(S))
267 if (auto EC = mapStringZ(S))
271 return Error::success();
324 Error CodeViewRecordIO::writeEncodedSignedInteger(const int64_t &Value) {
327 if (auto EC = Writer->writeInteger<uint16_t>(LF_CHAR))
329 if (auto EC = Writer->writeInteger<int8_t>(Value))
332 if (auto EC = Writer->writeInteger<uint16_t>(LF_SHORT))
334 if (auto EC = Writer->writeInteger<int16_t>(Value))
337 if (auto EC = Writer->writeInteger<uint16_t>(LF_LONG))
339 if (auto EC = Writer->writeInteger<int32_t>(Value))
342 if (auto EC = Writer->writeInteger<uint16_t>(LF_QUADWORD))
344 if (auto EC = Writer->writeInteger(Value))
347 return Error::success();
350 Error CodeViewRecordIO::writeEncodedUnsignedInteger(const uint64_t &Value) {
352 if (auto EC = Writer->writeInteger<uint16_t>(Value))
355 if (auto EC = Writer->writeInteger<uint16_t>(LF_USHORT))
357 if (auto EC = Writer->writeInteger<uint16_t>(Value))
360 if (auto EC = Writer->writeInteger<uint16_t>(LF_ULONG))
362 if (auto EC = Writer->writeInteger<uint32_t>(Value))
365 if (auto EC = Writer->writeInteger<uint16_t>(LF_UQUADWORD))
367 if (auto EC = Writer->writeInteger(Value))
371 return Error::success();
lib/DebugInfo/CodeView/DebugChecksumsSubsection.cpp 34 Error VarStreamArrayExtractor<FileChecksumEntry>::
39 if (auto EC = Reader.readObject(Header))
44 if (auto EC = Reader.readBytes(Item.Checksum, Header->ChecksumSize))
48 return Error::success();
51 Error DebugChecksumsSubsectionRef::initialize(BinaryStreamReader Reader) {
52 if (auto EC = Reader.readArray(Checksums, Reader.bytesRemaining()))
55 return Error::success();
58 Error DebugChecksumsSubsectionRef::initialize(BinaryStreamRef Section) {
94 Error DebugChecksumsSubsection::commit(BinaryStreamWriter &Writer) const {
100 if (auto EC = Writer.writeObject(Header))
102 if (auto EC = Writer.writeArray(makeArrayRef(FC.Checksum)))
104 if (auto EC = Writer.padToAlignment(4))
107 return Error::success();
lib/DebugInfo/CodeView/DebugCrossExSubsection.cpp 18 Error DebugCrossModuleExportsSubsectionRef::initialize(
29 Error DebugCrossModuleExportsSubsectionRef::initialize(BinaryStreamRef Stream) {
43 Error DebugCrossModuleExportsSubsection::commit(
46 if (auto EC = Writer.writeInteger(M.first))
48 if (auto EC = Writer.writeInteger(M.second))
51 return Error::success();
lib/DebugInfo/CodeView/DebugCrossImpSubsection.cpp 25 Error VarStreamArrayExtractor<CrossModuleImportItem>::
33 if (auto EC = Reader.readObject(Item.Header))
39 if (auto EC = Reader.readArray(Item.Imports, Item.Header->Count))
41 return Error::success();
44 Error DebugCrossModuleImportsSubsectionRef::initialize(
49 Error DebugCrossModuleImportsSubsectionRef::initialize(BinaryStreamRef Stream) {
72 Error DebugCrossModuleImportsSubsection::commit(
90 if (auto EC = Writer.writeObject(Imp))
92 if (auto EC = Writer.writeArray(makeArrayRef(Item->getValue())))
95 return Error::success();
lib/DebugInfo/CodeView/DebugFrameDataSubsection.cpp 15 Error DebugFrameDataSubsectionRef::initialize(BinaryStreamReader Reader) {
17 if (auto EC = Reader.readObject(RelocPtr))
26 if (auto EC = Reader.readArray(Frames, Count))
28 return Error::success();
31 Error DebugFrameDataSubsectionRef::initialize(BinaryStreamRef Section) {
43 Error DebugFrameDataSubsection::commit(BinaryStreamWriter &Writer) const {
45 if (auto EC = Writer.writeInteger<uint32_t>(0))
54 if (auto EC = Writer.writeArray(makeArrayRef(SortedFrames)))
56 return Error::success();
lib/DebugInfo/CodeView/DebugInlineeLinesSubsection.cpp 23 Error VarStreamArrayExtractor<InlineeSourceLine>::
27 if (auto EC = Reader.readObject(Item.Header))
32 if (auto EC = Reader.readInteger(ExtraFileCount))
34 if (auto EC = Reader.readArray(Item.ExtraFiles, ExtraFileCount))
39 return Error::success();
45 Error DebugInlineeLinesSubsectionRef::initialize(BinaryStreamReader Reader) {
46 if (auto EC = Reader.readEnum(Signature))
50 if (auto EC = Reader.readArray(Lines, Reader.bytesRemaining()))
54 return Error::success();
83 Error DebugInlineeLinesSubsection::commit(BinaryStreamWriter &Writer) const {
88 if (auto EC = Writer.writeEnum(Sig))
92 if (auto EC = Writer.writeObject(E.Header))
98 if (auto EC = Writer.writeInteger<uint32_t>(E.ExtraFiles.size()))
100 if (auto EC = Writer.writeArray(makeArrayRef(E.ExtraFiles)))
104 return Error::success();
lib/DebugInfo/CodeView/DebugLinesSubsection.cpp 23 Error LineColumnExtractor::operator()(BinaryStreamRef Stream, uint32_t &Len,
27 if (auto EC = Reader.readObject(BlockHeader))
44 if (auto EC = Reader.readArray(Item.LineNumbers, BlockHeader->NumLines))
47 if (auto EC = Reader.readArray(Item.Columns, BlockHeader->NumLines))
50 return Error::success();
56 Error DebugLinesSubsectionRef::initialize(BinaryStreamReader Reader) {
57 if (auto EC = Reader.readObject(Header))
61 if (auto EC = Reader.readArray(LinesAndColumns, Reader.bytesRemaining()))
64 return Error::success();
103 Error DebugLinesSubsection::commit(BinaryStreamWriter &Writer) const {
110 if (auto EC = Writer.writeObject(Header))
123 if (auto EC = Writer.writeObject(BlockHeader))
126 if (auto EC = Writer.writeArray(makeArrayRef(B.Lines)))
130 if (auto EC = Writer.writeArray(makeArrayRef(B.Columns)))
134 return Error::success();
lib/DebugInfo/CodeView/DebugStringTableSubsection.cpp 25 Error DebugStringTableSubsectionRef::initialize(BinaryStreamRef Contents) {
27 return Error::success();
30 Error DebugStringTableSubsectionRef::initialize(BinaryStreamReader &Reader) {
39 if (auto EC = Reader.readCString(Result))
64 Error DebugStringTableSubsection::commit(BinaryStreamWriter &Writer) const {
69 if (auto EC = Writer.writeCString(StringRef()))
76 if (auto EC = Writer.writeCString(S))
83 return Error::success();
lib/DebugInfo/CodeView/DebugSubsectionRecord.cpp 30 Error DebugSubsectionRecord::initialize(BinaryStreamRef Stream,
35 if (auto EC = Reader.readObject(Header))
40 if (auto EC = Reader.readStreamRef(Info.Data, Header->Length))
44 return Error::success();
71 Error DebugSubsectionRecordBuilder::commit(BinaryStreamWriter &Writer) const {
83 if (auto EC = Writer.writeObject(Header))
86 if (auto EC = Subsection->commit(Writer))
89 if (auto EC = Writer.writeStreamRef(Contents.getRecordData()))
92 if (auto EC = Writer.padToAlignment(4))
95 return Error::success();
lib/DebugInfo/CodeView/DebugSubsectionVisitor.cpp 28 Error llvm::codeview::visitDebugSubsection(
35 if (auto EC = Fragment.initialize(Reader))
42 if (auto EC = Fragment.initialize(Reader))
49 if (auto EC = Fragment.initialize(Reader))
55 if (auto EC = Section.initialize(Reader))
61 if (auto EC = Section.initialize(Reader))
67 if (auto EC = Section.initialize(Reader))
73 if (auto EC = Section.initialize(Reader))
79 if (auto EC = Section.initialize(Reader))
85 if (auto EC = Section.initialize(Reader))
lib/DebugInfo/CodeView/DebugSymbolRVASubsection.cpp 22 Error DebugSymbolRVASubsectionRef::initialize(BinaryStreamReader &Reader) {
29 Error DebugSymbolRVASubsection::commit(BinaryStreamWriter &Writer) const {
lib/DebugInfo/CodeView/DebugSymbolsSubsection.cpp 14 Error DebugSymbolsSubsectionRef::initialize(BinaryStreamReader Reader) {
22 Error DebugSymbolsSubsection::commit(BinaryStreamWriter &Writer) const {
24 if (auto EC = Writer.writeBytes(Record.RecordData))
27 return Error::success();
lib/DebugInfo/CodeView/LazyRandomTypeCollection.cpp 28 static void error(Error &&EC) {
93 auto EC = ensureTypeExists(Index);
104 if (auto EC = ensureTypeExists(Index)) {
121 if (auto EC = ensureTypeExists(Index)) {
150 Error LazyRandomTypeCollection::ensureTypeExists(TypeIndex TI) {
152 return Error::success();
170 Error LazyRandomTypeCollection::visitRangeForType(TypeIndex TI) {
201 return Error::success();
206 if (auto EC = ensureTypeExists(TI)) {
217 if (auto EC = ensureTypeExists(Prev + 1)) {
225 Error LazyRandomTypeCollection::fullScanForType(TypeIndex TI) {
261 return Error::success();
lib/DebugInfo/CodeView/RecordName.cpp 37 Error visitTypeBegin(CVType &Record) override;
38 Error visitTypeBegin(CVType &Record, TypeIndex Index) override;
39 Error visitTypeEnd(CVType &Record) override;
49 Error TypeNameComputer::visitTypeBegin(CVType &Record) {
51 return Error::success();
54 Error TypeNameComputer::visitTypeBegin(CVType &Record, TypeIndex Index) {
58 return Error::success();
61 Error TypeNameComputer::visitTypeEnd(CVType &CVR) { return Error::success(); }
61 Error TypeNameComputer::visitTypeEnd(CVType &CVR) { return Error::success(); }
63 Error TypeNameComputer::visitKnownRecord(CVType &CVR,
66 return Error::success();
69 Error TypeNameComputer::visitKnownRecord(CVRecord<TypeLeafKind> &CVR,
72 return Error::success();
75 Error TypeNameComputer::visitKnownRecord(CVType &CVR, ArgListRecord &Args) {
87 return Error::success();
90 Error TypeNameComputer::visitKnownRecord(CVType &CVR,
101 return Error::success();
104 Error TypeNameComputer::visitKnownRecord(CVType &CVR, ClassRecord &Class) {
106 return Error::success();
109 Error TypeNameComputer::visitKnownRecord(CVType &CVR, UnionRecord &Union) {
111 return Error::success();
114 Error TypeNameComputer::visitKnownRecord(CVType &CVR, EnumRecord &Enum) {
116 return Error::success();
119 Error TypeNameComputer::visitKnownRecord(CVType &CVR, ArrayRecord &AT) {
121 return Error::success();
124 Error TypeNameComputer::visitKnownRecord(CVType &CVR, VFTableRecord &VFT) {
126 return Error::success();
129 Error TypeNameComputer::visitKnownRecord(CVType &CVR, MemberFuncIdRecord &Id) {
131 return Error::success();
134 Error TypeNameComputer::visitKnownRecord(CVType &CVR, ProcedureRecord &Proc) {
138 return Error::success();
141 Error TypeNameComputer::visitKnownRecord(CVType &CVR,
147 return Error::success();
150 Error TypeNameComputer::visitKnownRecord(CVType &CVR, FuncIdRecord &Func) {
152 return Error::success();
155 Error TypeNameComputer::visitKnownRecord(CVType &CVR, TypeServer2Record &TS) {
157 return Error::success();
160 Error TypeNameComputer::visitKnownRecord(CVType &CVR, PointerRecord &Ptr) {
189 return Error::success();
192 Error TypeNameComputer::visitKnownRecord(CVType &CVR, ModifierRecord &Mod) {
202 return Error::success();
205 Error TypeNameComputer::visitKnownRecord(CVType &CVR,
208 return Error::success();
211 Error TypeNameComputer::visitKnownRecord(
213 return Error::success();
216 Error TypeNameComputer::visitKnownRecord(CVType &CVR,
218 return Error::success();
221 Error TypeNameComputer::visitKnownRecord(CVType &CVR, BitFieldRecord &BF) {
222 return Error::success();
225 Error TypeNameComputer::visitKnownRecord(CVType &CVR,
227 return Error::success();
230 Error TypeNameComputer::visitKnownRecord(CVType &CVR, BuildInfoRecord &BI) {
231 return Error::success();
234 Error TypeNameComputer::visitKnownRecord(CVType &CVR, LabelRecord &R) {
235 return Error::success();
238 Error TypeNameComputer::visitKnownRecord(CVType &CVR,
240 return Error::success();
243 Error TypeNameComputer::visitKnownRecord(CVType &CVR,
245 return Error::success();
252 if (auto EC = visitTypeRecord(Record, Index, Computer)) {
lib/DebugInfo/CodeView/RecordSerialization.cpp 36 Error llvm::codeview::consume(BinaryStreamReader &Reader, APSInt &Num) {
40 if (auto EC = Reader.readInteger(Short))
46 return Error::success();
52 if (auto EC = Reader.readInteger(N))
55 return Error::success();
59 if (auto EC = Reader.readInteger(N))
62 return Error::success();
66 if (auto EC = Reader.readInteger(N))
69 return Error::success();
73 if (auto EC = Reader.readInteger(N))
76 return Error::success();
80 if (auto EC = Reader.readInteger(N))
83 return Error::success();
87 if (auto EC = Reader.readInteger(N))
90 return Error::success();
94 if (auto EC = Reader.readInteger(N))
97 return Error::success();
104 Error llvm::codeview::consume(StringRef &Data, APSInt &Num) {
108 auto EC = consume(SR, Num);
114 Error llvm::codeview::consume_numeric(BinaryStreamReader &Reader,
117 if (auto EC = consume(Reader, N))
123 return Error::success();
126 Error llvm::codeview::consume(BinaryStreamReader &Reader, uint32_t &Item) {
130 Error llvm::codeview::consume(StringRef &Data, uint32_t &Item) {
134 auto EC = consume(SR, Item);
139 Error llvm::codeview::consume(BinaryStreamReader &Reader, int32_t &Item) {
143 Error llvm::codeview::consume(BinaryStreamReader &Reader, StringRef &Item) {
lib/DebugInfo/CodeView/SymbolDumper.cpp 44 Error visitSymbolBegin(CVSymbol &Record) override;
45 Error visitSymbolEnd(CVSymbol &Record) override;
46 Error visitUnknownSymbol(CVSymbol &Record) override;
103 Error CVSymbolDumperImpl::visitSymbolBegin(CVSymbol &CVR) {
108 return Error::success();
111 Error CVSymbolDumperImpl::visitSymbolEnd(CVSymbol &CVR) {
117 return Error::success();
120 Error CVSymbolDumperImpl::visitKnownRecord(CVSymbol &CVR, BlockSym &Block) {
132 return Error::success();
135 Error CVSymbolDumperImpl::visitKnownRecord(CVSymbol &CVR, Thunk32Sym &Thunk) {
144 return Error::success();
147 Error CVSymbolDumperImpl::visitKnownRecord(CVSymbol &CVR,
155 return Error::success();
158 Error CVSymbolDumperImpl::visitKnownRecord(CVSymbol &CVR, SectionSym &Section) {
168 return Error::success();
171 Error CVSymbolDumperImpl::visitKnownRecord(CVSymbol &CVR,
180 return Error::success();
183 Error CVSymbolDumperImpl::visitKnownRecord(CVSymbol &CVR,
188 return Error::success();
191 Error CVSymbolDumperImpl::visitKnownRecord(CVSymbol &CVR,
194 return Error::success();
197 Error CVSymbolDumperImpl::visitKnownRecord(CVSymbol &CVR,
209 return Error::success();
212 Error CVSymbolDumperImpl::visitKnownRecord(CVSymbol &CVR,
218 return Error::success();
221 Error CVSymbolDumperImpl::visitKnownRecord(CVSymbol &CVR,
227 return Error::success();
230 Error CVSymbolDumperImpl::visitKnownRecord(CVSymbol &CVR, ExportSym &Export) {
234 return Error::success();
237 Error CVSymbolDumperImpl::visitKnownRecord(CVSymbol &CVR,
258 return Error::success();
261 Error CVSymbolDumperImpl::visitKnownRecord(CVSymbol &CVR,
285 return Error::success();
288 Error CVSymbolDumperImpl::visitKnownRecord(CVSymbol &CVR,
293 return Error::success();
296 Error CVSymbolDumperImpl::visitKnownRecord(CVSymbol &CVR, DataSym &Data) {
306 return Error::success();
309 Error CVSymbolDumperImpl::visitKnownRecord(
313 return Error::success();
316 Error CVSymbolDumperImpl::visitKnownRecord(
322 return Error::success();
325 Error CVSymbolDumperImpl::visitKnownRecord(
336 return Error::success();
339 Error CVSymbolDumperImpl::visitKnownRecord(
347 return Error::success();
350 Error CVSymbolDumperImpl::visitKnownRecord(
359 return Error::success();
362 Error CVSymbolDumperImpl::visitKnownRecord(
378 return Error::success();
381 Error CVSymbolDumperImpl::visitKnownRecord(CVSymbol &CVR,
395 return Error::success();
398 Error CVSymbolDumperImpl::visitKnownRecord(CVSymbol &CVR,
411 return Error::success();
414 Error CVSymbolDumperImpl::visitKnownRecord(CVSymbol &CVR,
432 return Error::success();
435 Error CVSymbolDumperImpl::visitKnownRecord(
448 return Error::success();
451 Error CVSymbolDumperImpl::visitKnownRecord(CVSymbol &CVR,
503 return Error::success();
506 Error CVSymbolDumperImpl::visitKnownRecord(CVSymbol &CVR,
512 return Error::success();
515 Error CVSymbolDumperImpl::visitKnownRecord(CVSymbol &CVR, PublicSym32 &Public) {
520 return Error::success();
523 Error CVSymbolDumperImpl::visitKnownRecord(CVSymbol &CVR, ProcRefSym &ProcRef) {
528 return Error::success();
531 Error CVSymbolDumperImpl::visitKnownRecord(CVSymbol &CVR, LabelSym &Label) {
543 return Error::success();
546 Error CVSymbolDumperImpl::visitKnownRecord(CVSymbol &CVR, LocalSym &Local) {
550 return Error::success();
553 Error CVSymbolDumperImpl::visitKnownRecord(CVSymbol &CVR, ObjNameSym &ObjName) {
556 return Error::success();
559 Error CVSymbolDumperImpl::visitKnownRecord(CVSymbol &CVR, ProcSym &Proc) {
584 return Error::success();
587 Error CVSymbolDumperImpl::visitKnownRecord(CVSymbol &CVR,
590 return Error::success();
593 Error CVSymbolDumperImpl::visitKnownRecord(CVSymbol &CVR, CallerSym &Caller) {
597 return Error::success();
600 Error CVSymbolDumperImpl::visitKnownRecord(CVSymbol &CVR,
607 return Error::success();
610 Error CVSymbolDumperImpl::visitKnownRecord(CVSymbol &CVR,
621 return Error::success();
624 Error CVSymbolDumperImpl::visitKnownRecord(CVSymbol &CVR, UDTSym &UDT) {
627 return Error::success();
630 Error CVSymbolDumperImpl::visitKnownRecord(CVSymbol &CVR,
633 return Error::success();
636 Error CVSymbolDumperImpl::visitKnownRecord(CVSymbol &CVR,
645 return Error::success();
648 Error CVSymbolDumperImpl::visitUnknownSymbol(CVSymbol &CVR) {
650 return Error::success();
653 Error CVSymbolDumper::dump(CVRecord<SymbolKind> &Record) {
662 auto Err = Visitor.visitSymbolRecord(Record);
667 Error CVSymbolDumper::dump(const CVSymbolArray &Symbols) {
676 auto Err = Visitor.visitSymbolStream(Symbols);
lib/DebugInfo/CodeView/SymbolRecordMapping.cpp 20 Error operator()(CodeViewRecordIO &IO, LocalVariableAddrGap &Gap) const {
23 return Error::success();
28 static Error mapLocalVariableAddrRange(CodeViewRecordIO &IO,
33 return Error::success();
36 Error SymbolRecordMapping::visitSymbolBegin(CVSymbol &Record) {
38 return Error::success();
41 Error SymbolRecordMapping::visitSymbolEnd(CVSymbol &Record) {
44 return Error::success();
47 Error SymbolRecordMapping::visitKnownRecord(CVSymbol &CVR, BlockSym &Block) {
56 return Error::success();
59 Error SymbolRecordMapping::visitKnownRecord(CVSymbol &CVR, Thunk32Sym &Thunk) {
71 return Error::success();
74 Error SymbolRecordMapping::visitKnownRecord(CVSymbol &CVR,
84 return Error::success();
87 Error SymbolRecordMapping::visitKnownRecord(CVSymbol &CVR,
99 return Error::success();
102 Error SymbolRecordMapping::visitKnownRecord(CVSymbol &CVR,
111 return Error::success();
114 Error SymbolRecordMapping::visitKnownRecord(CVSymbol &CVR,
121 return Error::success();
124 Error SymbolRecordMapping::visitKnownRecord(CVSymbol &CVR,
129 return Error::success();
132 Error SymbolRecordMapping::visitKnownRecord(CVSymbol &CVR,
141 return Error::success();
144 Error SymbolRecordMapping::visitKnownRecord(CVSymbol &CVR,
151 return Error::success();
154 Error SymbolRecordMapping::visitKnownRecord(CVSymbol &CVR,
162 return Error::success();
165 Error SymbolRecordMapping::visitKnownRecord(CVSymbol &CVR, ExportSym &Export) {
171 return Error::success();
174 Error SymbolRecordMapping::visitKnownRecord(CVSymbol &CVR,
188 return Error::success();
191 Error SymbolRecordMapping::visitKnownRecord(CVSymbol &CVR,
206 return Error::success();
209 Error SymbolRecordMapping::visitKnownRecord(CVSymbol &CVR,
216 return Error::success();
219 Error SymbolRecordMapping::visitKnownRecord(CVSymbol &CVR, DataSym &Data) {
226 return Error::success();
229 Error SymbolRecordMapping::visitKnownRecord(
236 return Error::success();
239 Error SymbolRecordMapping::visitKnownRecord(
245 return Error::success();
248 Error SymbolRecordMapping::visitKnownRecord(
257 return Error::success();
260 Error SymbolRecordMapping::visitKnownRecord(
268 return Error::success();
271 Error SymbolRecordMapping::visitKnownRecord(
280 return Error::success();
283 Error SymbolRecordMapping::visitKnownRecord(
291 return Error::success();
294 Error SymbolRecordMapping::visitKnownRecord(CVSymbol &CVR,
301 return Error::success();
304 Error SymbolRecordMapping::visitKnownRecord(CVSymbol &CVR,
312 return Error::success();
315 Error SymbolRecordMapping::visitKnownRecord(CVSymbol &CVR,
325 return Error::success();
328 Error SymbolRecordMapping::visitKnownRecord(
336 return Error::success();
339 Error SymbolRecordMapping::visitKnownRecord(CVSymbol &CVR,
347 return Error::success();
350 Error SymbolRecordMapping::visitKnownRecord(CVSymbol &CVR,
357 return Error::success();
360 Error SymbolRecordMapping::visitKnownRecord(CVSymbol &CVR,
368 return Error::success();
371 Error SymbolRecordMapping::visitKnownRecord(CVSymbol &CVR,
379 return Error::success();
382 Error SymbolRecordMapping::visitKnownRecord(CVSymbol &CVR, LabelSym &Label) {
389 return Error::success();
392 Error SymbolRecordMapping::visitKnownRecord(CVSymbol &CVR, LocalSym &Local) {
397 return Error::success();
400 Error SymbolRecordMapping::visitKnownRecord(CVSymbol &CVR,
406 return Error::success();
409 Error SymbolRecordMapping::visitKnownRecord(CVSymbol &CVR, ProcSym &Proc) {
421 return Error::success();
424 Error SymbolRecordMapping::visitKnownRecord(CVSymbol &CVR,
426 return Error::success();
429 Error SymbolRecordMapping::visitKnownRecord(CVSymbol &CVR, CallerSym &Caller) {
433 return Error::success();
436 Error SymbolRecordMapping::visitKnownRecord(CVSymbol &CVR,
444 return Error::success();
447 Error SymbolRecordMapping::visitKnownRecord(CVSymbol &CVR,
455 return Error::success();
458 Error SymbolRecordMapping::visitKnownRecord(CVSymbol &CVR, UDTSym &UDT) {
463 return Error::success();
466 Error SymbolRecordMapping::visitKnownRecord(CVSymbol &CVR,
471 return Error::success();
474 Error SymbolRecordMapping::visitKnownRecord(CVSymbol &CVR,
483 return Error::success();
lib/DebugInfo/CodeView/SymbolSerializer.cpp 26 Error SymbolSerializer::visitSymbolBegin(CVSymbol &Record) {
31 if (auto EC = writeRecordPrefix(Record.kind()))
35 if (auto EC = Mapping.visitSymbolBegin(Record))
38 return Error::success();
41 Error SymbolSerializer::visitSymbolEnd(CVSymbol &Record) {
44 if (auto EC = Mapping.visitSymbolEnd(Record))
50 if (auto EC = Writer.writeInteger(Length))
58 return Error::success();
lib/DebugInfo/CodeView/TypeDumpVisitor.cpp 169 Error TypeDumpVisitor::visitTypeBegin(CVType &Record) {
173 Error TypeDumpVisitor::visitTypeBegin(CVType &Record, TypeIndex Index) {
180 return Error::success();
183 Error TypeDumpVisitor::visitTypeEnd(CVType &Record) {
189 return Error::success();
192 Error TypeDumpVisitor::visitMemberBegin(CVMemberRecord &Record) {
198 return Error::success();
201 Error TypeDumpVisitor::visitMemberEnd(CVMemberRecord &Record) {
207 return Error::success();
210 Error TypeDumpVisitor::visitKnownRecord(CVType &CVR,
212 if (auto EC = codeview::visitMemberRecordStream(FieldList.Data, *this))
215 return Error::success();
218 Error TypeDumpVisitor::visitKnownRecord(CVType &CVR, StringIdRecord &String) {
221 return Error::success();
224 Error TypeDumpVisitor::visitKnownRecord(CVType &CVR, ArgListRecord &Args) {
232 return Error::success();
235 Error TypeDumpVisitor::visitKnownRecord(CVType &CVR, StringListRecord &Strs) {
243 return Error::success();
246 Error TypeDumpVisitor::visitKnownRecord(CVType &CVR, ClassRecord &Class) {
257 return Error::success();
260 Error TypeDumpVisitor::visitKnownRecord(CVType &CVR, UnionRecord &Union) {
269 return Error::success();
272 Error TypeDumpVisitor::visitKnownRecord(CVType &CVR, EnumRecord &Enum) {
282 return Error::success();
285 Error TypeDumpVisitor::visitKnownRecord(CVType &CVR, ArrayRecord &AT) {
290 return Error::success();
293 Error TypeDumpVisitor::visitKnownRecord(CVType &CVR, VFTableRecord &VFT) {
300 return Error::success();
303 Error TypeDumpVisitor::visitKnownRecord(CVType &CVR, MemberFuncIdRecord &Id) {
307 return Error::success();
310 Error TypeDumpVisitor::visitKnownRecord(CVType &CVR, ProcedureRecord &Proc) {
318 return Error::success();
321 Error TypeDumpVisitor::visitKnownRecord(CVType &CVR, MemberFunctionRecord &MF) {
332 return Error::success();
335 Error TypeDumpVisitor::visitKnownRecord(CVType &CVR,
344 return Error::success();
347 Error TypeDumpVisitor::visitKnownRecord(CVType &CVR, FuncIdRecord &Func) {
351 return Error::success();
354 Error TypeDumpVisitor::visitKnownRecord(CVType &CVR, TypeServer2Record &TS) {
358 return Error::success();
361 Error TypeDumpVisitor::visitKnownRecord(CVType &CVR, PointerRecord &Ptr) {
384 return Error::success();
387 Error TypeDumpVisitor::visitKnownRecord(CVType &CVR, ModifierRecord &Mod) {
392 return Error::success();
395 Error TypeDumpVisitor::visitKnownRecord(CVType &CVR, BitFieldRecord &BitField) {
399 return Error::success();
402 Error TypeDumpVisitor::visitKnownRecord(CVType &CVR,
405 return Error::success();
408 Error TypeDumpVisitor::visitKnownRecord(CVType &CVR,
413 return Error::success();
416 Error TypeDumpVisitor::visitKnownRecord(CVType &CVR,
422 return Error::success();
425 Error TypeDumpVisitor::visitKnownRecord(CVType &CVR, BuildInfoRecord &Args) {
432 return Error::success();
454 Error TypeDumpVisitor::visitUnknownMember(CVMemberRecord &Record) {
456 return Error::success();
459 Error TypeDumpVisitor::visitUnknownType(CVType &Record) {
462 return Error::success();
465 Error TypeDumpVisitor::visitKnownMember(CVMemberRecord &CVR,
469 return Error::success();
472 Error TypeDumpVisitor::visitKnownMember(CVMemberRecord &CVR,
481 return Error::success();
484 Error TypeDumpVisitor::visitKnownMember(CVMemberRecord &CVR,
489 return Error::success();
492 Error TypeDumpVisitor::visitKnownMember(CVMemberRecord &CVR,
499 return Error::success();
502 Error TypeDumpVisitor::visitKnownMember(CVMemberRecord &CVR,
508 return Error::success();
511 Error TypeDumpVisitor::visitKnownMember(CVMemberRecord &CVR,
514 return Error::success();
517 Error TypeDumpVisitor::visitKnownMember(CVMemberRecord &CVR,
523 return Error::success();
526 Error TypeDumpVisitor::visitKnownMember(CVMemberRecord &CVR,
532 return Error::success();
535 Error TypeDumpVisitor::visitKnownMember(CVMemberRecord &CVR,
543 return Error::success();
546 Error TypeDumpVisitor::visitKnownMember(CVMemberRecord &CVR,
549 return Error::success();
552 Error TypeDumpVisitor::visitKnownRecord(CVType &CVR, LabelRecord &LR) {
554 return Error::success();
557 Error TypeDumpVisitor::visitKnownRecord(CVType &CVR,
563 return Error::success();
566 Error TypeDumpVisitor::visitKnownRecord(CVType &CVR,
569 return Error::success();
lib/DebugInfo/CodeView/TypeRecordHelpers.cpp 20 if (auto EC = TypeDeserializer::deserializeAs<RecordT>(CVT, Record)) {
lib/DebugInfo/CodeView/TypeRecordMapping.cpp 122 Error operator()(CodeViewRecordIO &IO, OneMethodRecord &Method) const {
139 return Error::success();
147 static Error mapNameAndUniqueName(CodeViewRecordIO &IO, StringRef &Name,
184 return Error::success();
187 Error TypeRecordMapping::visitTypeBegin(CVType &CVR) {
209 return Error::success();
212 Error TypeRecordMapping::visitTypeBegin(CVType &CVR, TypeIndex Index) {
219 Error TypeRecordMapping::visitTypeEnd(CVType &Record) {
226 return Error::success();
229 Error TypeRecordMapping::visitMemberBegin(CVMemberRecord &Record) {
252 return Error::success();
255 Error TypeRecordMapping::visitMemberEnd(CVMemberRecord &Record) {
260 if (auto EC = IO.skipPadding())
266 return Error::success();
269 Error TypeRecordMapping::visitKnownRecord(CVType &CVR, ModifierRecord &Record) {
275 return Error::success();
278 Error TypeRecordMapping::visitKnownRecord(CVType &CVR,
291 return Error::success();
294 Error TypeRecordMapping::visitKnownRecord(CVType &CVR,
310 return Error::success();
313 Error TypeRecordMapping::visitKnownRecord(CVType &CVR, ArgListRecord &Record) {
320 return Error::success();
323 Error TypeRecordMapping::visitKnownRecord(CVType &CVR,
332 return Error::success();
335 Error TypeRecordMapping::visitKnownRecord(CVType &CVR, PointerRecord &Record) {
383 return Error::success();
386 Error TypeRecordMapping::visitKnownRecord(CVType &CVR, ArrayRecord &Record) {
392 return Error::success();
395 Error TypeRecordMapping::visitKnownRecord(CVType &CVR, ClassRecord &Record) {
412 return Error::success();
415 Error TypeRecordMapping::visitKnownRecord(CVType &CVR, UnionRecord &Record) {
426 return Error::success();
429 Error TypeRecordMapping::visitKnownRecord(CVType &CVR, EnumRecord &Record) {
440 return Error::success();
443 Error TypeRecordMapping::visitKnownRecord(CVType &CVR, BitFieldRecord &Record) {
448 return Error::success();
451 Error TypeRecordMapping::visitKnownRecord(CVType &CVR,
477 return Error::success();
480 Error TypeRecordMapping::visitKnownRecord(CVType &CVR, VFTableRecord &Record) {
497 return Error::success();
500 Error TypeRecordMapping::visitKnownRecord(CVType &CVR, StringIdRecord &Record) {
504 return Error::success();
507 Error TypeRecordMapping::visitKnownRecord(CVType &CVR,
513 return Error::success();
516 Error TypeRecordMapping::visitKnownRecord(CVType &CVR,
523 return Error::success();
526 Error TypeRecordMapping::visitKnownRecord(CVType &CVR, FuncIdRecord &Record) {
531 return Error::success();
534 Error TypeRecordMapping::visitKnownRecord(CVType &CVR,
540 return Error::success();
543 Error TypeRecordMapping::visitKnownRecord(CVType &CVR,
552 return Error::success();
555 Error TypeRecordMapping::visitKnownRecord(CVType &CVR,
561 return Error::success();
564 Error TypeRecordMapping::visitKnownRecord(CVType &CVR,
567 if (auto EC = codeview::visitMemberRecordStream(Record.Data, *this))
572 return Error::success();
575 Error TypeRecordMapping::visitKnownRecord(CVType &CVR,
580 return Error::success();
583 Error TypeRecordMapping::visitKnownRecord(CVType &CVR, LabelRecord &Record) {
587 return Error::success();
590 Error TypeRecordMapping::visitKnownMember(CVMemberRecord &CVR,
598 return Error::success();
601 Error TypeRecordMapping::visitKnownMember(CVMemberRecord &CVR,
611 return Error::success();
614 Error TypeRecordMapping::visitKnownMember(CVMemberRecord &CVR,
623 return Error::success();
626 Error TypeRecordMapping::visitKnownMember(CVMemberRecord &CVR,
632 return Error::success();
635 Error TypeRecordMapping::visitKnownMember(CVMemberRecord &CVR,
642 Error TypeRecordMapping::visitKnownMember(CVMemberRecord &CVR,
649 return Error::success();
652 Error TypeRecordMapping::visitKnownMember(CVMemberRecord &CVR,
661 return Error::success();
664 Error TypeRecordMapping::visitKnownMember(CVMemberRecord &CVR,
675 return Error::success();
678 Error TypeRecordMapping::visitKnownMember(CVMemberRecord &CVR,
684 return Error::success();
687 Error TypeRecordMapping::visitKnownMember(CVMemberRecord &CVR,
693 return Error::success();
696 Error TypeRecordMapping::visitKnownRecord(CVType &CVR,
702 return Error::success();
705 Error TypeRecordMapping::visitKnownRecord(CVType &CVR,
708 return Error::success();
lib/DebugInfo/CodeView/TypeStreamMerger.cpp 77 Error mergeTypesAndIds(MergingTypeTableBuilder &DestIds,
80 Error mergeIdRecords(MergingTypeTableBuilder &Dest,
83 Error mergeTypeRecords(MergingTypeTableBuilder &Dest,
87 Error mergeTypesAndIds(GlobalTypeTableBuilder &DestIds,
92 Error mergeIdRecords(GlobalTypeTableBuilder &Dest,
96 Error mergeTypeRecords(GlobalTypeTableBuilder &Dest, const CVTypeArray &Types,
101 Error doit(const CVTypeArray &Types);
103 Error remapAllTypes(const CVTypeArray &Types);
105 Error remapType(const CVType &Type);
162 Error errorCorruptRecord() const {
168 Optional<Error> LastError;
255 Error TypeStreamMerger::mergeTypeRecords(MergingTypeTableBuilder &Dest,
263 Error TypeStreamMerger::mergeIdRecords(MergingTypeTableBuilder &Dest,
273 Error TypeStreamMerger::mergeTypesAndIds(MergingTypeTableBuilder &DestIds,
280 auto Err = doit(IdsAndTypes);
286 Error TypeStreamMerger::mergeTypeRecords(GlobalTypeTableBuilder &Dest,
293 auto Err = doit(Types);
298 Error TypeStreamMerger::mergeIdRecords(GlobalTypeTableBuilder &Dest,
310 Error TypeStreamMerger::mergeTypesAndIds(GlobalTypeTableBuilder &DestIds,
319 auto Err = doit(IdsAndTypes);
324 Error TypeStreamMerger::doit(const CVTypeArray &Types) {
325 if (auto EC = remapAllTypes(Types))
341 if (auto EC = remapAllTypes(Types))
354 return Error::success();
357 Error TypeStreamMerger::remapAllTypes(const CVTypeArray &Types) {
366 Error TypeStreamMerger::remapType(const CVType &Type) {
397 return Error::success();
428 Error llvm::codeview::mergeTypeRecords(MergingTypeTableBuilder &Dest,
435 Error llvm::codeview::mergeIdRecords(MergingTypeTableBuilder &Dest,
443 Error llvm::codeview::mergeTypeAndIdRecords(
451 Error llvm::codeview::mergeTypeAndIdRecords(
460 Error llvm::codeview::mergeTypeRecords(GlobalTypeTableBuilder &Dest,
469 Error llvm::codeview::mergeIdRecords(GlobalTypeTableBuilder &Dest,
484 if (auto EC = TypeDeserializer::deserializeAs(const_cast<CVType &>(Type),
lib/DebugInfo/DWARF/DWARFAcceleratorTable.cpp 44 Error AppleAcceleratorTable::extract() {
79 return Error::success();
379 Error DWARFDebugNames::Header::extract(const DWARFDataExtractor &AS,
404 return Error::success();
483 Error DWARFDebugNames::NameIndex::extract() {
486 if (Error E = Hdr.extract(AS, &Offset))
514 return Error::success();
759 Error DWARFDebugNames::extract() {
763 if (Error E = Next.extract())
768 return Error::success();
lib/DebugInfo/DWARF/DWARFContext.cpp 250 if (Error Err = AddrTable.extract(AddrData, &Offset, Version, AddrSize,
274 if (Error Err = Rnglists.extract(rnglistData, &Offset)) {
296 if (Error E = Header.extract(Data, &Offset)) {
521 if (Error E = rangeList.extract(rangesData, &offset)) {
803 if (Error E = Cache->extract())
846 DWARFUnit *U, std::function<void(Error)> RecoverableErrorCallback) {
1273 static Error createError(const Twine &Reason, llvm::Error E) {
1273 static Error createError(const Twine &Reason, llvm::Error E) {
1353 ErrorPolicy DWARFContext::defaultErrorHandler(Error E) {
1465 Error maybeDecompress(const object::SectionRef &Sec, StringRef Name,
1468 return Error::success();
1476 if (auto Err = Decompressor->resizeAndDecompress(Out))
1482 return Error::success();
1505 function_ref<ErrorPolicy(Error)> HandleError)
1552 if (auto Err = maybeDecompress(Section, Name, Data)) {
1817 function_ref<ErrorPolicy(Error)> HandleError,
1831 Error DWARFContext::loadRegisterInfo(const object::ObjectFile &Obj) {
1845 return Error::success();
1862 void DWARFContext::dumpWarning(Error Warning) {
lib/DebugInfo/DWARF/DWARFDataExtractor.cpp 17 Error *Err) const {
lib/DebugInfo/DWARF/DWARFDebugAddr.cpp 21 Error DWARFDebugAddrTable::extract(DWARFDataExtractor Data,
25 std::function<void(Error)> WarnCallback) {
138 return Error::success();
lib/DebugInfo/DWARF/DWARFDebugFrame.cpp 37 Error CFIProgram::parse(DWARFDataExtractor Data, uint64_t *Offset,
155 return Error::success();
523 if (Error E =
lib/DebugInfo/DWARF/DWARFDebugLine.cpp 225 static Error
323 return Error::success();
326 Error DWARFDebugLine::Prologue::parse(const DWARFDataExtractor &DebugLineData,
376 if (Error e = parseV5DirFileTables(
398 return Error::success();
513 const DWARFUnit *U, std::function<void(Error)> RecoverableErrorCallback) {
523 if (Error Err =
531 Error DWARFDebugLine::LineTable::parse(
534 std::function<void(Error)> RecoverableErrorCallback, raw_ostream *OS) {
539 Error PrologueErr = Prologue.parse(DebugLineData, OffsetPtr, Ctx, U);
906 return Error::success();
1132 function_ref<void(Error)> RecoverableErrorCallback,
1133 function_ref<void(Error)> UnrecoverableErrorCallback, raw_ostream *OS) {
1139 if (Error Err = LT.parse(DebugLineData, &Offset, Context, U,
1147 function_ref<void(Error)> ErrorCallback) {
1153 if (Error Err = LT.Prologue.parse(DebugLineData, &Offset, Context, U))
lib/DebugInfo/DWARF/DWARFDebugLoc.cpp 106 if (Error Err = C.takeError())
193 if (Error Err = C.takeError())
lib/DebugInfo/DWARF/DWARFDebugRangeList.cpp 25 Error DWARFDebugRangeList::extract(const DWARFDataExtractor &data,
57 return Error::success();
lib/DebugInfo/DWARF/DWARFDebugRnglists.cpp 19 Error RangeListEntry::extract(DWARFDataExtractor Data, uint64_t End,
112 return Error::success();
lib/DebugInfo/DWARF/DWARFListTable.cpp 18 Error DWARFListTableHeader::extract(DWARFDataExtractor Data,
86 return Error::success();
lib/DebugInfo/DWARF/DWARFUnit.cpp 323 if (Error E = Table.extractHeaderAndOffsets(DA, &Offset))
328 Error DWARFUnit::extractRangeList(uint64_t RangeListOffset,
407 if (Error e = tryExtractDIEsIfNeeded(CUDieOnly))
411 Error DWARFUnit::tryExtractDIEsIfNeeded(bool CUDieOnly) {
414 return Error::success(); // Already parsed.
420 return Error::success();
424 return Error::success();
492 return Error::success();
558 if (Error E = extractRangeList(Offset, RangeList))
lib/DebugInfo/DWARF/DWARFVerifier.cpp 825 if (Error E = AccelTable.extract()) {
1430 if (Error E = AccelTable.extract()) {
lib/DebugInfo/GSYM/FunctionInfo.cpp 114 llvm::Error err = OptLineTable->encode(O, Range.Start);
132 llvm::Error err = Inline->encode(O, Range.Start);
lib/DebugInfo/GSYM/GsymCreator.cpp 43 llvm::Error GsymCreator::save(StringRef Path,
53 llvm::Error GsymCreator::encode(FileWriter &O) const {
94 llvm::Error Err = Hdr.encode(O);
157 llvm::Error GsymCreator::finalize(llvm::raw_ostream &OS) {
244 return Error::success();
lib/DebugInfo/GSYM/GsymReader.cpp 56 llvm::Error Err = GR.parse();
62 llvm::Error
102 if (Error Err = Hdr->checkForError())
198 return Error::success();
lib/DebugInfo/GSYM/Header.cpp 41 llvm::Error Header::checkForError() const {
61 return Error::success();
80 if (llvm::Error Err = H.checkForError())
85 llvm::Error Header::encode(FileWriter &O) const {
87 if (llvm::Error Err = checkForError())
98 return Error::success();
lib/DebugInfo/GSYM/InlineInfo.cpp 122 llvm::Error InlineInfo::encode(FileWriter &O, uint64_t BaseAddr) const {
148 llvm::Error Err = Child.encode(O, ChildBaseAddr);
158 return Error::success();
lib/DebugInfo/GSYM/LineTable.cpp 54 static llvm::Error parse(DataExtractor &Data, uint64_t BaseAddr,
96 return Error::success();
114 return Error::success();
119 return Error::success();
122 llvm::Error LineTable::encode(FileWriter &Out, uint64_t BaseAddr) const {
245 return Error::success();
254 llvm::Error Err = parse(Data, BaseAddr, [&](const LineEntry &Row) -> bool {
268 llvm::Error Err = parse(Data, BaseAddr,
lib/DebugInfo/MSF/MSFBuilder.cpp 61 Error MSFBuilder::setBlockMapAddr(uint32_t Addr) {
63 return Error::success();
79 return Error::success();
86 Error MSFBuilder::setDirectoryBlocksHint(ArrayRef<uint32_t> DirBlocks) {
98 return Error::success();
101 Error MSFBuilder::allocateBlocks(uint32_t NumBlocks,
104 return Error::success();
141 return Error::success();
185 if (auto EC = allocateBlocks(ReqBlocks, NewBlocks))
191 Error MSFBuilder::setStreamSize(uint32_t Idx, uint32_t Size) {
194 return Error::success();
204 if (auto EC = allocateBlocks(AddedBlocks, AddedBlockList))
221 return Error::success();
269 if (auto EC = allocateBlocks(NumExtraBlocks, ExtraBlocks))
348 if (auto EC = OutFileOrError.takeError())
355 if (auto EC = Writer.writeObject(*Layout.SB))
363 if (auto EC = Writer.writeArray(Layout.DirectoryBlocks))
369 if (auto EC = DW.writeInteger<uint32_t>(Layout.StreamSizes.size()))
372 if (auto EC = DW.writeArray(Layout.StreamSizes))
376 if (auto EC = DW.writeArray(Blocks))
lib/DebugInfo/MSF/MSFCommon.cpp 19 Error llvm::msf::validateSuperBlock(const SuperBlock &SB) {
59 return Error::success();
lib/DebugInfo/MSF/MappedBlockStream.cpp 88 Error MappedBlockStream::readBytes(uint32_t Offset, uint32_t Size,
91 if (auto EC = checkOffsetForRead(Offset, Size))
95 return Error::success();
103 return Error::success();
144 return Error::success();
152 if (auto EC = readBytes(Offset, MutableArrayRef<uint8_t>(WriteBuffer, Size)))
163 return Error::success();
166 Error MappedBlockStream::readLongestContiguousChunk(uint32_t Offset,
169 if (auto EC = checkOffsetForRead(Offset, 1))
188 if (auto EC = MsfData.readBytes(MsfOffset, BlockSize, BlockData))
193 return Error::success();
230 if (auto EC = MsfData.readBytes(MsfOffset, BlockSize, BlockData)) {
239 Error MappedBlockStream::readBytes(uint32_t Offset,
245 if (auto EC = checkOffsetForRead(Offset, Buffer.size()))
256 if (auto EC = MsfData.readBytes(Offset, BlockSize, BlockData))
269 return Error::success();
373 Error WritableMappedBlockStream::readBytes(uint32_t Offset, uint32_t Size,
378 Error WritableMappedBlockStream::readLongestContiguousChunk(
387 Error WritableMappedBlockStream::writeBytes(uint32_t Offset,
390 if (auto EC = checkOffsetForWrite(Offset, Buffer.size()))
407 if (auto EC = WriteInterface.writeBytes(MsfOffset, ChunkData))
418 return Error::success();
421 Error WritableMappedBlockStream::commit() { return WriteInterface.commit(); }
lib/DebugInfo/PDB/Native/DbiModuleDescriptor.cpp 28 Error DbiModuleDescriptor::initialize(BinaryStreamRef Stream,
31 if (auto EC = Reader.readObject(Info.Layout))
34 if (auto EC = Reader.readCString(Info.ModuleName))
37 if (auto EC = Reader.readCString(Info.ObjFileName))
39 return Error::success();
lib/DebugInfo/PDB/Native/DbiModuleDescriptorBuilder.cpp 122 Error DbiModuleDescriptorBuilder::finalizeMsfLayout() {
126 return Error::success();
132 return Error::success();
135 Error DbiModuleDescriptorBuilder::commit(BinaryStreamWriter &ModiWriter,
140 if (auto EC = ModiWriter.writeObject(Layout))
142 if (auto EC = ModiWriter.writeCString(ModuleName))
144 if (auto EC = ModiWriter.writeCString(ObjFileName))
146 if (auto EC = ModiWriter.padToAlignment(sizeof(uint32_t)))
155 if (auto EC =
159 if (auto EC = SymbolWriter.writeBytes(Syms))
167 if (auto EC = Builder->commit(SymbolWriter))
172 if (auto EC = SymbolWriter.writeInteger<uint32_t>(0))
177 return Error::success();
lib/DebugInfo/PDB/Native/DbiModuleList.cpp 162 Error DbiModuleList::initialize(BinaryStreamRef ModInfo,
164 if (auto EC = initializeModInfo(ModInfo))
166 if (auto EC = initializeFileInfo(FileInfo))
169 return Error::success();
172 Error DbiModuleList::initializeModInfo(BinaryStreamRef ModInfo) {
176 return Error::success();
180 if (auto EC = Reader.readArray(Descriptors, ModInfo.getLength()))
183 return Error::success();
186 Error DbiModuleList::initializeFileInfo(BinaryStreamRef FileInfo) {
190 return Error::success();
193 if (auto EC = FISR.readObject(FileInfoHeader))
199 if (auto EC = FISR.readArray(ModuleIndices, FileInfoHeader->NumModules))
201 if (auto EC = FISR.readArray(ModFileCountArray, FileInfoHeader->NumModules))
216 if (auto EC = FISR.readArray(FileNameOffsets, NumSourceFiles))
219 if (auto EC = FISR.readStreamRef(NamesBuffer))
238 return Error::success();
276 if (auto EC = Names.readCString(Name))
lib/DebugInfo/PDB/Native/DbiStream.cpp 34 static Error loadSectionContribs(FixedStreamArray<ContribType> &Output,
42 if (auto EC = Reader.readArray(Output, Count))
44 return Error::success();
52 Error DbiStream::reload(PDBFile *Pdb) {
58 if (auto EC = Reader.readObject(Header))
100 if (auto EC = Reader.readSubstream(ModiSubstream, Header->ModiSubstreamSize))
103 if (auto EC = Reader.readSubstream(SecContrSubstream,
106 if (auto EC = Reader.readSubstream(SecMapSubstream, Header->SectionMapSize))
108 if (auto EC = Reader.readSubstream(FileInfoSubstream, Header->FileInfoSize))
110 if (auto EC =
113 if (auto EC = Reader.readSubstream(ECSubstream, Header->ECSubstreamSize))
115 if (auto EC = Reader.readArray(
119 if (auto EC = Modules.initialize(ModiSubstream.StreamData,
123 if (auto EC = initializeSectionContributionData())
125 if (auto EC = initializeSectionHeadersData(Pdb))
127 if (auto EC = initializeSectionMapData())
129 if (auto EC = initializeOldFpoRecords(Pdb))
131 if (auto EC = initializeNewFpoRecords(Pdb))
140 if (auto EC = ECNames.reload(ECReader))
144 return Error::success();
240 Error DbiStream::initializeSectionContributionData() {
242 return Error::success();
245 if (auto EC = SCReader.readEnum(SectionContribVersion))
258 Error DbiStream::initializeSectionHeadersData(PDBFile *Pdb) {
261 if (auto EC = ExpectedStream.takeError())
266 return Error::success();
275 if (auto EC = Reader.readArray(SectionHeaders, NumSections))
280 return Error::success();
284 Error DbiStream::initializeOldFpoRecords(PDBFile *Pdb) {
287 if (auto EC = ExpectedStream.takeError())
292 return Error::success();
301 if (auto EC = Reader.readArray(OldFpoRecords, NumRecords))
305 return Error::success();
308 Error DbiStream::initializeNewFpoRecords(PDBFile *Pdb) {
311 if (auto EC = ExpectedStream.takeError())
316 return Error::success();
318 if (auto EC = NewFpoRecords.initialize(*FS))
322 return Error::success();
365 Error DbiStream::initializeSectionMapData() {
367 return Error::success();
371 if (auto EC = SMReader.readObject(Header))
373 if (auto EC = SMReader.readArray(SectionMap, Header->SecCount))
375 return Error::success();
lib/DebugInfo/PDB/Native/DbiStreamBuilder.cpp 88 Error DbiStreamBuilder::addDbgStream(pdb::DbgHeaderType Type,
98 return Error::success();
121 Error DbiStreamBuilder::addModuleSourceFile(DbiModuleDescriptorBuilder &Module,
126 return Error::success();
188 Error DbiStreamBuilder::generateFileInfoSubstream() {
202 if (auto EC = MetadataWriter.writeInteger(ModiCount)) // NumModules
204 if (auto EC = MetadataWriter.writeInteger(FileCount)) // NumSourceFiles
207 if (auto EC = MetadataWriter.writeInteger(I)) // Mod Indices
212 if (auto EC = MetadataWriter.writeInteger(FileCount)) // Mod File Counts
224 if (auto EC = NameBufferWriter.writeCString(Name.getKey()))
234 if (auto EC = MetadataWriter.writeInteger(Result->second))
239 if (auto EC = NameBufferWriter.padToAlignment(sizeof(uint32_t)))
251 return Error::success();
254 Error DbiStreamBuilder::finalize() {
256 return Error::success();
261 if (auto EC = generateFileInfoSubstream())
288 return Error::success();
291 Error DbiStreamBuilder::finalizeMsfLayout() {
322 if (auto EC = MI->finalizeMsfLayout())
327 if (auto EC = Msf.setStreamSize(StreamDBI, Length))
329 return Error::success();
391 Error DbiStreamBuilder::commit(const msf::MSFLayout &Layout,
393 if (auto EC = finalize())
400 if (auto EC = Writer.writeObject(*Header))
404 if (auto EC = M->commit(Writer, Layout, MsfBuffer))
409 if (auto EC = Writer.writeEnum(DbiSecContribVer60))
411 if (auto EC = Writer.writeArray(makeArrayRef(SectionContribs)))
418 if (auto EC = Writer.writeObject(SMHeader))
420 if (auto EC = Writer.writeArray(SectionMap))
424 if (auto EC = Writer.writeStreamRef(FileInfoBuffer))
427 if (auto EC = ECNamesBuilder.commit(Writer))
434 if (auto EC = Writer.writeInteger(StreamNumber))
447 if (auto EC = Stream->WriteFn(DbgStreamWriter))
454 return Error::success();
lib/DebugInfo/PDB/Native/GSIStreamBuilder.cpp 60 Error commit(BinaryStreamWriter &Writer);
94 Error GSIHashStreamBuilder::commit(BinaryStreamWriter &Writer) {
101 if (auto EC = Writer.writeObject(Header))
104 if (auto EC = Writer.writeArray(makeArrayRef(HashRecords)))
106 if (auto EC = Writer.writeArray(makeArrayRef(HashBitmap)))
108 if (auto EC = Writer.writeArray(makeArrayRef(HashBuckets)))
110 return Error::success();
205 Error GSIStreamBuilder::finalizeMsfLayout() {
229 return Error::success();
306 static Error writeRecords(BinaryStreamWriter &Writer,
314 Error GSIStreamBuilder::commitSymbolRecordStream(
321 if (auto EC = writeRecords(Writer, PSH->Records))
323 if (auto EC = writeRecords(Writer, GSH->Records))
326 return Error::success();
329 Error GSIStreamBuilder::commitPublicsHashStream(
343 if (auto EC = Writer.writeObject(Header))
346 if (auto EC = PSH->commit(Writer))
350 if (auto EC = Writer.writeArray(makeArrayRef(AddrMap)))
353 return Error::success();
356 Error GSIStreamBuilder::commitGlobalsHashStream(
362 Error GSIStreamBuilder::commit(const msf::MSFLayout &Layout,
371 if (auto EC = commitSymbolRecordStream(*PRS))
373 if (auto EC = commitGlobalsHashStream(*GS))
375 if (auto EC = commitPublicsHashStream(*PS))
377 return Error::success();
lib/DebugInfo/PDB/Native/GlobalsStream.cpp 40 Error GlobalsStream::reload() {
42 if (auto E = GlobalsTable.read(Reader))
44 return Error::success();
84 static Error checkHashHdrVersion(const GSIHashHeader *HashHdr) {
90 return Error::success();
93 static Error readGSIHashHeader(const GSIHashHeader *&HashHdr,
104 return Error::success();
107 static Error readGSIHashRecords(FixedStreamArray<PSHashRecord> &HashRecords,
110 if (auto EC = checkHashHdrVersion(HashHdr))
119 if (auto EC = Reader.readArray(HashRecords, NumHashRecords))
124 return Error::success();
127 static Error
133 if (auto EC = checkHashHdrVersion(HashHdr))
140 if (auto EC = Reader.readArray(HashBitmap, NumBitmapEntries))
163 if (auto EC = Reader.readArray(HashBuckets, NumBuckets))
168 return Error::success();
171 Error GSIHashTable::read(BinaryStreamReader &Reader) {
172 if (auto EC = readGSIHashHeader(HashHdr, Reader))
174 if (auto EC = readGSIHashRecords(HashRecords, HashHdr, Reader))
177 if (auto EC = readGSIHashBuckets(HashBuckets, HashBitmap, HashHdr,
180 return Error::success();
lib/DebugInfo/PDB/Native/HashTable.cpp 24 Error llvm::pdb::readSparseBitVector(BinaryStreamReader &Stream,
27 if (auto EC = Stream.readInteger(NumWords))
35 if (auto EC = Stream.readInteger(Word))
43 return Error::success();
46 Error llvm::pdb::writeSparseBitVector(BinaryStreamWriter &Writer,
52 if (auto EC = Writer.writeInteger(ReqWords))
65 if (auto EC = Writer.writeInteger(Word))
70 return Error::success();
lib/DebugInfo/PDB/Native/InfoStream.cpp 25 Error InfoStream::reload() {
28 if (auto EC = Reader.readObject(Header))
46 if (auto EC = NamedStreams.load(Reader))
52 if (auto EC = Reader.readSubstream(SubNamedStreams, NamedStreamMapByteSize))
58 if (auto EC = Reader.readEnum(Sig))
83 return Error::success();
lib/DebugInfo/PDB/Native/InfoStreamBuilder.cpp 49 Error InfoStreamBuilder::finalizeMsfLayout() {
53 if (auto EC = Msf.setStreamSize(StreamPDB, Length))
55 return Error::success();
58 Error InfoStreamBuilder::commit(const msf::MSFLayout &Layout,
69 if (auto EC = Writer.writeObject(H))
72 if (auto EC = NamedStreams.commit(Writer))
74 if (auto EC = Writer.writeInteger(0))
77 if (auto EC = Writer.writeEnum(E))
81 return Error::success();
lib/DebugInfo/PDB/Native/InjectedSourceStream.cpp 28 Error InjectedSourceStream::reload(const PDBStringTable &Strings) {
31 if (auto EC = Reader.readObject(Header))
39 if (auto EC = InjectedSourceTable.load(Reader))
64 return Error::success();
lib/DebugInfo/PDB/Native/ModuleDebugStream.cpp 37 Error ModuleDebugStreamRef::reload() {
41 if (Error E = reloadSerialize(Reader))
47 return Error::success();
50 Error ModuleDebugStreamRef::reloadSerialize(BinaryStreamReader &Reader) {
61 if (auto EC = Reader.readInteger(Signature))
64 if (auto EC = Reader.readSubstream(SymbolsSubstream, SymbolSize))
66 if (auto EC = Reader.readSubstream(C11LinesSubstream, C11Size))
68 if (auto EC = Reader.readSubstream(C13LinesSubstream, C13Size))
72 if (auto EC = SymbolReader.readArray(
77 if (auto EC = SubsectionsReader.readArray(Subsections,
82 if (auto EC = Reader.readInteger(GlobalRefsSize))
84 if (auto EC = Reader.readSubstream(GlobalRefsSubstream, GlobalRefsSize))
86 return Error::success();
130 Error ModuleDebugStreamRef::commit() { return Error::success(); }
130 Error ModuleDebugStreamRef::commit() { return Error::success(); }
139 if (auto EC = Result.initialize(SS.getRecordData()))
lib/DebugInfo/PDB/Native/NamedStreamMap.cpp 51 Error NamedStreamMap::load(BinaryStreamReader &Stream) {
53 if (auto EC = Stream.readInteger(StringBufferSize))
59 if (auto EC = Stream.readFixedString(Buffer, StringBufferSize))
66 Error NamedStreamMap::commit(BinaryStreamWriter &Writer) const {
68 if (auto EC = Writer.writeInteger<uint32_t>(NamesBuffer.size()))
73 if (auto EC = Writer.writeFixedString(Data))
77 if (auto EC = OffsetIndexMap.commit(Writer))
80 return Error::success();
lib/DebugInfo/PDB/Native/NativeEnumInjectedSources.cpp 26 if (auto E = Stream.readLongestContiguousChunk(Offset, Data))
lib/DebugInfo/PDB/Native/NativeSession.cpp 59 Error NativeSession::createFromPdb(std::unique_ptr<MemoryBuffer> Buffer,
67 if (auto EC = File->parseFileHeaders())
69 if (auto EC = File->parseStreamData())
75 return Error::success();
78 Error NativeSession::createFromExe(StringRef Path,
lib/DebugInfo/PDB/Native/NativeTypeEnum.cpp 50 Error visitKnownMember(CVMemberRecord &CVM,
52 Error visitKnownMember(CVMemberRecord &CVM,
78 Error NativeEnumEnumEnumerators::visitKnownMember(CVMemberRecord &CVM,
81 return Error::success();
84 Error NativeEnumEnumEnumerators::visitKnownMember(
87 return Error::success();
lib/DebugInfo/PDB/Native/PDBFile.cpp 109 if (auto EC = Buffer->readBytes(StreamBlockOffset, NumBytes, Result))
114 Error PDBFile::setBlockData(uint32_t BlockIndex, uint32_t Offset,
120 Error PDBFile::parseFileHeaders() {
125 if (auto EC = Reader.readObject(SB)) {
131 if (auto EC = msf::validateSuperBlock(*SB))
158 if (auto EC = FpmReader.readBytes(FpmBytes, FpmReader.bytesRemaining()))
173 if (auto EC = Reader.readArray(ContainerLayout.DirectoryBlocks,
177 return Error::success();
180 Error PDBFile::parseStreamData() {
183 return Error::success();
195 if (auto EC = Reader.readInteger(NumStreams))
198 if (auto EC = Reader.readArray(ContainerLayout.StreamSizes, NumStreams))
215 if (auto EC = Reader.readArray(Blocks, NumExpectedStreamBlocks))
230 return Error::success();
268 if (auto EC = TempGlobals->reload())
281 if (auto EC = TempInfo->reload())
294 if (auto EC = TempDbi->reload(this))
307 if (auto EC = TempTpi->reload())
323 if (auto EC = TempIpi->reload())
341 if (auto EC = TempPublics->reload())
360 if (auto EC = TempSymbols->reload())
375 if (auto EC = N->reload(Reader))
395 if (auto EC = IJ->reload(*Strings))
lib/DebugInfo/PDB/Native/PDBFileBuilder.cpp 41 Error PDBFileBuilder::initialize(uint32_t BlockSize) {
46 return Error::success();
93 Error PDBFileBuilder::addNamedStream(StringRef Name, StringRef Data) {
99 return Error::success();
124 Error PDBFileBuilder::finalizeMsfLayout() {
142 if (auto EC = Gsi->finalizeMsfLayout())
151 if (auto EC = Tpi->finalizeMsfLayout())
155 if (auto EC = Dbi->finalizeMsfLayout())
163 if (auto EC = Ipi->finalizeMsfLayout())
170 if (auto EC = Info->finalizeMsfLayout())
211 if (auto EC = Info->finalizeMsfLayout())
215 return Error::success();
264 Error PDBFileBuilder::commit(StringRef Filename, codeview::GUID *Guid) {
266 if (auto EC = finalizeMsfLayout())
283 if (auto EC = Strings.commit(NSWriter))
293 if (auto EC = NSW.writeBytes(arrayRefFromStringRef(NSE.second)))
298 if (auto EC = Info->commit(Layout, Buffer))
303 if (auto EC = Dbi->commit(Layout, Buffer))
308 if (auto EC = Tpi->commit(Layout, Buffer))
313 if (auto EC = Ipi->commit(Layout, Buffer))
318 if (auto EC = Gsi->commit(Layout, Buffer))
lib/DebugInfo/PDB/Native/PDBStringTable.cpp 27 Error PDBStringTable::readHeader(BinaryStreamReader &Reader) {
28 if (auto EC = Reader.readObject(Header))
39 return Error::success();
42 Error PDBStringTable::readStrings(BinaryStreamReader &Reader) {
44 if (auto EC = Reader.readStreamRef(Stream))
47 if (auto EC = Strings.initialize(Stream)) {
54 return Error::success();
62 Error PDBStringTable::readHashTable(BinaryStreamReader &Reader) {
64 if (auto EC = Reader.readObject(HashCount))
67 if (auto EC = Reader.readArray(IDs, *HashCount)) {
73 return Error::success();
76 Error PDBStringTable::readEpilogue(BinaryStreamReader &Reader) {
77 if (auto EC = Reader.readInteger(NameCount))
81 return Error::success();
84 Error PDBStringTable::reload(BinaryStreamReader &Reader) {
89 if (auto EC = readHeader(SectionReader))
93 if (auto EC = readStrings(SectionReader))
98 if (auto EC = readHashTable(Reader))
102 if (auto EC = readEpilogue(SectionReader))
106 return Error::success();
lib/DebugInfo/PDB/Native/PDBStringTableBuilder.cpp 153 Error PDBStringTableBuilder::writeHeader(BinaryStreamWriter &Writer) const {
159 if (auto EC = Writer.writeObject(H))
162 return Error::success();
165 Error PDBStringTableBuilder::writeStrings(BinaryStreamWriter &Writer) const {
166 if (auto EC = Strings.commit(Writer))
170 return Error::success();
173 Error PDBStringTableBuilder::writeHashTable(BinaryStreamWriter &Writer) const {
176 if (auto EC = Writer.writeInteger(BucketCount))
194 if (auto EC = Writer.writeArray(ArrayRef<ulittle32_t>(Buckets)))
198 return Error::success();
201 Error PDBStringTableBuilder::writeEpilogue(BinaryStreamWriter &Writer) const {
202 if (auto EC = Writer.writeInteger<uint32_t>(Strings.size()))
205 return Error::success();
208 Error PDBStringTableBuilder::commit(BinaryStreamWriter &Writer) const {
212 if (auto EC = writeHeader(SectionWriter))
217 if (auto EC = writeStrings(SectionWriter))
221 if (auto EC = writeHashTable(SectionWriter))
225 if (auto EC = writeEpilogue(SectionWriter))
228 return Error::success();
lib/DebugInfo/PDB/Native/PublicsStream.cpp 58 Error PublicsStream::reload() {
73 if (auto E = PublicsTable.read(Reader))
78 if (auto EC = Reader.readArray(AddressMap, NumAddressMapEntries))
84 if (auto EC = Reader.readArray(ThunkMap, Header->NumThunks))
91 if (auto EC = Reader.readArray(SectionOffsets, Header->NumSections))
100 return Error::success();
lib/DebugInfo/PDB/Native/SymbolCache.cpp 114 if (auto EC = TypeDeserializer::deserializeAs<ModifierRecord>(CVT, Record)) {
lib/DebugInfo/PDB/Native/SymbolStream.cpp 27 Error SymbolStream::reload() {
30 if (auto EC = Reader.readArray(SymbolRecords, Stream->getLength()))
33 return Error::success();
41 Error SymbolStream::commit() { return Error::success(); }
41 Error SymbolStream::commit() { return Error::success(); }
lib/DebugInfo/PDB/Native/TpiHashing.cpp 45 if (auto E = TypeDeserializer::deserializeAs(const_cast<CVType &>(Rec),
54 if (auto E = TypeDeserializer::deserializeAs(const_cast<CVType &>(Rec),
80 if (auto E = TypeDeserializer::deserializeAs(const_cast<CVType &>(Rec),
lib/DebugInfo/PDB/Native/TpiStream.cpp 41 Error TpiStream::reload() {
70 if (auto EC =
75 if (auto EC =
97 if (auto EC = HSR.readArray(HashValues, NumHashValues))
103 if (auto EC = HSR.readArray(TypeIndexOffsets, NumTypeIndexOffsets))
108 if (auto EC = HashAdjusters.load(HSR))
117 return Error::success();
246 Error TpiStream::commit() { return Error::success(); }
246 Error TpiStream::commit() { return Error::success(); }
lib/DebugInfo/PDB/Native/TpiStreamBuilder.cpp 62 Error TpiStreamBuilder::finalize() {
64 return Error::success();
96 return Error::success();
113 Error TpiStreamBuilder::finalizeMsfLayout() {
115 if (auto EC = Msf.setStreamSize(Idx, Length))
122 return Error::success();
140 return Error::success();
143 Error TpiStreamBuilder::commit(const msf::MSFLayout &Layout,
145 if (auto EC = finalize())
152 if (auto EC = Writer.writeObject(*Header))
158 if (auto EC = Writer.writeBytes(Rec))
167 if (auto EC = HW.writeStreamRef(*HashValueStream))
172 if (auto EC = HW.writeObject(IndexOffset))
177 return Error::success();
lib/DebugInfo/PDB/PDB.cpp 23 Error llvm::pdb::loadDataForPDB(PDB_ReaderType Type, StringRef Path,
43 Error llvm::pdb::loadDataForEXE(PDB_ReaderType Type, StringRef Path,
lib/DebugInfo/Symbolize/Symbolize.cpp 460 if (auto Err = loadDataForEXE(PDB_ReaderType::DIA,
lib/ExecutionEngine/Interpreter/Interpreter.cpp 37 if (Error Err = M->materializeAll()) {
lib/ExecutionEngine/JITLink/EHFrameSupport.cpp 27 Error EHFrameBinaryParser::addToGraph() {
39 if (auto Err = EHFrameReader.readInteger(RecordLengthField))
54 if (auto Err = EHFrameReader.readInteger(ExtendedLengthField))
74 if (auto Err = EHFrameReader.readInteger(CIEPointer))
79 if (auto Err = processCIE(RecordOffset, RecordLength))
82 if (auto Err = processFDE(RecordOffset, RecordLength, CIEPointerAddress,
90 return Error::success();
101 if (auto Err = EHFrameReader.readInteger(NextChar))
110 if (auto Err = EHFrameReader.readInteger(NextChar))
129 if (auto Err = EHFrameReader.readInteger(NextChar))
141 if (auto Err = EHFrameReader.readInteger(Addr))
145 if (auto Err = EHFrameReader.readInteger(Addr32))
153 Error EHFrameBinaryParser::processCIE(size_t RecordOffset,
168 if (auto Err = EHFrameReader.readInteger(Version))
181 if (auto Err = EHFrameReader.skip(PointerSize))
187 if (auto Err = EHFrameReader.readULEB128(CodeAlignmentFactor))
198 if (auto Err = EHFrameReader.readSLEB128(DataAlignmentFactor))
207 if (auto Err = EHFrameReader.skip(1))
211 if (auto Err = EHFrameReader.readULEB128(AugmentationDataLength))
222 if (auto Err = EHFrameReader.readInteger(LSDAPointerEncoding))
233 if (auto Err = EHFrameReader.readInteger(PersonalityPointerEncoding))
243 if (auto Err = EHFrameReader.readInteger(PersonalityPointerAddress))
249 if (auto Err = EHFrameReader.readInteger(FDEPointerEncoding))
273 return Error::success();
276 Error EHFrameBinaryParser::processFDE(size_t RecordOffset, size_t RecordLength,
322 if (auto Err = EHFrameReader.skip(PointerSize))
329 if (auto Err = EHFrameReader.readULEB128(AugmentationDataSize))
380 Error registerFrameWrapper(const void *P) {
382 return Error::success();
385 Error deregisterFrameWrapper(const void *P) {
387 return Error::success();
469 Error registerEHFrameSection(const void *EHFrameSectionAddr,
486 Error deregisterEHFrameSection(const void *EHFrameSectionAddr,
531 return Error::success();
lib/ExecutionEngine/JITLink/EHFrameSupportImpl.h 37 Error addToGraph();
57 Error processCIE(size_t RecordOffset, size_t RecordLength);
58 Error processFDE(size_t RecordOffset, size_t RecordLength,
lib/ExecutionEngine/JITLink/JITLink.cpp 206 Error JITLinkContext::modifyPassConfig(const Triple &TT,
208 return Error::success();
211 Error markAllSymbolsLive(LinkGraph &G) {
214 return Error::success();
lib/ExecutionEngine/JITLink/JITLinkGeneric.cpp 35 if (auto Err = runPasses(Passes.PrePrunePasses))
51 if (auto Err = runPasses(Passes.PostPrunePasses))
58 if (auto Err = allocateSegments(Layout))
103 if (auto Err = copyAndFixUpBlocks(Layout, *Alloc))
111 if (auto Err = runPasses(Passes.PostFixupPasses))
124 void JITLinkerBase::linkPhase3(std::unique_ptr<JITLinkerBase> Self, Error Err) {
130 Error JITLinkerBase::runPasses(LinkGraphPassList &Passes) {
132 if (auto Err = P(*G))
134 return Error::success();
183 Error JITLinkerBase::allocateSegments(const SegmentLayoutMap &Layout) {
254 return Error::success();
289 void JITLinkerBase::deallocateAndBailOut(Error Err) {
lib/ExecutionEngine/JITLink/JITLinkGeneric.h 73 void linkPhase3(std::unique_ptr<JITLinkerBase> Self, Error Err);
99 Error runPasses(LinkGraphPassList &Passes);
103 virtual Error
108 Error allocateSegments(const SegmentLayoutMap &Layout);
111 void deallocateAndBailOut(Error Err);
147 Error
209 if (auto Err = impl().applyFixup(*B, E, BlockDataPtr))
231 return Error::success();
lib/ExecutionEngine/JITLink/JITLinkMemoryManager.cpp 40 Error deallocate() override {
42 return Error::success();
56 return Error::success();
60 Error applyProtections() {
70 return Error::success();
lib/ExecutionEngine/JITLink/MachOLinkGraphBuilder.cpp 30 if (auto Err = createNormalizedSections())
33 if (auto Err = createNormalizedSymbols())
36 if (auto Err = graphifyRegularSymbols())
39 if (auto Err = graphifySectionsWithCustomParsers())
42 if (auto Err = addRelocations())
99 Error MachOLinkGraphBuilder::createNormalizedSections() {
177 return Error::success();
200 return Error::success();
203 Error MachOLinkGraphBuilder::createNormalizedSymbols() {
280 return Error::success();
296 Error MachOLinkGraphBuilder::graphifyRegularSymbols() {
517 return Error::success();
520 Error MachOLinkGraphBuilder::graphifySectionsWithCustomParsers() {
528 if (auto Err = Parse(NSec))
533 return Error::success();
lib/ExecutionEngine/JITLink/MachOLinkGraphBuilder.h 144 using SectionParserFunction = std::function<Error(NormalizedSection &S)>;
155 virtual Error addRelocations() = 0;
241 Error createNormalizedSections();
242 Error createNormalizedSymbols();
246 Error graphifyRegularSymbols();
249 Error graphifySectionsWithCustomParsers();
lib/ExecutionEngine/JITLink/MachO_arm64.cpp 201 Error addRelocations() override {
389 return Error::success();
508 static Error targetOutOfRangeError(const Block &B, const Edge &E) {
541 Error applyFixup(Block &B, const Edge &E, char *BlockWorkingMem) const {
669 return Error::success();
689 return Error::success();
693 if (auto Err = Ctx->modifyPassConfig(TT, Config))
lib/ExecutionEngine/JITLink/MachO_x86_64.cpp 203 Error addRelocations() override {
358 return Error::success();
468 static Error targetOutOfRangeError(const Block &B, const Edge &E) {
479 Error applyFixup(Block &B, const Edge &E, char *BlockWorkingMem) const {
558 return Error::success();
578 return Error::success();
582 if (auto Err = Ctx->modifyPassConfig(TT, Config))
lib/ExecutionEngine/MCJIT/MCJIT.cpp 328 } else if (auto Err = Sym.takeError())
616 } else if (auto Err = Sym.takeError())
lib/ExecutionEngine/Orc/CompileOnDemandLayer.cpp 157 if (auto Err = PDR.getImplDylib().define(
292 if (auto Err = R.defineMaterializing(SymbolFlags))
lib/ExecutionEngine/Orc/Core.cpp 326 void AsynchronousSymbolQuery::handleFailed(Error Err) {
375 Error MaterializationResponsibility::notifyResolved(const SymbolMap &Symbols) {
393 Error MaterializationResponsibility::notifyEmitted() {
399 if (auto Err = JD.emit(SymbolFlags))
403 return Error::success();
406 Error MaterializationResponsibility::defineMaterializing(
644 if (auto Err = QueryInfo->R.notifyResolved(ResolutionMap)) {
649 if (auto Err = QueryInfo->R.notifyEmitted()) {
747 Error JITDylib::defineMaterializing(const SymbolFlagsMap &SymbolFlags) {
771 return Error::success();
917 Error JITDylib::resolve(const SymbolMap &Resolved) {
1003 return Error::success();
1006 Error JITDylib::emit(const SymbolFlagsMap &Emitted) {
1136 return Error::success();
1294 Error JITDylib::remove(const SymbolNameSet &Names) {
1345 return Error::success();
1400 Error JITDylib::lodgeQuery(std::shared_ptr<AsynchronousSymbolQuery> &Q,
1405 if (auto Err = lodgeQueryImpl(Q, Unresolved, MatchNonExported, MUs))
1438 return Error::success();
1441 Error JITDylib::lodgeQueryImpl(
1513 return Error::success();
1527 auto Err = ES.runSessionLocked([&, this]() -> Error {
1549 return Error::success();
1733 Error JITDylib::defineImpl(MaterializationUnit &MU) {
1782 return Error::success();
1852 void ExecutionSession::legacyFailQuery(AsynchronousSymbolQuery &Q, Error Err) {
1874 Error ResolutionError = Error::success();
1874 Error ResolutionError = Error::success();
1912 auto Err = make_error<SymbolsNotFound>(std::move(UnresolvedSymbols));
1957 auto LodgingErr = runSessionLocked([&]() -> Error {
1966 if (auto Err = JD.lodgeQuery(Q, Unresolved, MatchNonExported,
1974 return Error::success();
1977 if (auto Err = LodgeQuery()) {
2002 return Error::success();
2033 Error ResolutionError = Error::success();
2033 Error ResolutionError = Error::success();
lib/ExecutionEngine/Orc/ExecutionUtils.cpp 118 Error CtorDtorRunner::run() {
143 return Error::success();
164 Error LocalCXXRuntimeOverrides::enable(JITDylib &JD,
243 Error Err = Error::success();
243 Error Err = Error::success();
279 if (auto Err =
290 ObjectLayer &L, std::unique_ptr<MemoryBuffer> ArchiveBuffer, Error &Err)
297 Error Err2 = Error::success();
297 Error Err2 = Error::success();
lib/ExecutionEngine/Orc/LLJIT.cpp 18 Error LLJITBuilderState::prepareForConstruction() {
27 return Error::success();
35 Error LLJIT::defineAbsolute(StringRef Name, JITEvaluatedSymbol Sym) {
41 Error LLJIT::addIRModule(JITDylib &JD, ThreadSafeModule TSM) {
44 if (auto Err =
51 Error LLJIT::addObjectFile(JITDylib &JD, std::unique_ptr<MemoryBuffer> Obj) {
104 LLJIT::LLJIT(LLJITBuilderState &S, Error &Err)
152 Error LLJIT::applyDataLayout(Module &M) {
161 return Error::success();
169 Error LLLazyJITBuilderState::prepareForConstruction() {
170 if (auto Err = LLJITBuilderState::prepareForConstruction())
173 return Error::success();
176 Error LLLazyJIT::addLazyIRModule(JITDylib &JD, ThreadSafeModule TSM) {
179 if (auto Err = TSM.withModuleDo([&](Module &M) -> Error {
180 if (auto Err = applyDataLayout(M))
184 return Error::success();
191 LLLazyJIT::LLLazyJIT(LLLazyJITBuilderState &S, Error &Err) : LLJIT(S, Err) {
lib/ExecutionEngine/Orc/Layer.cpp 21 Error IRLayer::add(JITDylib &JD, ThreadSafeModule TSM, VModuleKey K) {
108 Error ObjectLayer::add(JITDylib &JD, std::unique_ptr<MemoryBuffer> O,
lib/ExecutionEngine/Orc/LazyReexports.cpp 74 if (auto Err = (*NotifyResolved)(*SourceJD, SymbolName, ResolvedAddr)) {
176 if (auto Err = ISManager.createStubs(StubInits)) {
lib/ExecutionEngine/Orc/ObjectLinkingLayer.cpp 45 void notifyFailed(Error Err) override {
128 if (auto Err = MR.defineMaterializing(ExtraSymbolsToClaim))
130 if (auto Err = MR.notifyResolved(InternedResult)) {
140 if (auto Err = Layer.notifyEmitted(MR, std::move(A))) {
145 if (auto Err = MR.notifyEmitted()) {
155 Error modifyPassConfig(const Triple &TT, PassConfiguration &Config) override {
165 return Error::success();
171 Error externalizeWeakAndCommonSymbols(LinkGraph &G) {
185 return Error::success();
188 Error markResponsibilitySymbolsLive(LinkGraph &G) const {
193 return Error::success();
196 Error computeNamedSymbolDependencies(LinkGraph &G) {
226 return Error::success();
325 if (auto Err = removeAllModules())
348 Error ObjectLinkingLayer::notifyEmitted(MaterializationResponsibility &MR,
350 Error Err = Error::success();
350 Error Err = Error::success();
362 return Error::success();
365 Error ObjectLinkingLayer::removeModule(VModuleKey K) {
366 Error Err = Error::success();
366 Error Err = Error::success();
385 Error ObjectLinkingLayer::removeAllModules() {
387 Error Err = Error::success();
387 Error Err = Error::success();
428 Error EHFrameRegistrationPlugin::notifyEmitted(
433 return Error::success();
448 Error EHFrameRegistrationPlugin::notifyRemovingModule(VModuleKey K) {
451 return Error::success();
461 Error EHFrameRegistrationPlugin::notifyRemovingAllModules() {
472 Error Err = Error::success();
472 Error Err = Error::success();
lib/ExecutionEngine/Orc/OrcABISupport.cpp 124 Error OrcAArch64::emitIndirectStubsBlock(IndirectStubsInfo &StubsInfo,
188 return Error::success();
206 Error OrcX86_64_Base::emitIndirectStubsBlock(IndirectStubsInfo &StubsInfo,
269 return Error::success();
475 Error OrcI386::emitIndirectStubsBlock(IndirectStubsInfo &StubsInfo,
536 return Error::success();
658 Error OrcMips32_Base::emitIndirectStubsBlock(IndirectStubsInfo &StubsInfo,
729 return Error::success();
899 Error OrcMips64::emitIndirectStubsBlock(IndirectStubsInfo &StubsInfo,
980 return Error::success();
lib/ExecutionEngine/Orc/OrcCBindings.cpp 145 auto Err = J->shutdown();
lib/ExecutionEngine/Orc/OrcCBindingsStack.h 58 virtual Error removeModule(orc::VModuleKey K) = 0;
70 Error removeModule(orc::VModuleKey K) override {
90 Error removeModule(orc::VModuleKey K) override {
139 } else if (auto Err = Sym.takeError()) {
162 } else if (auto Err = Sym.takeError()) {
185 else if (auto Err = Sym.takeError())
190 else if (auto Err = Sym.takeError())
241 Error shutdown() {
246 if (auto Err = DtorRunner.runViaLayer(*this))
248 return Error::success();
275 Error createIndirectStub(StringRef StubName, JITTargetAddress Addr) {
280 Error setIndirectStubPointer(StringRef Name, JITTargetAddress Addr) {
307 if (auto Err = Layer.addModule(K, std::move(M)))
316 if (auto Err = CtorRunner.runViaLayer(*this))
348 Error removeModule(orc::VModuleKey K) {
350 if (auto Err = KeyLayers[K]->removeModule(K))
354 return Error::success();
367 if (auto Err = ObjectLayer.addObject(K, std::move(ObjBuffer)))
400 } else if (auto Err = Sym.takeError()) {
418 } else if (auto Err = Sym.takeError()) {
488 void reportError(Error Err) {
lib/ExecutionEngine/Orc/OrcMCJITReplacement.h 153 } else if (auto Err = Sym.takeError()) {
160 } else if (auto Err = Sym2.takeError()) {
186 } else if (auto Err = Sym.takeError()) {
199 } else if (auto Err = Sym2.takeError()) {
227 void reportError(Error Err) {
lib/ExecutionEngine/Orc/RTDyldObjectLinkingLayer.cpp 149 Error RTDyldObjectLinkingLayer::onObjLoad(
181 if (auto Err = R.defineMaterializing(ExtraSymbolsToClaim))
184 if (auto Err = R.notifyResolved(Symbols)) {
192 return Error::success();
197 MaterializationResponsibility &R, Error Err) {
204 if (auto Err = R.notifyEmitted()) {
lib/ExecutionEngine/Orc/Speculation.cpp 45 Error Speculator::addSpeculationRuntime(JITDylib &JD,
lib/ExecutionEngine/RuntimeDyld/JITSymbol.cpp 82 } else if (auto Err = Sym.takeError()) {
94 } else if (auto Err = Sym.takeError()) {
121 } else if (auto Err = Sym.takeError())
lib/ExecutionEngine/RuntimeDyld/RuntimeDyld.cpp 131 if (auto Err = resolveExternalSymbols()) {
170 static Error getOffset(const SymbolRef &Sym, SectionRef Sec,
176 return Error::success();
193 if (auto Err = computeTotalAllocSize(Obj,
321 if (auto Err = getOffset(*I, *SI, SectOffset))
342 if (auto Err = emitCommonSymbols(Obj, CommonSymbolsToAllocate, CommonSize,
434 if (auto Err = finalizeLoad(Obj, LocalSections))
515 Error RuntimeDyldImpl::computeTotalAllocSize(const ObjectFile &Obj,
621 return Error::success();
717 Error RuntimeDyldImpl::emitCommonSymbols(const ObjectFile &Obj,
722 return Error::success();
768 return Error::success();
1135 Error RuntimeDyldImpl::resolveExternalSymbols() {
1188 return Error::success();
1193 unique_function<void(Error)> OnEmitted,
1219 OnEmitted(Error::success());
1410 unique_function<Error(
1414 unique_function<void(Error)> OnEmitted) {
1427 if (auto Err = OnLoaded(std::move(Info), RTDyld.getSymbolTable()))
lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.cpp 104 if (auto E = Obj.takeError())
155 if (Error E = ObjOrErr.takeError())
561 Error RuntimeDyldELF::findPPC64TOCSection(const ELFObjectFileBase &Obj,
597 return Error::success();
602 Error RuntimeDyldELF::findOPDEntrySection(const ELFObjectFileBase &Obj,
674 return Error::success();
1462 if (auto Err = findOPDEntrySection(Obj, ObjSectionToID, Value))
1576 if (auto Err = findPPC64TOCSection(Obj, ObjSectionToID, TOCValue))
1589 if (auto Err = findPPC64TOCSection(Obj, ObjSectionToID, Value))
1592 if (auto Err = findPPC64TOCSection(Obj, ObjSectionToID, Value))
1852 Error RuntimeDyldELF::finalizeLoad(const ObjectFile &Obj,
1915 return Error::success();
lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.h 91 Error findPPC64TOCSection(const ELFObjectFileBase &Obj,
94 Error findOPDEntrySection(const ELFObjectFileBase &Obj,
183 Error finalizeLoad(const ObjectFile &Obj,
lib/ExecutionEngine/RuntimeDyld/RuntimeDyldImpl.h 378 Error emitCommonSymbols(const ObjectFile &Obj,
431 Error resolveExternalSymbols();
435 Error computeTotalAllocSize(const ObjectFile &Obj,
552 unique_function<void(Error)> OnEmitted,
578 virtual Error finalizeLoad(const ObjectFile &ObjImg,
580 return Error::success();
lib/ExecutionEngine/RuntimeDyld/RuntimeDyldMachO.cpp 180 Error RuntimeDyldMachO::populateIndirectSymbolPointersSection(
219 return Error::success();
227 Error
264 if (auto Err = impl().finalizeSection(Obj, I->second, Section))
271 return Error::success();
lib/ExecutionEngine/RuntimeDyld/RuntimeDyldMachO.h 117 Error populateIndirectSymbolPointersSection(const MachOObjectFile &Obj,
158 Error finalizeLoad(const ObjectFile &Obj,
lib/ExecutionEngine/RuntimeDyld/Targets/RuntimeDyldCOFFX86_64.h 282 Error finalizeLoad(const object::ObjectFile &Obj,
297 return Error::success();
lib/ExecutionEngine/RuntimeDyld/Targets/RuntimeDyldMachOAArch64.h 436 Error finalizeSection(const ObjectFile &Obj, unsigned SectionID,
438 return Error::success();
lib/ExecutionEngine/RuntimeDyld/Targets/RuntimeDyldMachOARM.h 289 Error finalizeSection(const ObjectFile &Obj, unsigned SectionID,
300 return Error::success();
lib/ExecutionEngine/RuntimeDyld/Targets/RuntimeDyldMachOI386.h 128 Error finalizeSection(const ObjectFile &Obj, unsigned SectionID,
141 return Error::success();
212 Error populateJumpTable(const MachOObjectFile &Obj,
243 return Error::success();
lib/ExecutionEngine/RuntimeDyld/Targets/RuntimeDyldMachOX86_64.h 123 Error finalizeSection(const ObjectFile &Obj, unsigned SectionID,
125 return Error::success();
lib/FuzzMutate/FuzzerCLI.cpp 182 if (Error E = M.takeError()) {
lib/IR/Globals.cpp 49 Error GlobalValue::materialize() {
lib/IR/Module.cpp 394 Error Module::materialize(GlobalValue *GV) {
396 return Error::success();
401 Error Module::materializeAll() {
403 return Error::success();
408 Error Module::materializeMetadata() {
410 return Error::success();
lib/IR/RemarkStreamer.cpp 37 Error RemarkStreamer::setFilter(StringRef Filter) {
44 return Error::success();
158 if (Error E = Format.takeError())
174 if (Error E = RemarkSerializer.takeError())
181 if (Error E = Context.getRemarkStreamer()->setFilter(RemarksPasses))
187 Error llvm::setupOptimizationRemarks(LLVMContext &Context, raw_ostream &OS,
199 if (Error E = Format.takeError())
205 if (Error E = RemarkSerializer.takeError())
212 if (Error E = Context.getRemarkStreamer()->setFilter(RemarksPasses))
215 return Error::success();
lib/IRReader/IRReader.cpp 39 if (Error E = ModuleOrErr.takeError()) {
79 if (Error E = ModuleOrErr.takeError()) {
lib/LTO/Caching.cpp 108 Error E = TempFile.keep(EntryPath);
121 return Error::success();
lib/LTO/LTO.cpp 568 Error LTO::add(std::unique_ptr<InputFile> Input,
580 if (Error Err = addModule(*Input, I, ResI, Res.end()))
584 return Error::success();
587 Error LTO::addModule(InputFile &Input, unsigned ModI,
622 if (Error Err = BM.readSummary(ThinLTO.CombinedIndex, "", -1ull))
625 return Error::success();
674 if (Error Err = M.materializeMetadata())
778 Error LTO::linkRegularLTO(RegularLTOState::AddedModule Mod,
806 Error LTO::addThinLTO(BitcodeModule BM, ArrayRef<InputFile::Symbol> Syms,
809 if (Error Err =
850 return Error::success();
860 Error LTO::checkPartiallySplit() {
862 return Error::success();
894 return Error::success();
897 Error LTO::run(AddStreamFn AddStream, NativeObjectCache Cache) {
935 if (Error Err = linkRegularLTO(std::move(M),
940 if (Error Err = checkPartiallySplit())
943 Error Result = runRegularLTO(AddStream);
953 Error LTO::runRegularLTO(AddStreamFn AddStream) {
985 return Error::success();
1011 return Error::success();
1041 virtual Error start(
1047 virtual Error wait() = 0;
1058 Optional<Error> Err;
1078 Error runThinLTOBackendThread(
1113 return Error::success();
1116 Error start(
1134 Error E = runThinLTOBackendThread(
1147 return Error::success();
1150 Error wait() override {
1155 return Error::success();
1208 Error start(
1241 return Error::success();
1244 Error wait() override { return Error::success(); }
1244 Error wait() override { return Error::success(); }
1260 Error LTO::runThinLTO(AddStreamFn AddStream, NativeObjectCache Cache,
1263 return Error::success();
1266 return Error::success();
1368 if (Error E = BackendProc->start(Task, Mod.second, ImportLists[Mod.first],
1388 if (Error E = ResultOrErr.takeError())
lib/LTO/LTOBackend.cpp 56 Error Config::addSaveTemps(std::string OutputFileName,
122 return Error::success();
176 if (auto Err = PB.parseAAPipeline(AA, "default"))
235 if (auto Err = PB.parseAAPipeline(AA, AAPipelineDesc))
260 if (auto Err = PB.parsePassPipeline(MPM, PipelineDesc))
416 static Error
421 return Error::success();
424 return Error::success();
427 Error lto::backend(Config &C, AddStreamFn AddStream,
481 Error lto::thinBackend(Config &Conf, unsigned Task, AddStreamFn AddStream,
535 if (Error Err = Importer.importFunctions(Mod, ImportList).takeError())
lib/LTO/LTOModule.cpp 174 if (Error E = MBOrErr.takeError()) {
lib/LTO/ThinLTOCodeGenerator.cpp 378 if (auto Err = handleErrors(
571 if (Error Err =
lib/Linker/IRMover.cpp 426 Optional<Error> FoundError;
427 void setError(Error E) {
434 Error stringErr(const Twine &T) {
486 Error linkModuleFlagsMetadata();
489 Error linkFunctionBody(Function &Dst, Function &Src);
492 Error linkGlobalValueBody(GlobalValue &Dst, GlobalValue &Src);
539 Error run();
1056 Error IRLinker::linkFunctionBody(Function &Dst, Function &Src) {
1060 if (Error Err = Src.materialize())
1080 return Error::success();
1089 Error IRLinker::linkGlobalValueBody(GlobalValue &Dst, GlobalValue &Src) {
1094 return Error::success();
1097 return Error::success();
1192 Error IRLinker::linkModuleFlagsMetadata() {
1196 return Error::success();
1205 return Error::success();
1365 return Error::success();
1380 Error IRLinker::run() {
1383 if (Error Err = SrcM->getMaterializer()->materializeMetadata())
1555 Error IRMover::move(
1562 Error E = TheIRLinker.run();
lib/Linker/LinkModules.cpp 553 if (Error E = Mover.move(std::move(SrcM), ValuesToLink.getArrayRef(),
lib/MC/ELFObjectWriter.cpp 894 if (Error E = zlib::compress(
lib/MCA/InstrBuilder.cpp 218 static Error verifyOperands(const MCInstrDesc &MCDesc, const MCInst &MCI) {
483 Error InstrBuilder::verifyInstrDesc(const InstrDesc &ID,
574 if (Error Err = verifyOperands(MCDesc, MCI))
584 if (Error Err = verifyInstrDesc(*ID, MCI))
lib/MCA/Pipeline.cpp 42 if (Error Err = runCycle())
51 Error Pipeline::runCycle() {
52 Error Err = ErrorSuccess();
lib/MCA/Stages/DispatchStage.cpp 78 Error DispatchStage::dispatch(InstRef IR) {
138 Error DispatchStage::cycleStart() {
175 Error DispatchStage::execute(InstRef &IR) {
lib/MCA/Stages/EntryStage.cpp 42 llvm::Error EntryStage::execute(InstRef & /*unused */) {
44 if (llvm::Error Val = moveToTheNextStage(CurrentInstruction))
53 llvm::Error EntryStage::cycleStart() {
59 llvm::Error EntryStage::cycleEnd() {
lib/MCA/Stages/ExecuteStage.cpp 53 Error ExecuteStage::issueInstruction(InstRef &IR) {
68 if (Error S = moveToTheNextStage(IR))
80 Error ExecuteStage::issueReadyInstructions() {
83 if (Error Err = issueInstruction(IR))
93 Error ExecuteStage::cycleStart() {
109 if (Error S = moveToTheNextStage(IR))
122 Error ExecuteStage::cycleEnd() {
173 Error ExecuteStage::handleInstructionEliminated(InstRef &IR) {
186 Error ExecuteStage::execute(InstRef &IR) {
lib/MCA/Stages/InstructionTables.cpp 22 Error InstructionTables::execute(InstRef &IR) {
lib/MCA/Stages/MicroOpQueueStage.cpp 21 Error MicroOpQueueStage::moveInstructions() {
24 if (llvm::Error Val = moveToTheNextStage(IR))
46 Error MicroOpQueueStage::execute(InstRef &IR) {
56 Error MicroOpQueueStage::cycleStart() {
63 Error MicroOpQueueStage::cycleEnd() {
lib/MCA/Stages/RetireStage.cpp 25 llvm::Error RetireStage::cycleStart() {
45 llvm::Error RetireStage::execute(InstRef &IR) {
lib/Object/Archive.cpp 46 static Error
55 uint64_t Size, Error *Err)
327 Archive::Child::Child(const Archive *Parent, const char *Start, Error *Err)
481 Error Err = Error::success();
481 Error Err = Error::success();
531 Error Err = Error::success();
531 Error Err = Error::success();
543 Archive::Archive(MemoryBufferRef Source, Error &Err)
573 Err = Error::success();
629 Err = Error::success();
692 Err = Error::success();
716 Err = Error::success();
723 Err = Error::success();
747 Err = Error::success();
772 Err = Error::success();
775 Archive::child_iterator Archive::child_begin(Error &Err,
852 Error Err = Error::success();
852 Error Err = Error::success();
lib/Object/ArchiveWriter.cpp 381 if (Error E = S.printName(SymNames))
494 if (auto E = Symbols.takeError())
551 Error writeArchive(StringRef ArcName, ArrayRef<NewArchiveMember> NewMembers,
564 if (Error E = DataOrErr.takeError())
lib/Object/COFFImportFile.cpp 571 Error writeImportLibrary(StringRef ImportName, StringRef Path,
lib/Object/COFFModuleDefinition.cpp 83 static Error createError(const Twine &Err) {
153 if (Error Err = parseOne())
169 Error readAsInt(uint64_t *I) {
173 return Error::success();
176 Error expect(Kind Expected, StringRef Msg) {
180 return Error::success();
185 Error parseOne() {
189 return Error::success();
195 return Error::success();
197 if (Error Err = parseExport())
208 if (Error Err = parseName(&Name, &Info.ImageBase))
221 return Error::success();
230 Error parseExport() {
263 return Error::success();
295 return Error::success();
300 Error parseNumbers(uint64_t *Reserve, uint64_t *Commit) {
301 if (Error Err = readAsInt(Reserve))
307 return Error::success();
309 if (Error Err = readAsInt(Commit))
311 return Error::success();
315 Error parseName(std::string *Out, uint64_t *Baseaddr) {
322 return Error::success();
326 if (Error Err = expect(Equal, "'=' expected"))
328 if (Error Err = readAsInt(Baseaddr))
334 return Error::success();
338 Error parseVersion(uint32_t *Major, uint32_t *Minor) {
350 return Error::success();
lib/Object/COFFObjectFile.cpp 299 if (Error E = getSectionContents(Sec, Res))
1099 Error COFFObjectFile::getSectionContents(const coff_section *Sec,
1104 return Error::success();
1113 return Error::success();
1748 Error ResourceSectionRef::load(const COFFObjectFile *O) {
1761 Error ResourceSectionRef::load(const COFFObjectFile *O, const SectionRef &S) {
1777 return Error::success();
1834 if (Error E = Obj->getSectionContents(Section, Contents))
lib/Object/Decompressor.cpp 26 Error Err = isGnuStyle(Name) ? D.consumeCompressedGnuHeader()
36 Error Decompressor::consumeCompressedGnuHeader() {
48 return Error::success();
51 Error Decompressor::consumeCompressedZLibHeader(bool Is64Bit,
72 return Error::success();
95 Error Decompressor::decompress(MutableArrayRef<char> Buffer) {
lib/Object/ELFObjectFile.cpp 64 if (Error E = Ret.takeError())
160 if (Error E = getBuildAttributes(Attributes))
308 if (Error E = getBuildAttributes(Attributes))
lib/Object/Error.cpp 80 llvm::Error llvm::object::isNotObjectErrorInvalidFileType(llvm::Error Err) {
80 llvm::Error llvm::object::isNotObjectErrorInvalidFileType(llvm::Error Err) {
85 return Error::success();
lib/Object/IRObjectFile.cpp 45 Error IRObjectFile::printSymbolName(raw_ostream &OS, DataRefImpl Symb) const {
47 return Error::success();
lib/Object/IRSymtab.cpp 109 Error addModule(Module *M);
110 Error addSymbol(const ModuleSymbolTable &Msymtab,
114 Error build(ArrayRef<Module *> Mods);
117 Error Builder::addModule(Module *M) {
135 if (auto E = M->materializeMetadata())
146 if (auto E = M->materializeMetadata())
160 if (Error Err = addSymbol(Msymtab, Used, Msym))
163 return Error::success();
195 Error Builder::addSymbol(const ModuleSymbolTable &Msymtab,
245 return Error::success();
304 return Error::success();
307 Error Builder::build(ArrayRef<Module *> IRMods) {
318 if (Error Err = addModule(M))
333 return Error::success();
338 Error irsymtab::build(ArrayRef<Module *> Mods, SmallVector<char, 0> &Symtab,
365 if (Error E = build(Mods, FC.Symtab, StrtabBuilder, Alloc))
lib/Object/MachOObjectFile.cpp 60 static Error malformedError(const Twine &Msg) {
221 Error &Err) {
240 static Error checkOverlappingElement(std::list<MachOElement> &Elements,
244 return Error::success();
261 return Error::success();
266 return Error::success();
273 static Error parseSegmentLoadCommand(
354 if (Error Err = checkOverlappingElement(Elements, s.offset, s.size,
370 if (Error Err = checkOverlappingElement(Elements, s.reloff, s.nreloc *
394 return Error::success();
397 static Error checkSymtabCommand(const MachOObjectFile &Obj,
435 if (Error Err = checkOverlappingElement(Elements, Symtab.symoff, SymtabSize,
448 if (Error Err = checkOverlappingElement(Elements, Symtab.stroff,
452 return Error::success();
455 static Error checkDysymtabCommand(const MachOObjectFile &Obj,
486 if (Error Err = checkOverlappingElement(Elements, Dysymtab.tocoff,
512 if (Error Err = checkOverlappingElement(Elements, Dysymtab.modtaboff,
528 if (Error Err = checkOverlappingElement(Elements, Dysymtab.extrefsymoff,
545 if (Error Err = checkOverlappingElement(Elements, Dysymtab.indirectsymoff,
562 if (Error Err = checkOverlappingElement(Elements, Dysymtab.extreloff,
579 if (Error Err = checkOverlappingElement(Elements, Dysymtab.locreloff,
585 return Error::success();
588 static Error checkLinkeditDataCommand(const MachOObjectFile &Obj,
619 if (Error Err = checkOverlappingElement(Elements, LinkData.dataoff,
623 return Error::success();
626 static Error checkDyldInfoCommand(const MachOObjectFile &Obj,
657 if (Error Err = checkOverlappingElement(Elements, DyldInfo.rebase_off,
672 if (Error Err = checkOverlappingElement(Elements, DyldInfo.bind_off,
687 if (Error Err = checkOverlappingElement(Elements, DyldInfo.weak_bind_off,
702 if (Error Err = checkOverlappingElement(Elements, DyldInfo.lazy_bind_off,
717 if (Error Err = checkOverlappingElement(Elements, DyldInfo.export_off,
722 return Error::success();
725 static Error checkDylibCommand(const MachOObjectFile &Obj,
754 return Error::success();
757 static Error checkDylibIdCommand(const MachOObjectFile &Obj,
761 if (Error Err = checkDylibCommand(Obj, Load, LoadCommandIndex,
771 return Error::success();
774 static Error checkDyldCommand(const MachOObjectFile &Obj,
803 return Error::success();
806 static Error checkVersCommand(const MachOObjectFile &Obj,
818 return Error::success();
821 static Error checkNoteCommand(const MachOObjectFile &Obj,
843 if (Error Err = checkOverlappingElement(Elements, Nt.offset, Nt.size,
846 return Error::success();
849 static Error
870 return Error::success();
873 static Error checkRpathCommand(const MachOObjectFile &Obj,
902 return Error::success();
905 static Error checkEncryptCommand(const MachOObjectFile &Obj,
926 return Error::success();
929 static Error checkLinkerOptCommand(const MachOObjectFile &Obj,
966 return Error::success();
969 static Error checkSubCommand(const MachOObjectFile &Obj,
993 return Error::success();
996 static Error checkThreadCommand(const MachOObjectFile &Obj,
1184 return Error::success();
1187 static Error checkTwoLevelHintsCommand(const MachOObjectFile &Obj,
1215 if (Error Err = checkOverlappingElement(Elements, Hints.offset, Hints.nhints *
1220 return Error::success();
1244 Error Err = Error::success();
1244 Error Err = Error::success();
1255 bool Is64bits, Error &Err,
1671 Err = Error::success();
1674 Error MachOObjectFile::checkSymbolTable() const {
1738 return Error::success();
2780 ExportEntry::ExportEntry(Error *E, const MachOObjectFile *O,
3084 MachOObjectFile::exports(Error &E, ArrayRef<uint8_t> Trie,
3098 iterator_range<export_iterator> MachOObjectFile::exports(Error &Err) const {
3102 MachORebaseEntry::MachORebaseEntry(Error *E, const MachOObjectFile *O,
3433 MachOObjectFile::rebaseTable(Error &Err, MachOObjectFile *O,
3446 iterator_range<rebase_iterator> MachOObjectFile::rebaseTable(Error &Err) {
3450 MachOBindEntry::MachOBindEntry(Error *E, const MachOObjectFile *O,
4103 MachOObjectFile::bindTable(Error &Err, MachOObjectFile *O,
4117 iterator_range<bind_iterator> MachOObjectFile::bindTable(Error &Err) {
4122 iterator_range<bind_iterator> MachOObjectFile::lazyBindTable(Error &Err) {
4127 iterator_range<bind_iterator> MachOObjectFile::weakBindTable(Error &Err) {
lib/Object/MachOUniversal.cpp 24 static Error
104 Error Err = Error::success();
104 Error Err = Error::success();
112 MachOUniversalBinary::MachOUniversalBinary(MemoryBufferRef Source, Error &Err)
210 Err = Error::success();
lib/Object/ObjectFile.cpp 59 Error ObjectFile::printSymbolName(raw_ostream &OS, DataRefImpl Symb) const {
64 return Error::success();
177 if (Error Err = ObjOrErr.takeError())
lib/Object/TapiFile.cpp 83 Error TapiFile::printSymbolName(raw_ostream &OS, DataRefImpl DRI) const {
86 return Error::success();
lib/Object/TapiUniversal.cpp 23 TapiUniversal::TapiUniversal(MemoryBufferRef Source, Error &Err)
49 Error Err = Error::success();
49 Error Err = Error::success();
lib/Object/WasmObjectFile.cpp 58 Error Err = Error::success();
58 Error Err = Error::success();
162 static Error readInitExpr(wasm::WasmInitExpr &Expr,
192 return Error::success();
211 static Error readSection(WasmSection &Section, WasmObjectFile::ReadContext &Ctx,
244 return Error::success();
247 WasmObjectFile::WasmObjectFile(MemoryBufferRef Buffer, Error &Err)
287 Error WasmObjectFile::parseSection(WasmSection &Sec) {
327 Error WasmObjectFile::parseDylinkSection(ReadContext &Ctx) {
341 return Error::success();
344 Error WasmObjectFile::parseNameSection(ReadContext &Ctx) {
387 return Error::success();
390 Error WasmObjectFile::parseLinkingSection(ReadContext &Ctx) {
416 if (Error Err = parseLinkingSectionSymtab(Ctx))
447 if (Error Err = parseLinkingSectionComdat(Ctx))
461 return Error::success();
464 Error WasmObjectFile::parseLinkingSectionSymtab(ReadContext &Ctx) {
629 return Error::success();
632 Error WasmObjectFile::parseLinkingSectionComdat(ReadContext &Ctx) {
676 return Error::success();
679 Error WasmObjectFile::parseProducersSection(ReadContext &Ctx) {
717 return Error::success();
720 Error WasmObjectFile::parseTargetFeaturesSection(ReadContext &Ctx) {
747 return Error::success();
750 Error WasmObjectFile::parseRelocSection(StringRef Name, ReadContext &Ctx) {
841 return Error::success();
844 Error WasmObjectFile::parseCustomSection(WasmSection &Sec, ReadContext &Ctx) {
846 if (Error Err = parseDylinkSection(Ctx))
849 if (Error Err = parseNameSection(Ctx))
852 if (Error Err = parseLinkingSection(Ctx))
855 if (Error Err = parseProducersSection(Ctx))
858 if (Error Err = parseTargetFeaturesSection(Ctx))
861 if (Error Err = parseRelocSection(Sec.Name, Ctx))
864 return Error::success();
867 Error WasmObjectFile::parseTypeSection(ReadContext &Ctx) {
893 return Error::success();
896 Error WasmObjectFile::parseImportSection(ReadContext &Ctx) {
937 return Error::success();
940 Error WasmObjectFile::parseFunctionSection(ReadContext &Ctx) {
954 return Error::success();
957 Error WasmObjectFile::parseTableSection(ReadContext &Ctx) {
970 return Error::success();
973 Error WasmObjectFile::parseMemorySection(ReadContext &Ctx) {
982 return Error::success();
985 Error WasmObjectFile::parseGlobalSection(ReadContext &Ctx) {
994 if (Error Err = readInitExpr(Global.InitExpr, Ctx))
1001 return Error::success();
1004 Error WasmObjectFile::parseEventSection(ReadContext &Ctx) {
1019 return Error::success();
1022 Error WasmObjectFile::parseExportSection(ReadContext &Ctx) {
1058 return Error::success();
1126 Error WasmObjectFile::parseStartSection(ReadContext &Ctx) {
1131 return Error::success();
1134 Error WasmObjectFile::parseCodeSection(ReadContext &Ctx) {
1173 return Error::success();
1176 Error WasmObjectFile::parseElemSection(ReadContext &Ctx) {
1186 if (Error Err = readInitExpr(Segment.Offset, Ctx))
1197 return Error::success();
1200 Error WasmObjectFile::parseDataSection(ReadContext &Ctx) {
1213 if (Error Err = readInitExpr(Segment.Data.Offset, Ctx))
1236 return Error::success();
1239 Error WasmObjectFile::parseDataCountSection(ReadContext &Ctx) {
1241 return Error::success();
lib/Object/WindowsResource.cpp 83 if (auto E = Ref.loadNext())
88 Error ResourceEntryRef::moveNext(bool &End) {
92 return Error::success();
96 return Error::success();
99 static Error readStringOrId(BinaryStreamReader &Reader, uint16_t &ID,
113 return Error::success();
116 Error ResourceEntryRef::loadNext() {
137 return Error::success();
329 Error WindowsResourceParser::parse(WindowsResource *WR,
333 auto E = EntryOrErr.takeError();
342 return Error::success();
364 return Error::success();
367 Error WindowsResourceParser::parse(ResourceSectionRef &RSR, StringRef Filename,
390 Error WindowsResourceParser::addChildren(TreeNode &Node,
415 Error E =
449 return Error::success();
604 const WindowsResourceParser &Parser, Error &E);
642 Error &E)
1005 Error E = Error::success();
1005 Error E = Error::success();
lib/Object/XCOFFObjectFile.cpp 580 if (Error E = NumRelocEntriesOrErr.takeError())
588 if (Error E = RelocationOrErr.takeError())
614 if (Error E = StringTableOrErr.takeError())
637 if (Error E = FileHeaderOrErr.takeError())
651 if (Error E = SecHeadersOrErr.takeError())
670 if (Error E = SymTableOrErr.takeError())
678 if (Error E = StringTableOrErr.takeError())
lib/ObjectYAML/CodeViewYAMLDebugSections.cpp 696 if (auto EC = Reader.readCString(S))
700 if (auto EC = Reader.readCString(S))
768 Error visitUnknown(DebugUnknownSubsectionRef &Unknown) override;
769 Error visitLines(DebugLinesSubsectionRef &Lines,
771 Error visitFileChecksums(DebugChecksumsSubsectionRef &Checksums,
773 Error visitInlineeLines(DebugInlineeLinesSubsectionRef &Inlinees,
775 Error visitCrossModuleExports(DebugCrossModuleExportsSubsectionRef &Checksums,
777 Error visitCrossModuleImports(DebugCrossModuleImportsSubsectionRef &Inlinees,
779 Error visitStringTable(DebugStringTableSubsectionRef &ST,
781 Error visitSymbols(DebugSymbolsSubsectionRef &Symbols,
783 Error visitFrameData(DebugFrameDataSubsectionRef &Symbols,
785 Error visitCOFFSymbolRVAs(DebugSymbolRVASubsectionRef &Symbols,
793 Error SubsectionConversionVisitor::visitUnknown(
798 Error SubsectionConversionVisitor::visitLines(
805 return Error::success();
808 Error SubsectionConversionVisitor::visitFileChecksums(
816 return Error::success();
819 Error SubsectionConversionVisitor::visitInlineeLines(
827 return Error::success();
830 Error SubsectionConversionVisitor::visitCrossModuleExports(
838 return Error::success();
841 Error SubsectionConversionVisitor::visitCrossModuleImports(
849 return Error::success();
852 Error SubsectionConversionVisitor::visitStringTable(
859 return Error::success();
862 Error SubsectionConversionVisitor::visitSymbols(
868 return Error::success();
871 Error SubsectionConversionVisitor::visitFrameData(
878 return Error::success();
881 Error SubsectionConversionVisitor::visitCOFFSymbolRVAs(
887 return Error::success();
894 if (auto EC = visitDebugSubsection(SS, V, SC))
lib/ObjectYAML/CodeViewYAMLSymbols.cpp 215 virtual Error fromCodeViewSymbol(codeview::CVSymbol Type) = 0;
230 Error fromCodeViewSymbol(codeview::CVSymbol CVS) override {
254 Error fromCodeViewSymbol(CVSymbol CVS) override {
257 return Error::success();
587 if (auto EC = Impl->fromCodeViewSymbol(Symbol))
lib/ObjectYAML/CodeViewYAMLTypes.cpp 86 virtual Error fromCodeViewRecord(CVType Type) = 0;
95 Error fromCodeViewRecord(CVType Type) override {
112 Error fromCodeViewRecord(CVType Type) override;
473 template <typename T> Error visitKnownMemberImpl(T &Record) {
478 return Error::success();
486 Error LeafRecordImpl<FieldListRecord>::fromCodeViewRecord(CVType Type) {
673 if (auto EC = Impl->fromCodeViewRecord(Type))
lib/Passes/PassBuilder.cpp 1807 Error PassBuilder::parseModulePass(ModulePassManager &MPM,
1817 if (auto Err = parseModulePassPipeline(NestedMPM, InnerPipeline,
1821 return Error::success();
1825 if (auto Err = parseCGSCCPassPipeline(CGPM, InnerPipeline, VerifyEachPass,
1829 return Error::success();
1833 if (auto Err = parseFunctionPassPipeline(FPM, InnerPipeline,
1837 return Error::success();
1841 if (auto Err = parseModulePassPipeline(NestedMPM, InnerPipeline,
1845 return Error::success();
1850 return Error::success();
1887 return Error::success();
1902 return Error::success();
1927 return Error::success();
1933 Error PassBuilder::parseCGSCCPass(CGSCCPassManager &CGPM,
1943 if (auto Err = parseCGSCCPassPipeline(NestedCGPM, InnerPipeline,
1948 return Error::success();
1952 if (auto Err = parseFunctionPassPipeline(FPM, InnerPipeline,
1957 return Error::success();
1961 if (auto Err = parseCGSCCPassPipeline(NestedCGPM, InnerPipeline,
1965 return Error::success();
1969 if (auto Err = parseCGSCCPassPipeline(NestedCGPM, InnerPipeline,
1974 return Error::success();
1979 return Error::success();
2010 return Error::success();
2016 Error PassBuilder::parseFunctionPass(FunctionPassManager &FPM,
2026 if (auto Err = parseFunctionPassPipeline(NestedFPM, InnerPipeline,
2031 return Error::success();
2035 if (auto Err = parseLoopPassPipeline(LPM, InnerPipeline, VerifyEachPass,
2042 return Error::success();
2046 if (auto Err = parseFunctionPassPipeline(NestedFPM, InnerPipeline,
2050 return Error::success();
2055 return Error::success();
2093 return Error::success();
2099 Error PassBuilder::parseLoopPass(LoopPassManager &LPM, const PipelineElement &E,
2108 if (auto Err = parseLoopPassPipeline(NestedLPM, InnerPipeline,
2113 return Error::success();
2117 if (auto Err = parseLoopPassPipeline(NestedLPM, InnerPipeline,
2121 return Error::success();
2126 return Error::success();
2165 return Error::success();
2191 Error PassBuilder::parseLoopPassPipeline(LoopPassManager &LPM,
2196 if (auto Err = parseLoopPass(LPM, Element, VerifyEachPass, DebugLogging))
2200 return Error::success();
2203 Error PassBuilder::parseFunctionPassPipeline(FunctionPassManager &FPM,
2208 if (auto Err =
2214 return Error::success();
2217 Error PassBuilder::parseCGSCCPassPipeline(CGSCCPassManager &CGPM,
2222 if (auto Err = parseCGSCCPass(CGPM, Element, VerifyEachPass, DebugLogging))
2226 return Error::success();
2242 Error PassBuilder::parseModulePassPipeline(ModulePassManager &MPM,
2247 if (auto Err = parseModulePass(MPM, Element, VerifyEachPass, DebugLogging))
2252 return Error::success();
2258 Error PassBuilder::parsePassPipeline(ModulePassManager &MPM,
2282 return Error::success();
2294 if (auto Err =
2297 return Error::success();
2301 Error PassBuilder::parsePassPipeline(CGSCCPassManager &CGPM,
2318 if (auto Err =
2321 return Error::success();
2326 Error PassBuilder::parsePassPipeline(FunctionPassManager &FPM,
2343 if (auto Err = parseFunctionPassPipeline(FPM, *Pipeline, VerifyEachPass,
2346 return Error::success();
2350 Error PassBuilder::parsePassPipeline(LoopPassManager &CGPM,
2359 if (auto Err =
2363 return Error::success();
2366 Error PassBuilder::parseAAPipeline(AAManager &AA, StringRef PipelineText) {
2371 return Error::success();
2383 return Error::success();
lib/ProfileData/Coverage/CoverageMapping.cpp 158 if (auto E = Value.takeError()) {
206 Error CoverageMapping::loadFunctionRecord(
221 if (Error E = ProfileReader.getFunctionCounts(Record.FunctionName,
226 return Error::success();
242 return Error::success();
247 if (auto E = ExecutionCount.takeError()) {
249 return Error::success();
258 return Error::success();
275 return Error::success();
285 if (Error E = RecordOrErr.takeError())
288 if (Error E = Coverage->loadFunctionRecord(Record, ProfileReader))
297 static Error handleMaybeNoDataFoundError(Error E) {
297 static Error handleMaybeNoDataFoundError(Error E) {
301 return static_cast<Error>(Error::success());
310 if (Error E = ProfileReaderOrErr.takeError())
325 if (Error E = CoverageReadersOrErr.takeError()) {
lib/ProfileData/Coverage/CoverageMappingReader.cpp 49 if (auto E = Reader->readNextRecord(Record))
58 Error RawCoverageReader::readULEB128(uint64_t &Result) {
66 return Error::success();
69 Error RawCoverageReader::readIntMax(uint64_t &Result, uint64_t MaxPlus1) {
70 if (auto Err = readULEB128(Result))
74 return Error::success();
77 Error RawCoverageReader::readSize(uint64_t &Result) {
78 if (auto Err = readULEB128(Result))
83 return Error::success();
86 Error RawCoverageReader::readString(StringRef &Result) {
88 if (auto Err = readSize(Length))
92 return Error::success();
95 Error RawCoverageFilenamesReader::read() {
97 if (auto Err = readSize(NumFilenames))
101 if (auto Err = readString(Filename))
105 return Error::success();
108 Error RawCoverageMappingReader::decodeCounter(unsigned Value, Counter &C) {
113 return Error::success();
116 return Error::success();
134 return Error::success();
137 Error RawCoverageMappingReader::readCounter(Counter &C) {
139 if (auto Err =
142 if (auto Err = decodeCounter(EncodedCounter, C))
144 return Error::success();
153 Error RawCoverageMappingReader::readMappingRegionsSubArray(
157 if (auto Err = readSize(NumRegions))
166 if (auto Err = readIntMax(EncodedCounterAndRegion,
172 if (auto Err = decodeCounter(EncodedCounterAndRegion, C))
199 if (auto Err =
202 if (auto Err = readULEB128(ColumnStart))
206 if (auto Err = readIntMax(NumLines, std::numeric_limits<unsigned>::max()))
208 if (auto Err = readIntMax(ColumnEnd, std::numeric_limits<unsigned>::max()))
249 return Error::success();
252 Error RawCoverageMappingReader::read() {
256 if (auto Err = readSize(NumFileMappings))
260 if (auto Err = readIntMax(FilenameIndex, TranslationUnitFilenames.size()))
272 if (auto Err = readSize(NumExpressions))
281 if (auto Err = readCounter(Expressions[I].LHS))
283 if (auto Err = readCounter(Expressions[I].RHS))
290 if (auto Err = readMappingRegionsSubArray(MappingRegions, InferredFileID,
317 return Error::success();
323 if (Error Err = readSize(NumFileMappings))
329 if (Error Err =
333 if (Error Err = readSize(NumExpressions))
338 if (Error Err = readSize(NumRegions))
343 if (Error Err = readIntMax(EncodedCounterAndRegion,
350 Error InstrProfSymtab::create(SectionRef &Section) {
363 return Error::success();
425 Error insertFunctionRecordIfNeeded(const FuncRecordType *CFR,
433 if (Error Err = CFR->template getFuncName<Endian>(ProfileNames, FuncName))
439 return Error::success();
447 if (Error Err = OldIsDummyExpected.takeError())
450 return Error::success();
453 if (Error Err = NewIsDummyExpected.takeError())
456 return Error::success();
461 return Error::success();
496 if (auto Err = Reader.read())
522 if (Error Err =
547 if (Error E = P.create(P.getNameData()))
560 static Error readCoverageMappingData(
575 if (Error E = ReaderExpected.takeError())
580 if (auto E = NextHeaderOrErr.takeError())
584 return Error::success();
596 if (Error E =
602 if (Error E = readCoverageMappingData<uint32_t, support::endianness::big>(
607 if (Error E =
613 if (Error E = readCoverageMappingData<uint64_t, support::endianness::big>(
645 if (Error E = ProfileNames.create(Data.substr(0, ProfileNamesSize), Address))
710 if (auto E = NamesSection.takeError())
715 if (auto E = CoverageSection.takeError())
724 if (Error E = ProfileNames.create(*NamesSection))
775 Error Err = Error::success();
775 Error Err = Error::success();
808 Error BinaryCoverageReader::readNextRecord(CoverageMappingRecord &Record) {
820 if (auto Err = Reader.read())
830 return Error::success();
lib/ProfileData/InstrProf.cpp 336 Error InstrProfSymtab::create(Module &M, bool InLTO) {
343 if (Error E = addFuncName(PGOFuncName))
353 if (Error E = addFuncName(OtherFuncName))
361 return Error::success();
378 Error collectPGOFuncNameStrings(ArrayRef<std::string> NameStrs,
400 return Error::success();
408 Error E = zlib::compress(StringRef(UncompressedNameStrings),
426 Error collectPGOFuncNameStrings(ArrayRef<GlobalVariable *> NameVars,
436 Error readPGOFuncNameStrings(StringRef NameStrings, InstrProfSymtab &Symtab) {
454 if (Error E =
472 if (Error E = Symtab.addFuncName(Name))
478 return Error::success();
855 Error ValueProfData::checkIntegrity() {
870 return Error::success();
892 Error E = VPD->checkIntegrity();
1167 Error OverlapStats::accumulateCounts(const std::string &BaseFilename,
1173 if (Error E = ReaderOrErr.takeError()) {
1178 return Error::success();
1180 auto Ret = getProfileSum(BaseFilename, Base);
1189 return Error::success();
lib/ProfileData/InstrProfReader.cpp 49 static Error initializeReader(InstrProfReader &Reader) {
57 if (Error E = BufferOrError.takeError())
85 if (Error E = initializeReader(*Result))
95 if (Error E = BufferOrError.takeError())
103 if (Error E = RemappingBufferOrError.takeError())
126 if (Error E = initializeReader(*Result))
133 if (auto E = Reader->readNextRecord(Record)) {
153 Error TextInstrProfReader::readHeader() {
176 Error
224 if (Error E = Symtab->addFuncName(VD.first))
246 Error TextInstrProfReader::readNextRecord(NamedInstrProfRecord &Record) {
257 if (Error E = Symtab->addFuncName(Record.Name))
288 if (Error E = readValueProfileData(Record))
305 Error RawInstrProfReader<IntPtrT>::readHeader() {
317 Error RawInstrProfReader<IntPtrT>::readNextHeader(const char *CurrentPos) {
343 Error RawInstrProfReader<IntPtrT>::createSymtab(InstrProfSymtab &Symtab) {
344 if (Error E = Symtab.create(StringRef(NamesStart, NamesSize)))
356 Error RawInstrProfReader<IntPtrT>::readHeader(
389 if (Error E = createSymtab(*NewSymtab.get()))
397 Error RawInstrProfReader<IntPtrT>::readName(NamedInstrProfRecord &Record) {
403 Error RawInstrProfReader<IntPtrT>::readFuncHash(NamedInstrProfRecord &Record) {
409 Error RawInstrProfReader<IntPtrT>::readRawCounts(
442 Error RawInstrProfReader<IntPtrT>::readValueProfilingData(
459 if (Error E = VDataPtrOrErr.takeError())
471 Error RawInstrProfReader<IntPtrT>::readNextRecord(NamedInstrProfRecord &Record) {
474 if (Error E = readNextHeader(getNextHeaderPos()))
478 if (Error E = readName(Record))
482 if (Error E = readFuncHash(Record))
486 if (Error E = readRawCounts(Record))
490 if (Error E = readValueProfilingData(Record))
575 Error InstrProfReaderIndex<HashTableImpl>::getRecords(
585 return Error::success();
589 Error InstrProfReaderIndex<HashTableImpl>::getRecords(
599 return Error::success();
623 Error getRecords(StringRef FuncName,
667 Error populateRemappings() override {
668 if (Error E = Remappings.read(*RemapBuffer))
679 return Error::success();
682 Error getRecords(StringRef FuncName,
695 Error E = Underlying.getRecords(Reconstituted, Data);
701 if (Error Unhandled = handleErrors(
704 ? Error::success()
797 Error IndexedInstrProfReader::readHeader() {
844 if (Error E = Remapper->populateRemappings())
859 if (Error E = Index->populateSymtab(*NewSymtab.get())) {
871 Error Err = Remapper->getRecords(FuncName, Data);
884 Error IndexedInstrProfReader::getFunctionCounts(StringRef FuncName,
888 if (Error E = Record.takeError())
895 Error IndexedInstrProfReader::readNextRecord(NamedInstrProfRecord &Record) {
898 Error E = Index->getRecords(Data);
lib/ProfileData/InstrProfWriter.cpp 184 function_ref<void(Error)> Warn) {
226 function_ref<void(Error)> Warn) {
253 function_ref<void(Error)> Warn) {
439 Error InstrProfWriter::writeText(raw_fd_ostream &OS) {
452 if (Error E = Symtab.addFuncName(I.getKey()))
470 return Error::success();
lib/ProfileData/SampleProfReader.cpp 596 llvm::Error E =
1309 if (Error E = Remappings->read(*B.get())) {
lib/ProfileData/SampleProfWriter.cpp 104 llvm::Error E = zlib::compress(UncompressedStrings, CompressedStrings,
lib/Remarks/BitstreamRemarkParser.cpp 23 static Error unknownRecord(const char *BlockName, unsigned RecordID) {
30 static Error malformedRecord(const char *BlockName, const char *RecordName) {
42 static Error parseRecord(BitstreamMetaParserHelper &Parser, unsigned Code) {
81 return Error::success();
89 static Error parseRecord(BitstreamRemarkParserHelper &Parser, unsigned Code) {
154 return Error::success();
158 static Error parseBlock(T &ParserHelper, unsigned BlockID,
182 return Error::success();
189 if (Error E = parseRecord(ParserHelper, Next->ID))
201 Error BitstreamMetaParserHelper::parse() {
205 Error BitstreamRemarkParserHelper::parse() {
222 Error BitstreamParserHelper::parseBlockInfoBlock() {
246 return Error::success();
268 if (Error E = Stream.JumpToBit(PreviousBitNo))
281 static Error validateMagicNumber(StringRef Magic) {
286 return Error::success();
289 static Error advanceToMetaBlock(BitstreamParserHelper &Helper) {
293 if (Error E = validateMagicNumber(StringRef(Magic->data(), Magic->size())))
295 if (Error E = Helper.parseBlockInfoBlock())
304 return Error::success();
316 if (Error E = validateMagicNumber(StringRef(Magic->data(), Magic->size())))
334 if (Error E = parseMeta())
342 Error BitstreamRemarkParser::parseMeta() {
344 if (Error E = advanceToMetaBlock(ParserHelper))
349 if (Error E = MetaHelper.parse())
352 if (Error E = processCommonMeta(MetaHelper))
366 Error BitstreamRemarkParser::processCommonMeta(
388 return Error::success();
391 static Error processStrTab(BitstreamRemarkParser &P,
399 return Error::success();
402 static Error processRemarkVersion(BitstreamRemarkParser &P,
409 return Error::success();
412 Error BitstreamRemarkParser::processExternalFilePath(
434 if (Error E = advanceToMetaBlock(ParserHelper))
441 if (Error E = SeparateMetaHelper.parse())
445 if (Error E = processCommonMeta(SeparateMetaHelper))
465 Error BitstreamRemarkParser::processStandaloneMeta(
467 if (Error E = processStrTab(*this, Helper.StrTabBuf))
472 Error BitstreamRemarkParser::processSeparateRemarksFileMeta(
477 Error BitstreamRemarkParser::processSeparateRemarksMetaMeta(
479 if (Error E = processStrTab(*this, Helper.StrTabBuf))
486 if (Error E = RemarkHelper.parse())
lib/Remarks/BitstreamRemarkParser.h 60 Error parseMeta();
67 Error processCommonMeta(BitstreamMetaParserHelper &Helper);
68 Error processStandaloneMeta(BitstreamMetaParserHelper &Helper);
69 Error processSeparateRemarksFileMeta(BitstreamMetaParserHelper &Helper);
70 Error processSeparateRemarksMetaMeta(BitstreamMetaParserHelper &Helper);
73 Error processExternalFilePath(Optional<StringRef> ExternalFilePath);
lib/Remarks/RemarkParser.cpp 121 void handleError(Error E) { Err.emplace(toString(std::move(E))); }
148 if (Error E = MaybeRemark.takeError()) {
lib/Remarks/YAMLRemarkParser.cpp 178 Error YAMLRemarkParser::error(StringRef Message, yaml::Node &Node) {
182 Error YAMLRemarkParser::error() {
184 return Error::success();
185 Error E = make_error<YAMLParseError>(LastErrorMessage);
192 if (Error E = error())
lib/Remarks/YAMLRemarkParser.h 79 Error error();
81 Error error(StringRef Message, yaml::Node &Node);
lib/Support/BinaryStreamReader.cpp 29 Error BinaryStreamReader::readLongestContiguousChunk(
31 if (auto EC = Stream.readLongestContiguousChunk(Offset, Buffer))
34 return Error::success();
37 Error BinaryStreamReader::readBytes(ArrayRef<uint8_t> &Buffer, uint32_t Size) {
38 if (auto EC = Stream.readBytes(Offset, Size, Buffer))
41 return Error::success();
44 Error BinaryStreamReader::readULEB128(uint64_t &Dest) {
50 if (auto Err = readBytes(NextByte, 1))
56 return Error::success();
59 Error BinaryStreamReader::readSLEB128(int64_t &Dest) {
65 if (auto Err = readBytes(NextByte, 1))
71 return Error::success();
74 Error BinaryStreamReader::readCString(StringRef &Dest) {
80 if (auto EC = readLongestContiguousChunk(Buffer))
94 if (auto EC = readFixedString(Dest, Length))
99 return Error::success();
102 Error BinaryStreamReader::readWideString(ArrayRef<UTF16> &Dest) {
107 if (auto EC = readObject(C))
116 if (auto EC = readArray(Dest, Length))
119 return Error::success();
122 Error BinaryStreamReader::readFixedString(StringRef &Dest, uint32_t Length) {
124 if (auto EC = readBytes(Bytes, Length))
127 return Error::success();
130 Error BinaryStreamReader::readStreamRef(BinaryStreamRef &Ref) {
134 Error BinaryStreamReader::readStreamRef(BinaryStreamRef &Ref, uint32_t Length) {
139 return Error::success();
142 Error BinaryStreamReader::readSubstream(BinarySubstreamRef &Stream,
148 Error BinaryStreamReader::skip(uint32_t Amount) {
152 return Error::success();
155 Error BinaryStreamReader::padToAlignment(uint32_t Align) {
162 auto EC = Stream.readBytes(Offset, 1, Buffer);
lib/Support/BinaryStreamRef.cpp 24 Error readBytes(uint32_t Offset, uint32_t Size,
28 Error readLongestContiguousChunk(uint32_t Offset,
47 Error readBytes(uint32_t Offset, uint32_t Size,
51 Error readLongestContiguousChunk(uint32_t Offset,
57 Error writeBytes(uint32_t Offset, ArrayRef<uint8_t> Data) override {
60 Error commit() override { return BBS.commit(); }
79 Error BinaryStreamRef::readBytes(uint32_t Offset, uint32_t Size,
81 if (auto EC = checkOffsetForRead(Offset, Size))
86 Error BinaryStreamRef::readLongestContiguousChunk(
88 if (auto EC = checkOffsetForRead(Offset, 1))
91 if (auto EC =
100 return Error::success();
117 Error WritableBinaryStreamRef::writeBytes(uint32_t Offset,
119 if (auto EC = checkOffsetForWrite(Offset, Data.size()))
130 Error WritableBinaryStreamRef::commit() { return BorrowedImpl->commit(); }
lib/Support/BinaryStreamWriter.cpp 28 Error BinaryStreamWriter::writeBytes(ArrayRef<uint8_t> Buffer) {
29 if (auto EC = Stream.writeBytes(Offset, Buffer))
32 return Error::success();
35 Error BinaryStreamWriter::writeULEB128(uint64_t Value) {
41 Error BinaryStreamWriter::writeSLEB128(int64_t Value) {
47 Error BinaryStreamWriter::writeCString(StringRef Str) {
48 if (auto EC = writeFixedString(Str))
50 if (auto EC = writeObject('\0'))
53 return Error::success();
56 Error BinaryStreamWriter::writeFixedString(StringRef Str) {
61 Error BinaryStreamWriter::writeStreamRef(BinaryStreamRef Ref) {
65 Error BinaryStreamWriter::writeStreamRef(BinaryStreamRef Ref, uint32_t Length) {
74 if (auto EC = SrcReader.readLongestContiguousChunk(Chunk))
76 if (auto EC = writeBytes(Chunk))
79 return Error::success();
95 Error BinaryStreamWriter::padToAlignment(uint32_t Align) {
100 if (auto EC = writeInteger('\0'))
102 return Error::success();
lib/Support/Compression.cpp 90 Error zlib::compress(StringRef InputBuffer,
94 Error zlib::uncompress(StringRef InputBuffer, char *UncompressedBuffer,
98 Error zlib::uncompress(StringRef InputBuffer,
lib/Support/DataExtractor.cpp 18 static void unexpectedEndReached(Error *E) {
24 static bool isError(Error *E) { return E && *E; }
28 bool isLittleEndian, const char *Data, llvm::Error *Err) {
51 llvm::Error *Err) {
72 uint8_t DataExtractor::getU8(uint64_t *offset_ptr, llvm::Error *Err) const {
87 uint16_t DataExtractor::getU16(uint64_t *offset_ptr, llvm::Error *Err) const {
104 uint32_t DataExtractor::getU32(uint64_t *offset_ptr, llvm::Error *Err) const {
114 uint64_t DataExtractor::getU64(uint64_t *offset_ptr, llvm::Error *Err) const {
125 llvm::Error *Err) const {
175 llvm::Error *Err) const {
lib/Support/Error.cpp 61 void logAllUnhandledErrors(Error E, raw_ostream &OS, Twine ErrorBanner) {
87 Error errorCodeToError(std::error_code EC) {
89 return Error::success();
93 std::error_code errorToErrorCode(Error Err) {
135 Error createStringError(std::error_code EC, char const *Msg) {
139 void report_fatal_error(Error Err, bool GenCrashDiag) {
lib/Support/FileCheck.cpp 43 Error Err = Error::success();
43 Error Err = Error::success();
1133 Error DefineError =
1338 std::vector<FileCheckDiag> *Diags, Error MatchErrors) {
1396 std::vector<FileCheckDiag> *Diags, Error MatchErrors) {
1768 Error FileCheckPatternContext::defineCmdlineVariables(
1774 return Error::success();
1780 Error Errs = Error::success();
1780 Error Errs = Error::success();
lib/Support/FileCheckImpl.h 290 Error defineCmdlineVariables(std::vector<std::string> &CmdlineDefines,
340 static Error get(const SourceMgr &SM, SMLoc Loc, const Twine &ErrMsg) {
345 static Error get(const SourceMgr &SM, StringRef Buffer, const Twine &ErrMsg) {
lib/Support/FileOutputBuffer.cpp 48 Error commit() override {
91 Error commit() override {
95 return Error::success();
106 return Error::success();
lib/Support/FileUtilities.cpp 288 llvm::Error llvm::writeFileAtomically(StringRef TempPathModel,
293 return llvm::Error::success();
297 llvm::Error llvm::writeFileAtomically(
299 std::function<llvm::Error(llvm::raw_ostream &)> Writer) {
310 if (llvm::Error Err = Writer(OS)) {
329 return Error::success();
lib/Support/JSON.cpp 225 Error takeError() {
250 Optional<Error> Err;
lib/Support/Path.cpp 1134 Error TempFile::discard() {
1159 Error TempFile::keep(const Twine &Name) {
1204 Error TempFile::keep() {
1224 return Error::success();
lib/Support/SymbolRemappingReader.cpp 27 Error SymbolRemappingReader::read(MemoryBuffer &B) {
79 return Error::success();
lib/Testing/Support/Error.cpp 15 llvm::detail::ErrorHolder llvm::detail::TakeError(llvm::Error Err) {
lib/TextAPI/ELF/TBEHandler.cpp 155 Error elfabi::writeTBEToOutputStream(raw_ostream &OS, const ELFStub &Stub) {
159 return Error::success();
lib/TextAPI/MachO/TextStub.cpp 1128 Error TextAPIWriter::writeToStream(raw_ostream &OS, const InterfaceFile &File) {
1140 return Error::success();
lib/ToolDrivers/llvm-lib/LibDriver.cpp 104 static void fatalOpenError(llvm::Error E, Twine File) {
132 Error Err = Error::success();
132 Error Err = Error::success();
208 Error Err = Error::success();
208 Error Err = Error::success();
368 if (Error E =
lib/Transforms/IPO/FunctionImport.cpp 1101 if (Error Err = SrcModule->materializeMetadata())
1116 if (Error Err = F.materialize())
1138 if (Error Err = GV.materialize())
1152 if (Error Err = GA.materialize())
1156 if (Error Err = Base->materialize())
lib/Transforms/Instrumentation/IndirectCallPromotion.cpp 388 if (Error E = Symtab.create(M, InLTO)) {
lib/Transforms/Instrumentation/InstrProfiling.cpp 917 if (Error E = collectPGOFuncNameStrings(ReferencedNames, CompressedNameStr,
lib/Transforms/Instrumentation/PGOInstrumentation.cpp 1144 if (Error E = Result.takeError()) {
1528 if (Error E = ReaderOrErr.takeError()) {
lib/WindowsManifest/WindowsManifestMerger.cpp 38 Error merge(const MemoryBuffer &Manifest);
43 Error getParseError();
692 Error WindowsManifestMerger::WindowsManifestMergerImpl::merge(
711 Error WindowsManifestMerger::merge(const MemoryBuffer &Manifest) {
725 Error WindowsManifestMerger::WindowsManifestMergerImpl::getParseError() {
727 return Error::success();
lib/XRay/BlockIndexer.cpp 18 Error BlockIndexer::visit(BufferExtents &) { return Error::success(); }
18 Error BlockIndexer::visit(BufferExtents &) { return Error::success(); }
20 Error BlockIndexer::visit(WallclockRecord &R) {
23 return Error::success();
26 Error BlockIndexer::visit(NewCPUIDRecord &R) {
28 return Error::success();
31 Error BlockIndexer::visit(TSCWrapRecord &R) {
33 return Error::success();
36 Error BlockIndexer::visit(CustomEventRecord &R) {
38 return Error::success();
41 Error BlockIndexer::visit(CustomEventRecordV5 &R) {
43 return Error::success();
46 Error BlockIndexer::visit(TypedEventRecord &R) {
48 return Error::success();
51 Error BlockIndexer::visit(CallArgRecord &R) {
53 return Error::success();
56 Error BlockIndexer::visit(PIDRecord &R) {
59 return Error::success();
62 Error BlockIndexer::visit(NewBufferRecord &R) {
64 if (auto E = flush())
69 return Error::success();
72 Error BlockIndexer::visit(EndBufferRecord &R) {
74 return Error::success();
77 Error BlockIndexer::visit(FunctionRecord &R) {
79 return Error::success();
82 Error BlockIndexer::flush() {
93 return Error::success();
lib/XRay/BlockPrinter.cpp 13 Error BlockPrinter::visit(BufferExtents &R) {
20 Error BlockPrinter::visit(NewBufferRecord &R) {
29 Error BlockPrinter::visit(WallclockRecord &R) {
34 Error BlockPrinter::visit(PIDRecord &R) {
40 Error BlockPrinter::visit(NewCPUIDRecord &R) {
47 auto E = RP.visit(R);
51 Error BlockPrinter::visit(TSCWrapRecord &R) {
56 auto E = RP.visit(R);
61 Error BlockPrinter::visit(CustomEventRecord &R) {
66 auto E = RP.visit(R);
70 Error BlockPrinter::visit(CustomEventRecordV5 &R) {
75 auto E = RP.visit(R);
79 Error BlockPrinter::visit(TypedEventRecord &R) {
84 auto E = RP.visit(R);
89 Error BlockPrinter::visit(FunctionRecord &R) {
94 auto E = RP.visit(R);
98 Error BlockPrinter::visit(CallArgRecord &R) {
101 auto E = RP.visit(R);
105 Error BlockPrinter::visit(EndBufferRecord &R) {
108 auto E = RP.visit(R);
lib/XRay/BlockVerifier.cpp 61 Error BlockVerifier::transition(State To) {
120 return Error::success();
133 return Error::success();
136 Error BlockVerifier::visit(BufferExtents &) {
140 Error BlockVerifier::visit(WallclockRecord &) {
144 Error BlockVerifier::visit(NewCPUIDRecord &) {
148 Error BlockVerifier::visit(TSCWrapRecord &) {
152 Error BlockVerifier::visit(CustomEventRecord &) {
156 Error BlockVerifier::visit(CustomEventRecordV5 &) {
160 Error BlockVerifier::visit(TypedEventRecord &) {
164 Error BlockVerifier::visit(CallArgRecord &) {
168 Error BlockVerifier::visit(PIDRecord &) { return transition(State::PIDEntry); }
170 Error BlockVerifier::visit(NewBufferRecord &) {
174 Error BlockVerifier::visit(EndBufferRecord &) {
178 Error BlockVerifier::visit(FunctionRecord &) {
182 Error BlockVerifier::verify() {
192 return Error::success();
lib/XRay/FDRRecordProducer.cpp 103 if (auto Err = R->apply(RI))
174 if (auto Err = R->apply(RI))
lib/XRay/FDRRecords.cpp 18 Error BufferExtents::apply(RecordVisitor &V) { return V.visit(*this); }
19 Error WallclockRecord::apply(RecordVisitor &V) { return V.visit(*this); }
20 Error NewCPUIDRecord::apply(RecordVisitor &V) { return V.visit(*this); }
21 Error TSCWrapRecord::apply(RecordVisitor &V) { return V.visit(*this); }
22 Error CustomEventRecord::apply(RecordVisitor &V) { return V.visit(*this); }
23 Error CallArgRecord::apply(RecordVisitor &V) { return V.visit(*this); }
24 Error PIDRecord::apply(RecordVisitor &V) { return V.visit(*this); }
25 Error NewBufferRecord::apply(RecordVisitor &V) { return V.visit(*this); }
26 Error EndBufferRecord::apply(RecordVisitor &V) { return V.visit(*this); }
27 Error FunctionRecord::apply(RecordVisitor &V) { return V.visit(*this); }
28 Error CustomEventRecordV5::apply(RecordVisitor &V) { return V.visit(*this); }
29 Error TypedEventRecord::apply(RecordVisitor &V) { return V.visit(*this); }
lib/XRay/FDRTraceExpander.cpp 21 Error TraceExpander::visit(BufferExtents &) {
23 return Error::success();
26 Error TraceExpander::visit(WallclockRecord &) { return Error::success(); }
26 Error TraceExpander::visit(WallclockRecord &) { return Error::success(); }
28 Error TraceExpander::visit(NewCPUIDRecord &R) {
31 return Error::success();
34 Error TraceExpander::visit(TSCWrapRecord &R) {
36 return Error::success();
39 Error TraceExpander::visit(CustomEventRecord &R) {
50 return Error::success();
53 Error TraceExpander::visit(CustomEventRecordV5 &R) {
65 return Error::success();
68 Error TraceExpander::visit(TypedEventRecord &R) {
81 return Error::success();
84 Error TraceExpander::visit(CallArgRecord &R) {
87 return Error::success();
90 Error TraceExpander::visit(PIDRecord &R) {
92 return Error::success();
95 Error TraceExpander::visit(NewBufferRecord &R) {
101 return Error::success();
104 Error TraceExpander::visit(EndBufferRecord &) {
107 return Error::success();
110 Error TraceExpander::visit(FunctionRecord &R) {
122 return Error::success();
125 Error TraceExpander::flush() {
127 return Error::success();
lib/XRay/FDRTraceWriter.cpp 44 Error writeMetadata(support::endian::Writer &OS, Values &&... Ds) {
56 return Error::success();
81 Error FDRTraceWriter::visit(BufferExtents &R) {
85 Error FDRTraceWriter::visit(WallclockRecord &R) {
89 Error FDRTraceWriter::visit(NewCPUIDRecord &R) {
93 Error FDRTraceWriter::visit(TSCWrapRecord &R) {
97 Error FDRTraceWriter::visit(CustomEventRecord &R) {
98 if (auto E = writeMetadata<5u>(OS, R.size(), R.tsc(), R.cpu()))
103 return Error::success();
106 Error FDRTraceWriter::visit(CustomEventRecordV5 &R) {
107 if (auto E = writeMetadata<5u>(OS, R.size(), R.delta()))
112 return Error::success();
115 Error FDRTraceWriter::visit(TypedEventRecord &R) {
116 if (auto E = writeMetadata<8u>(OS, R.size(), R.delta(), R.eventType()))
121 return Error::success();
124 Error FDRTraceWriter::visit(CallArgRecord &R) {
128 Error FDRTraceWriter::visit(PIDRecord &R) {
132 Error FDRTraceWriter::visit(NewBufferRecord &R) {
136 Error FDRTraceWriter::visit(EndBufferRecord &R) {
140 Error FDRTraceWriter::visit(FunctionRecord &R) {
149 return Error::success();
lib/XRay/InstrumentationMap.cpp 52 static Error
172 return Error::success();
175 static Error
203 return Error::success();
217 auto E = ObjectFileOrError.takeError();
237 if (auto E = loadYAML(*FdOrErr, FileSize, Filename, Map.Sleds,
240 } else if (auto E = loadObj(Filename, *ObjectFileOrError, Map.Sleds,
lib/XRay/LogBuilderConsumer.cpp 13 Error LogBuilderConsumer::consume(std::unique_ptr<Record> R) {
19 return Error::success();
22 Error PipelineConsumer::consume(std::unique_ptr<Record> R) {
30 Error Result = Error::success();
30 Error Result = Error::success();
lib/XRay/Profile.cpp 121 Error Profile::addBlock(Block &&B) {
128 return Error::success();
308 if (auto E =
391 if (auto E = P.addBlock({
lib/XRay/RecordInitializer.cpp 13 Error RecordInitializer::visit(BufferExtents &R) {
27 return Error::success();
30 Error RecordInitializer::visit(WallclockRecord &R) {
56 return Error::success();
59 Error RecordInitializer::visit(NewCPUIDRecord &R) {
81 return Error::success();
84 Error RecordInitializer::visit(TSCWrapRecord &R) {
99 return Error::success();
102 Error RecordInitializer::visit(CustomEventRecord &R) {
172 return Error::success();
175 Error RecordInitializer::visit(CustomEventRecordV5 &R) {
236 return Error::success();
239 Error RecordInitializer::visit(TypedEventRecord &R) {
308 return Error::success();
311 Error RecordInitializer::visit(CallArgRecord &R) {
327 return Error::success();
330 Error RecordInitializer::visit(PIDRecord &R) {
345 return Error::success();
348 Error RecordInitializer::visit(NewBufferRecord &R) {
363 return Error::success();
366 Error RecordInitializer::visit(EndBufferRecord &R) {
375 return Error::success();
378 Error RecordInitializer::visit(FunctionRecord &R) {
427 return Error::success();
lib/XRay/RecordPrinter.cpp 15 Error RecordPrinter::visit(BufferExtents &R) {
17 return Error::success();
20 Error RecordPrinter::visit(WallclockRecord &R) {
23 return Error::success();
26 Error RecordPrinter::visit(NewCPUIDRecord &R) {
28 return Error::success();
31 Error RecordPrinter::visit(TSCWrapRecord &R) {
33 return Error::success();
36 Error RecordPrinter::visit(CustomEventRecord &R) {
41 return Error::success();
44 Error RecordPrinter::visit(CustomEventRecordV5 &R) {
48 return Error::success();
51 Error RecordPrinter::visit(TypedEventRecord &R) {
56 return Error::success();
59 Error RecordPrinter::visit(CallArgRecord &R) {
61 return Error::success();
64 Error RecordPrinter::visit(PIDRecord &R) {
66 return Error::success();
69 Error RecordPrinter::visit(NewBufferRecord &R) {
71 return Error::success();
74 Error RecordPrinter::visit(EndBufferRecord &R) {
76 return Error::success();
79 Error RecordPrinter::visit(FunctionRecord &R) {
104 return Error::success();
lib/XRay/Trace.cpp 36 Error loadNaiveFormatLog(StringRef Data, bool IsLittleEndian,
210 return Error::success();
267 Error loadFDRLog(StringRef Data, bool IsLittleEndian,
291 if (auto E = C.consume(std::move(R.get())))
301 if (auto E = R->apply(Indexer))
303 if (auto E = Indexer.flush())
314 if (auto E = R->apply(Verifier))
316 if (auto E = Verifier.verify())
339 if (auto E = R->apply(Expander))
342 if (auto E = Expander.flush())
347 return Error::success();
350 Error loadYAMLLog(StringRef Data, XRayFileHeader &FileHeader,
376 return Error::success();
444 if (auto E = loadNaiveFormatLog(DE.getData(), DE.isLittleEndian(),
456 if (auto E = loadFDRLog(DE.getData(), DE.isLittleEndian(), T.FileHeader,
466 if (auto E = loadYAMLLog(DE.getData(), T.FileHeader, T.Records))
tools/bugpoint/BugDriver.cpp 36 if (Error E = File.keep())
40 if (Error E = File.discard())
162 Error BugDriver::run() {
183 if (Error E = initializeExecutionEnvironment())
188 if (Error E = compileProgram(*Program)) {
201 if (Error E = createReferenceFile(*Program)) {
218 if (Error E = Diff.takeError()) {
224 if (Error E = debugMiscompilation()) {
228 return Error::success();
233 if (Error E = debugCodeGenerator()) {
237 return Error::success();
tools/bugpoint/BugDriver.h 89 Error run();
95 Error debugOptimizerCrash(const std::string &ID = "passes");
100 Error debugCodeGeneratorCrash();
105 Error debugMiscompilation();
124 Error debugCodeGenerator();
150 Error compileProgram(Module &M) const;
170 Error createReferenceFile(Module &M, const std::string &Filename =
251 Error runManyPasses(const std::vector<std::string> &AllPasses);
264 Error initializeExecutionEnvironment();
tools/bugpoint/CrashDebugger.cpp 949 static Error ReduceGlobalInitializers(BugDriver &BD, BugTester TestFn) {
952 return Error::success();
969 return Error::success();
977 return Error::success();
995 if (Error E = Result.takeError())
1001 return Error::success();
1004 static Error ReduceInsts(BugDriver &BD, BugTester TestFn) {
1017 if (Error E = Result.takeError())
1025 return Error::success();
1057 return Error::success();
1085 return Error::success();
1091 static Error DebugACrash(BugDriver &BD, BugTester TestFn) {
1095 if (Error E = ReduceGlobalInitializers(BD, TestFn))
1111 if (Error E = Result.takeError())
1140 if (Error E = Result.takeError())
1160 if (Error E = Result.takeError())
1163 if (Error E = Result.takeError())
1181 if (Error E = Result.takeError())
1194 if (Error E = Result.takeError())
1203 if (Error E = ReduceInsts(BD, TestFn))
1232 if (Error E = Result.takeError())
1245 if (Error E = Result.takeError())
1265 return Error::success();
1276 Error BugDriver::debugOptimizerCrash(const std::string &ID) {
1282 if (Error E = Result.takeError())
1296 if (Error E = BD.compileProgram(*M)) {
1312 Error BugDriver::debugCodeGeneratorCrash() {
tools/bugpoint/ExecutionDriver.cpp 141 Error BugDriver::initializeExecutionEnvironment() {
265 return Error::success();
270 Error BugDriver::compileProgram(Module &M) const {
349 if (Error E = RetVal.takeError())
395 if (Error E = FT.takeError())
399 if (Error E = cc->MakeSharedObject(OutputFile, *FT, SharedObjectFile,
412 Error BugDriver::createReferenceFile(Module &M, const std::string &Filename) {
413 if (Error E = compileProgram(*Program))
417 if (Error E = Result.takeError()) {
432 return Error::success();
446 if (Error E = Output.takeError())
tools/bugpoint/FindBugs.cpp 22 Error
28 if (Error E = initializeExecutionEnvironment())
34 if (Error E = createReferenceFile(*Program))
67 if (Error E = compileProgram(*Program)) {
80 if (Error E = Diff.takeError()) {
86 Error E = debugMiscompilation();
88 return Error::success();
tools/bugpoint/ListReducer.h 51 if (Error E = Result.takeError())
124 if (Error E = Result.takeError())
187 if (Error E = Result.takeError())
tools/bugpoint/Miscompilation.cpp 76 if (Error E = BD.debugOptimizerCrash())
84 if (Error E = Diff.takeError())
118 if (Error E = BD.debugOptimizerCrash())
125 if (Error E = Diff.takeError())
163 if (Error E = BD.debugOptimizerCrash())
171 if (Error E = Diff.takeError())
202 if (Error E = Ret.takeError())
209 if (Error E = Ret.takeError())
239 if (Error E = Diff.takeError())
337 if (Error E = New.takeError())
379 if (Error E = Result.takeError())
462 if (Error E = Ret.takeError())
469 if (Error E = Ret.takeError())
556 if (Error E = Ret.takeError())
564 if (Error E = Ret.takeError())
630 if (Error E = Ret.takeError()) {
646 if (Error E = Ret.takeError())
657 if (Error E = Ret.takeError())
670 if (Error E = Ret.takeError())
680 if (Error E = Ret.takeError())
710 if (Error E = BD.debugOptimizerCrash())
719 if (Error E = Result.takeError())
733 Error BugDriver::debugMiscompilation() {
738 if (Error E = Result.takeError())
754 if (Error E = MiscompiledFunctions.takeError())
773 return Error::success();
984 if (Error E = SharedObject.takeError())
993 if (Error E = Result.takeError())
1006 Error BugDriver::debugCodeGenerator() {
1019 return Error::success();
1026 if (Error E = Funcs.takeError())
1070 if (Error E = SharedObject.takeError())
1095 return Error::success();
tools/bugpoint/ToolRunner.cpp 106 static Error ProcessFailure(StringRef ProgPath, ArrayRef<StringRef> Args,
249 Error compileProgram(const std::string &Bitcode, unsigned Timeout = 0,
265 Error CustomCompiler::compileProgram(const std::string &Bitcode,
282 return Error::success();
471 Error LLC::compileProgram(const std::string &Bitcode, unsigned Timeout,
477 if (Error E = Result.takeError())
479 return Error::success();
494 if (Error E = FileKind.takeError())
765 Error CC::MakeSharedObject(const std::string &InputFile, FileType fileType,
837 return Error::success();
tools/bugpoint/ToolRunner.h 72 Error MakeSharedObject(const std::string &InputFile, FileType fileType,
113 virtual Error compileProgram(const std::string &Bitcode, unsigned Timeout = 0,
115 return Error::success();
166 Error compileProgram(const std::string &Bitcode, unsigned Timeout = 0,
tools/bugpoint/bugpoint.cpp 236 if (Error E = D.run()) {
tools/clang/examples/clang-interpreter/main.cpp 97 Error addModule(ThreadSafeModule M) {
tools/clang/include/clang/AST/ASTImporter.h 341 LLVM_NODISCARD llvm::Error importInto(ImportT &To, const ImportT &From) {
499 LLVM_NODISCARD llvm::Error ImportDefinition(Decl *From);
tools/clang/include/clang/Basic/Diagnostic.h 1301 llvm::Error &&E) {
tools/clang/include/clang/Basic/DiagnosticError.h 31 static llvm::Error create(SourceLocation Loc, PartialDiagnostic Diag) {
39 static Optional<PartialDiagnosticAt> take(llvm::Error &Err) {
tools/clang/include/clang/CrossTU/CrossTranslationUnit.h 276 llvm::Error ensureCTUIndexLoaded(StringRef CrossTUDir, StringRef IndexName);
tools/clang/include/clang/Frontend/FrontendAction.h 233 llvm::Error Execute();
tools/clang/include/clang/Serialization/ASTReader.h 1446 void Error(llvm::Error &&Err) const;
2692 if (llvm::Error Err = Cursor.JumpToBit(Offset))
tools/clang/include/clang/Serialization/GlobalModuleIndex.h 133 static std::pair<GlobalModuleIndex *, llvm::Error>
185 static llvm::Error writeIndex(FileManager &FileMgr,
tools/clang/include/clang/Tooling/AllTUsExecution.h 49 llvm::Error
tools/clang/include/clang/Tooling/CommonOptionsParser.h 120 llvm::Error init(int &argc, const char **argv,
tools/clang/include/clang/Tooling/Core/Replacement.h 258 llvm::Error add(const Replacement &R);
tools/clang/include/clang/Tooling/DependencyScanning/DependencyScanningWorker.h 58 llvm::Error computeDependencies(const std::string &Input,
tools/clang/include/clang/Tooling/DiagnosticsYaml.h 41 llvm::Error Err = M.Fix[Fix.getFilePath()].add(Fix);
tools/clang/include/clang/Tooling/Execution.h 119 virtual llvm::Error
125 llvm::Error execute(std::unique_ptr<FrontendActionFactory> Action);
127 llvm::Error execute(std::unique_ptr<FrontendActionFactory> Action,
tools/clang/include/clang/Tooling/Refactoring/AtomicChange.h 84 llvm::Error replace(const SourceManager &SM, const CharSourceRange &Range,
90 llvm::Error replace(const SourceManager &SM, SourceLocation Loc,
101 llvm::Error insert(const SourceManager &SM, SourceLocation Loc,
tools/clang/include/clang/Tooling/Refactoring/RefactoringActionRulesInternal.h 24 inline llvm::Error findError() { return llvm::Error::success(); }
24 inline llvm::Error findError() { return llvm::Error::success(); }
38 llvm::Error findError(Expected<FirstT> &First, Expected<RestT> &... Rest) {
54 auto Err = findError(std::get<Is>(Values)...);
tools/clang/include/clang/Tooling/Refactoring/RefactoringResultConsumer.h 30 virtual void handleError(llvm::Error Err) = 0;
tools/clang/include/clang/Tooling/Refactoring/RefactoringRuleContext.h 57 llvm::Error createDiagnosticError(SourceLocation Loc, unsigned DiagID) {
61 llvm::Error createDiagnosticError(unsigned DiagID) {
tools/clang/include/clang/Tooling/StandaloneExecution.h 57 llvm::Error
tools/clang/include/clang/Tooling/Transformer/MatchConsumer.h 39 inline llvm::Error notBoundError(llvm::StringRef Id) {
tools/clang/include/clang/Tooling/Transformer/Stencil.h 47 virtual llvm::Error eval(const ast_matchers::MatchFinder::MatchResult &Match,
72 llvm::Error eval(const ast_matchers::MatchFinder::MatchResult &Match,
tools/clang/lib/AST/ASTImporter.cpp 146 LLVM_NODISCARD Error importInto(ImportT &To, const ImportT &From) {
152 LLVM_NODISCARD Error importInto(ImportT *&To, ImportT *From) {
356 Error ImportDeclParts(
359 Error ImportDefinitionIfNeeded(Decl *FromD, Decl *ToD = nullptr);
360 Error ImportDeclarationNameLoc(
362 Error ImportDeclContext(DeclContext *FromDC, bool ForceImport = false);
363 Error ImportDeclContext(
365 Error ImportImplicitMethods(const CXXRecordDecl *From, CXXRecordDecl *To);
389 Error ImportInitializer(VarDecl *From, VarDecl *To);
390 Error ImportDefinition(
393 Error ImportDefinition(
396 Error ImportDefinition(
399 Error ImportDefinition(
402 Error ImportTemplateArguments(
409 Error ImportTemplateArgumentListInfo(
413 Error ImportTemplateArgumentListInfo(
423 Error ImportTemplateParameterLists(const DeclaratorDecl *FromD,
426 Error ImportTemplateInformation(FunctionDecl *FromFD, FunctionDecl *ToFD);
428 Error ImportFunctionDeclBody(FunctionDecl *FromFD, FunctionDecl *ToFD);
430 Error ImportDefaultArgOfParmVarDecl(const ParmVarDecl *FromParam,
615 Error ImportArrayChecked(IIter Ibegin, IIter Iend, OIter Obegin) {
623 return Error::success();
631 Error ImportContainerChecked(
638 Error ImportArrayChecked(const InContainerTy &InContainer, OIter Obegin) {
642 Error ImportOverriddenMethods(CXXMethodDecl *ToMethod,
650 Error ASTNodeImporter::ImportTemplateArgumentListInfo(
661 if (auto Err = ImportTemplateArgumentListInfo(Container, ToTAInfo))
664 return Error::success();
668 Error ASTNodeImporter::ImportTemplateArgumentListInfo<TemplateArgumentListInfo>(
675 Error ASTNodeImporter::ImportTemplateArgumentListInfo<
692 if (Error Err = importInto(std::get<0>(Result), FTSInfo->getTemplate()))
697 if (Error Err = ImportTemplateArguments(TemplArgs.data(), TemplArgs.size(),
708 if (Error Err = ImportContainerChecked(*From, To))
799 if (Error Err = ImportTemplateArguments(
927 if (Error Err = importInto(EllipsisLoc, From.getEllipsisLoc()))
1406 if (Error Err = ImportTemplateArguments(
1464 if (Error Err = ImportTemplateArguments(
1541 Error ASTNodeImporter::ImportDeclParts(
1569 if (Error Err = ImportDeclContext(D, DC, LexicalDC))
1573 if (Error Err = importInto(Name, D->getDeclName()))
1577 if (Error Err = importInto(Loc, D->getLocation()))
1582 if (Error Err = ASTNodeImporter(*this).ImportDefinitionIfNeeded(D, ToD))
1585 return Error::success();
1588 Error ASTNodeImporter::ImportDefinitionIfNeeded(Decl *FromD, Decl *ToD) {
1590 return Error::success();
1593 if (Error Err = importInto(ToD, FromD))
1600 if (Error Err = ImportDefinition(FromRecord, ToRecord))
1604 return Error::success();
1610 if (Error Err = ImportDefinition(FromEnum, ToEnum))
1614 return Error::success();
1617 return Error::success();
1620 Error
1632 return Error::success();
1639 return Error::success();
1646 return Error::success();
1655 return Error::success();
1661 Error
1679 Error ChildErrors = Error::success();
1679 Error ChildErrors = Error::success();
1747 Error ASTNodeImporter::ImportDeclContext(
1763 return Error::success();
1766 Error ASTNodeImporter::ImportImplicitMethods(
1778 return Error::success();
1781 static Error setTypedefNameForAnonDecl(TagDecl *From, TagDecl *To,
1789 return Error::success();
1792 Error ASTNodeImporter::ImportDefinition(
1812 Error Result = ImportDeclContext(From, /*ForceImport=*/true);
1819 return Error::success();
1829 if (Error Err = setTypedefNameForAnonDecl(From, To, Importer))
1862 if (Error Err =
1888 if (Error Err = ImportDeclContext(From, /*ForceImport=*/true))
1891 return Error::success();
1894 Error ASTNodeImporter::ImportInitializer(VarDecl *From, VarDecl *To) {
1896 return Error::success();
1900 return Error::success();
1914 return Error::success();
1917 Error ASTNodeImporter::ImportDefinition(
1922 return Error::success();
1927 if (Error Err = setTypedefNameForAnonDecl(From, To, Importer))
1940 if (Error Err = ImportDeclContext(From, /*ForceImport=*/true))
1948 return Error::success();
1951 Error ASTNodeImporter::ImportTemplateArguments(
1961 return Error::success();
1971 Error ASTNodeImporter::ImportTemplateArgumentListInfo(
1979 return Error::success();
2097 if (Error Err = ImportDeclContext(D, DC, LexicalDC))
2183 if (Error Err = ImportDeclParts(D, DC, LexicalDC, Name, ToD, Loc))
2250 if (Error Err = ImportDeclContext(D))
2262 if (Error Err = ImportDeclParts(D, DC, LexicalDC, Name, LookupD, Loc))
2301 if (Error Err = ImportDeclParts(D, DC, LexicalDC, Name, ToD, Loc))
2396 if (Error Err = ImportDeclParts(D, DC, LexicalDC, Name, FoundD, Loc))
2452 if (Error Err = ImportDeclParts(D, DC, LexicalDC, Name, ToD, Loc))
2491 if (Error Err = ImportDeclParts(D, DC, LexicalDC, Name, ToD, Loc))
2500 if (Error Err = importInto(
2566 if (Error Err = ImportDefinition(D, D2))
2586 if (Error Err = ImportDeclParts(D, DC, LexicalDC, Name, ToD, Loc))
2595 if (Error Err = importInto(
2655 if (Error Err = ImportImplicitMethods(DCXX, FoundCXX))
2730 if (Error Err = importInto(ToDescribed, FromDescribed))
2803 if (Error Err = ImportDefinition(D, D2, IDK_Default))
2815 if (Error Err = ImportDeclParts(D, DC, LexicalDC, Name, ToD, Loc))
2867 Error ASTNodeImporter::ImportTemplateParameterLists(const DeclaratorDecl *FromD,
2871 return Error::success();
2880 return Error::success();
2883 Error ASTNodeImporter::ImportTemplateInformation(
2888 return Error::success();
2905 return Error::success();
2921 if (Error Err = ImportTemplateArgumentListInfo(
2929 if (Error Err = ImportTemplateParameterLists(FromFD, ToFD))
2936 return Error::success();
2953 if (Error Err = ImportTemplateArgumentListInfo(
2962 return Error::success();
2983 Error ASTNodeImporter::ImportFunctionDeclBody(FunctionDecl *FromFD,
2991 return Error::success();
3012 if (Error Err = ImportDeclParts(D, DC, LexicalDC, Name, ToD, Loc))
3113 if (Error Err = ImportDeclarationNameLoc(D->getNameInfo(), NameInfo))
3286 if (Error Err = ImportContainerChecked(
3299 Error Err = ImportFunctionDeclBody(D, ToFunction);
3308 if (Error Err = ImportTemplateInformation(D, ToFunction))
3330 if (Error Err = ImportOverriddenMethods(cast<CXXMethodDecl>(ToFunction),
3366 if (Error Err = ImportDeclParts(D, DC, LexicalDC, Name, ToD, Loc))
3451 if (Error Err = ImportDeclParts(D, DC, LexicalDC, Name, ToD, Loc))
3518 if (Error Err = ImportDeclContext(D, DC, LexicalDC))
3545 if (Error Err = importInto(ToFriendD, FriendD))
3594 if (Error Err = ImportDeclParts(D, DC, LexicalDC, Name, ToD, Loc))
3659 if (Error Err = ImportDeclParts(D, DC, LexicalDC, Name, ToD, Loc))
3769 if (Error Err = ImportInitializer(D, ToVar))
3812 Error ASTNodeImporter::ImportDefaultArgOfParmVarDecl(
3831 return Error::success();
3863 if (Error Err = ImportDefaultArgOfParmVarDecl(D, ToParm))
3883 if (Error Err = ImportDeclParts(D, DC, LexicalDC, Name, ToD, Loc))
3992 if (Error Err = ImportContainerChecked(FromSelLocs, ToSelLocs))
4008 if (Error Err = ImportDeclParts(D, DC, LexicalDC, Name, ToD, Loc))
4040 if (Error Err = ImportDeclParts(D, DC, LexicalDC, Name, ToD, Loc))
4046 if (Error Err = importInto(ToInterface, D->getClassInterface()))
4112 if (Error Err = ImportDeclContext(D))
4127 Error ASTNodeImporter::ImportDefinition(
4131 if (Error Err = ImportDeclContext(From))
4133 return Error::success();
4166 if (Error Err = ImportDeclContext(From, /*ForceImport=*/true))
4169 return Error::success();
4189 if (Error Err = ImportDeclParts(D, DC, LexicalDC, Name, ToD, Loc))
4222 if (Error Err = ImportDefinition(D, ToProto))
4230 if (Error Err = ImportDeclContext(D, DC, LexicalDC))
4267 if (Error Err = ImportDeclParts(D, DC, LexicalDC, Name, ToD, Loc))
4281 if (Error Err = ImportDeclarationNameLoc(D->getNameInfo(), NameInfo))
4318 if (Error Err = ImportDeclParts(D, DC, LexicalDC, Name, ToD, Loc))
4360 if (Error Err = ImportDeclParts(D, DC, LexicalDC, Name, ToD, Loc))
4403 if (Error Err = ImportDeclParts(D, DC, LexicalDC, Name, ToD, Loc))
4418 if (Error Err = ImportDeclarationNameLoc(D->getNameInfo(), NameInfo))
4440 if (Error Err = ImportDeclParts(D, DC, LexicalDC, Name, ToD, Loc))
4468 Error ASTNodeImporter::ImportDefinition(
4502 if (Error Err = ImportDeclContext(From))
4504 return Error::success();
4563 if (Error Err = ImportDeclContext(From, /*ForceImport=*/true))
4566 return Error::success();
4613 if (Error Err = ImportDeclParts(D, DC, LexicalDC, Name, ToD, Loc))
4655 if (Error Err = ImportDefinition(D, ToIface))
4664 if (Error Err = importInto(Category, D->getCategoryDecl()))
4670 if (Error Err = ImportDeclContext(D, DC, LexicalDC))
4692 if (Error Err = ImportDeclContext(D))
4702 if (Error Err = importInto(Iface, D->getClassInterface()))
4707 if (Error Err = importInto(Super, D->getSuperClass()))
4715 if (Error Err = ImportDeclContext(D, DC, LexicalDC))
4777 if (Error Err = ImportDeclContext(D))
4789 if (Error Err = ImportDeclParts(D, DC, LexicalDC, Name, ToD, Loc))
4869 if (Error Err = importInto(Property, D->getPropertyDecl()))
4873 if (Error Err = ImportDeclContext(D, DC, LexicalDC))
4880 if (Error Err = importInto(Ivar, D->getPropertyIvarDecl()))
5043 if (Error Err = ImportDeclParts(D, DC, LexicalDC, Name, ToD, Loc))
5093 if (Error Err = importInto(ToTemplated, FromTemplated))
5154 if (Error Err = importInto(ClassTemplate, D->getSpecializedTemplate()))
5159 if (Error Err = ImportDeclContext(D, DC, LexicalDC))
5164 if (Error Err = ImportTemplateArguments(
5226 if (Error Err = ImportTemplateArgumentListInfo(ASTTemplateArgs, ToTAInfo))
5230 if (Error Err = importInto(
5311 if (Error Err = ImportDefinition(D, D2))
5337 if (Error Err = ImportDeclParts(D, DC, LexicalDC, Name, ToD, Loc))
5383 if (Error Err = importInto(ToTemplated, DTemplated))
5424 if (Error Err = importInto(VarTemplate, D->getSpecializedTemplate()))
5429 if (Error Err = ImportDeclContext(D, DC, LexicalDC))
5443 if (Error Err = ImportTemplateArguments(
5469 if (Error Err = importInto(T, D->getType()))
5477 if (Error Err = ImportTemplateArgumentListInfo(
5488 if (Error Err = ImportTemplateArgumentListInfo(
5551 if (Error Err = ImportInitializer(D, D2))
5564 if (Error Err = ImportDeclParts(D, DC, LexicalDC, Name, ToD, Loc))
5604 if (Error Err = importInto(TemplatedFD, D->getTemplatedDecl()))
5690 if (Error Err = ImportContainerChecked(S->outputs(), Exprs))
5693 if (Error Err =
5697 if (Error Err = ImportArrayChecked(
5751 if (Error Err = ImportContainerChecked(S->body(), ToStmts))
5820 if (Error Err = ImportContainerChecked(FromAttrs, ToAttrs))
6275 if (Error Err =
6317 if (Error Err = ImportContainerChecked(E->designators(), ToDesignators))
6400 if (Error Err = ImportArrayChecked(
6438 if (Error Err = ImportArrayChecked(
6495 if (Error Err = ImportContainerChecked(E->exprs(), ToExprs))
6928 if (Error Err = ImportDefaultArgOfParmVarDecl(*FromParam, ToParam))
6982 if (Error Err = ImportContainerChecked(E->arguments(), ToArgs))
7043 if (Error Err = ImportTemplateArguments(
7076 if (Error Err =
7120 if (Error Err = ImportContainerChecked(E->arguments(), ToArgs))
7137 if (Error Err = ImportContainerChecked(E->getObjects(), ToObjects))
7157 if (Error Err = ImportContainerChecked(E->arguments(), ToArgs))
7223 if (Error Err =
7298 if (Error Err = ImportTemplateArgumentListInfo(
7311 if (Error Err = ImportDeclarationNameLoc(
7337 if (Error Err = ImportDeclarationNameLoc(E->getNameInfo(), ToNameInfo))
7343 if (Error Err =
7366 if (Error Err =
7391 if (Error Err = ImportDeclarationNameLoc(E->getNameInfo(), ToNameInfo))
7403 if (Error Err = ImportTemplateArgumentListInfo(
7442 if (Error Err = ImportDeclarationNameLoc(E->getNameInfo(), ToNameInfo))
7455 if (Error Err =
7487 if (Error Err = ImportContainerChecked(E->arguments(), ToArgs))
7523 if (Error Err = ImportContainerChecked(E->capture_inits(), ToCaptureInits))
7553 if (Error Err = ImportContainerChecked(E->inits(), ToExprs))
7728 if (Error Err = ImportContainerChecked(E->getArgs(), ToArgs))
7765 Error ASTNodeImporter::ImportOverriddenMethods(CXXMethodDecl *ToMethod,
7767 Error ImportErrors = Error::success();
7767 Error ImportErrors = Error::success();
8074 if (Error Err = ASTNodeImporter(*this).ImportDefinition(
8085 if (Error Err = ASTNodeImporter(*this).ImportDefinition(
8096 if (Error Err = ASTNodeImporter(*this).ImportDefinition(
8107 if (Error Err = ASTNodeImporter(*this).ImportDefinition(
8164 if (Error Err = importInto(Prefix, FromNNS->getPrefix()))
8231 if (Error Err = importInto(Spec, NNS.getNestedNameSpecifier()))
8238 if (Error Err = importInto(ToLocalBeginLoc, NNS.getLocalBeginLoc()))
8242 if (Error Err = importInto(ToLocalEndLoc, NNS.getLocalEndLoc()))
8265 if (Error Err = importInto(ToTLoc, NNS.getTypeLoc().getBeginLoc()))
8404 if (Error Err = importInto(ToBegin, FromRange.getBegin()))
8406 if (Error Err = importInto(ToEnd, FromRange.getEnd()))
8516 if (Error Err = importInto(EllipsisLoc, From->getEllipsisLoc()))
8582 Error ASTImporter::ImportDefinition(Decl *From) {
tools/clang/lib/AST/ExternalASTMerger.cpp 318 if (llvm::Error Err = Forward.ImportDefinition(SourceTag))
338 if (llvm::Error Err = Forward.ImportDefinition(SourceInterface))
tools/clang/lib/AST/Interp/ByteCodeEmitter.cpp 19 using Error = llvm::Error;
tools/clang/lib/CodeGen/BackendUtil.cpp 1426 if (Error E = Conf.addSaveTemps(CGOpts.SaveTempsFilePrefix + ".",
1483 if (Error E = thinBackend(
tools/clang/lib/CodeGen/CodeGenAction.cpp 277 if (Error E = OptRecordFileOrErr.takeError()) {
tools/clang/lib/CodeGen/CodeGenModule.cpp 159 if (auto E = ReaderOrErr.takeError()) {
tools/clang/lib/CodeGen/CodeGenPGO.cpp 971 if (auto E = RecordExpected.takeError()) {
tools/clang/lib/CrossTU/CrossTranslationUnit.cpp 415 if (llvm::Error IndexLoadError =
446 if (llvm::Error IndexLoadError = ensureCTUIndexLoaded(CrossTUDir, IndexName))
451 llvm::Error CrossTranslationUnitContext::ASTUnitStorage::ensureCTUIndexLoaded(
455 return llvm::Error::success();
467 return llvm::Error::success();
tools/clang/lib/Format/ContinuationIndenter.cpp 1598 auto PrefixErr = Whitespaces.addReplacement(tooling::Replacement(
1610 auto SuffixErr = Whitespaces.addReplacement(tooling::Replacement(
1621 auto Err = Whitespaces.addReplacement(tooling::Replacement(
tools/clang/lib/Format/Format.cpp 621 inline llvm::Error make_string_error(const llvm::Twine &Message) {
1285 auto Err = Result.add(tooling::Replacement(
1643 auto Err =
1962 auto Err = Replaces.add(tooling::Replacement(
2131 auto Err = Replaces.add(tooling::Replacement(FileName, Imports.front().Offset,
2321 auto Err = Result.add(R);
2343 auto Err = Result.add(*Replace);
tools/clang/lib/Format/NamespaceEndCommentsFixer.cpp 132 auto Err = Fixes->add(tooling::Replacement(SourceMgr, Range, EndCommentText));
146 auto Err = Fixes->add(tooling::Replacement(SourceMgr, Range, EndCommentText));
tools/clang/lib/Format/SortJavaScriptImports.cpp 192 auto Err = Result.add(tooling::Replacement(
tools/clang/lib/Format/TokenAnalyzer.cpp 102 auto Err = Result.add(R);
tools/clang/lib/Format/UsingDeclarationsSorter.cpp 145 auto Err = Fixes->add(tooling::Replacement(SourceMgr, Range, ""));
169 auto Err = Fixes->add(tooling::Replacement(SourceMgr, Range, Text));
tools/clang/lib/Format/WhitespaceManager.cpp 69 llvm::Error
780 auto Err = Replaces.add(tooling::Replacement(
tools/clang/lib/Format/WhitespaceManager.h 61 llvm::Error addReplacement(const tooling::Replacement &Replacement);
tools/clang/lib/Frontend/ASTUnit.cpp 1210 if (llvm::Error Err = Act->Execute()) {
1638 if (llvm::Error Err = Act->Execute()) {
2289 if (llvm::Error Err = Act->Execute()) {
2308 if (llvm::Error Err = llvm::writeFileAtomically(
2313 : llvm::Error::success();
tools/clang/lib/Frontend/CompilerInstance.cpp 964 if (llvm::Error Err = Act.Execute()) {
2073 if (llvm::Error Err = GlobalModuleIndex::writeIndex(
2107 if (llvm::Error Err = GlobalModuleIndex::writeIndex(
tools/clang/lib/Frontend/CompilerInvocation.cpp 651 if (auto E = ReaderOrErr.takeError()) {
tools/clang/lib/Frontend/FrontendAction.cpp 928 llvm::Error FrontendAction::Execute() {
944 if (llvm::Error Err = GlobalModuleIndex::writeIndex(
954 return llvm::Error::success();
tools/clang/lib/Frontend/PrecompiledPreamble.cpp 355 if (llvm::Error Err = Act->Execute())
tools/clang/lib/Frontend/Rewrite/FrontendActions.cpp 133 if (llvm::Error Err = FixAction->Execute()) {
tools/clang/lib/Frontend/SerializedDiagnosticReader.cpp 98 if (llvm::Error Err = Stream.SkipBlock()) {
146 if (llvm::Error Err = Stream.ReadAbbrevRecord())
163 if (llvm::Error Err =
182 if (llvm::Error Err = Stream.SkipBlock()) {
212 if (llvm::Error Err =
236 } else if (llvm::Error Err = Stream.SkipBlock()) {
tools/clang/lib/Serialization/ASTReader.cpp 1151 if (llvm::Error Err = Cursor.JumpToBit(Offset)) {
1201 if (llvm::Error Err = Cursor.JumpToBit(Offset)) {
1256 void ASTReader::Error(llvm::Error &&Err) const {
1323 if (llvm::Error Err = F.Stream.SkipBlock()) {
1329 if (llvm::Error Err =
1451 if (llvm::Error E =
1467 if (llvm::Error Err = F->SLocEntryCursor.JumpToBit(
1626 if (llvm::Error Err = Cursor.EnterSubBlock(BlockID)) {
1644 if (llvm::Error Err = Cursor.JumpToBit(Offset)) {
1651 if (llvm::Error Err = Cursor.ReadAbbrevRecord()) {
1679 if (llvm::Error Err = Stream.JumpToBit(Offset)) {
1949 if (llvm::Error Err = Cursor.JumpToBit(I.MacroStartOffset)) {
2097 if (llvm::Error Err = Cursor.JumpToBit(PMInfo.MacroDirectivesOffset)) {
2219 if (llvm::Error Err = Cursor.JumpToBit(F.InputFileOffsets[ID - 1])) {
2287 if (llvm::Error Err = Cursor.JumpToBit(F.InputFileOffsets[ID - 1])) {
2475 if (llvm::Error Err = Stream.EnterSubBlock(OPTIONS_BLOCK_ID)) {
2566 if (llvm::Error Err = Stream.EnterSubBlock(CONTROL_BLOCK_ID)) {
2662 if (llvm::Error Err = Stream.SkipBlock()) {
2702 } else if (llvm::Error Err = Stream.SkipBlock()) {
2709 if (llvm::Error Err = Stream.SkipBlock()) {
2926 if (llvm::Error Err = Stream.EnterSubBlock(AST_BLOCK_ID)) {
2966 if (llvm::Error Err = Stream.SkipBlock()) {
2981 if (llvm::Error Err = Stream.SkipBlock()) {
2995 if (llvm::Error Err = Stream.SkipBlock()) {
3027 if (llvm::Error Err = Stream.SkipBlock()) {
3040 if (llvm::Error Err = Stream.SkipBlock()) {
4082 std::pair<GlobalModuleIndex *, llvm::Error> Result =
4084 if (llvm::Error Err = std::move(Result.second)) {
4142 if (llvm::Error Err = Cursor.EnterSubBlock(BlockID)) {
4151 if (llvm::Error Err = Cursor.SkipBlock()) {
4398 static llvm::Error doesntStartWithASTFileMagic(BitstreamCursor &Stream) {
4413 return llvm::Error::success();
4500 if (llvm::Error Err = doesntStartWithASTFileMagic(Stream)) {
4575 if (llvm::Error Err = Stream.SkipBlock()) {
4646 if (llvm::Error Err = doesntStartWithASTFileMagic(Stream)) {
4749 if (llvm::Error Err = Stream.SkipBlock()) {
4944 if (llvm::Error Err = doesntStartWithASTFileMagic(Stream)) {
5001 if (llvm::Error Err = doesntStartWithASTFileMagic(Stream)) {
5114 if (llvm::Error Err = doesntStartWithASTFileMagic(Stream)) {
5154 if (llvm::Error Err = Stream.SkipBlock()) {
5165 if (llvm::Error Err = Stream.SkipBlock()) {
5234 if (llvm::Error Err = Cursor.JumpToBit(InputFileOffs[I])) {
5309 if (llvm::Error Err = Stream.SkipBlock()) {
5377 if (llvm::Error Err = F.Stream.EnterSubBlock(SUBMODULE_BLOCK_ID)) {
5892 if (llvm::Error Err =
6331 if (llvm::Error Err = DeclsCursor.JumpToBit(Loc.Offset)) {
7659 if (llvm::Error Err = Cursor.JumpToBit(Loc.Offset)) {
7694 if (llvm::Error Err = Cursor.JumpToBit(Loc.Offset)) {
7922 if (llvm::Error Err = Loc.F->DeclsCursor.JumpToBit(Loc.Offset)) {
tools/clang/lib/Serialization/ASTReaderDecl.cpp 3628 if (llvm::Error JumpFailed = DeclsCursor.JumpToBit(Loc.Offset))
3986 if (llvm::Error JumpFailed = Cursor.JumpToBit(Offset))
4068 if (llvm::Error JumpFailed = Cursor.JumpToBit(LocalOffset))
tools/clang/lib/Serialization/ASTWriter.cpp 2251 llvm::Error E = llvm::zlib::compress(Blob.drop_back(1), CompressedBuffer);
tools/clang/lib/Serialization/GlobalModuleIndex.cpp 170 if (llvm::Error Err = Cursor.EnterSubBlock(GLOBAL_INDEX_BLOCK_ID))
173 } else if (llvm::Error Err = Cursor.SkipBlock())
251 std::pair<GlobalModuleIndex *, llvm::Error>
280 llvm::Error::success());
459 llvm::Error loadModuleFile(const FileEntry *File);
530 llvm::Error GlobalModuleIndexBuilder::loadModuleFile(const FileEntry *File) {
582 if (llvm::Error Err = InStream.EnterSubBlock(CONTROL_BLOCK_ID))
591 if (llvm::Error Err = InStream.EnterSubBlock(AST_BLOCK_ID))
600 if (llvm::Error Err = InStream.EnterSubBlock(UNHASHED_CONTROL_BLOCK_ID))
608 if (llvm::Error Err = InStream.SkipBlock())
713 return llvm::Error::success();
851 llvm::Error
903 if (llvm::Error Err = Builder.loadModuleFile(*ModuleFile))
tools/clang/lib/Tooling/AllTUsExecution.cpp 21 llvm::Error make_string_error(const llvm::Twine &Message) {
77 llvm::Error AllTUsToolExecutor::execute(
148 return llvm::Error::success();
tools/clang/lib/Tooling/CommonOptionsParser.cpp 83 llvm::Error CommonOptionsParser::init(
128 return llvm::Error::success();
154 return llvm::Error::success();
161 llvm::Error Err =
171 llvm::Error Err = init(argc, argv, Category, OccurrencesFlag, Overview);
tools/clang/lib/Tooling/Core/Replacement.cpp 245 llvm::Error Replacements::add(const Replacement &R) {
254 return llvm::Error::success();
285 return llvm::Error::success();
295 return llvm::Error::success();
302 return llvm::Error::success();
341 return llvm::Error::success();
tools/clang/lib/Tooling/DependencyScanning/DependencyScanningTool.cpp 63 auto Result =
tools/clang/lib/Tooling/DependencyScanning/DependencyScanningWorker.cpp 169 static llvm::Error runWithDiags(
179 return llvm::Error::success();
184 llvm::Error DependencyScanningWorker::computeDependencies(
tools/clang/lib/Tooling/Execution.cpp 42 llvm::Error
47 llvm::Error ToolExecutor::execute(std::unique_ptr<FrontendActionFactory> Action,
tools/clang/lib/Tooling/Inclusions/HeaderIncludes.cpp 356 llvm::Error Err = Result.add(tooling::Replacement(
tools/clang/lib/Tooling/Refactoring/AtomicChange.cpp 137 inline llvm::Error make_string_error(const llvm::Twine &Message) {
159 llvm::Error Err = HeaderReplacements.add(
167 llvm::Error Err =
188 if (auto Err = Replaces.add(Replacement(
243 llvm::Error Err = E.Replaces.add(R);
252 llvm::Error AtomicChange::replace(const SourceManager &SM,
258 llvm::Error AtomicChange::replace(const SourceManager &SM, SourceLocation Loc,
263 llvm::Error AtomicChange::insert(const SourceManager &SM, SourceLocation Loc,
266 return llvm::Error::success();
268 llvm::Error Err = Replaces.add(R);
280 return llvm::Error::success();
283 return llvm::Error::success();
313 llvm::Error Err = AllReplaces.add(R);
tools/clang/lib/Tooling/Refactoring/Extract/Extract.cpp 170 auto Err = Change.insert(SM, ExtractedDeclLocation, OS.str());
186 auto Err = Change.replace(
tools/clang/lib/Tooling/Refactoring/Rename/RenamingAction.cpp 155 auto Error =
173 llvm::Error Err = (*FileToReplaces)[Replace.getFilePath()].add(Replace);
tools/clang/lib/Tooling/Refactoring/Rename/USRLocFinder.cpp 523 llvm::Error Err = ReplaceChange.replace(
tools/clang/lib/Tooling/RefactoringCallbacks.cpp 52 llvm::Error Err =
91 auto Err = Replace.add(tooling::Replacement(
111 auto Err = Replace.add(
131 auto Err =
142 auto Err =
231 llvm::Error Err = Replace.add(Replacement);
tools/clang/lib/Tooling/StandaloneExecution.cpp 15 static llvm::Error make_string_error(const llvm::Twine &Message) {
52 llvm::Error StandaloneToolExecutor::execute(
69 return llvm::Error::success();
tools/clang/lib/Tooling/Transformer/RangeSelector.cpp 33 static Error invalidArgumentError(Twine Message) {
37 static Error typeError(StringRef ID, const ASTNodeKind &Kind) {
42 static Error typeError(StringRef ID, const ASTNodeKind &Kind,
49 static Error missingPropertyError(StringRef ID, Twine Description,
tools/clang/lib/Tooling/Transformer/Stencil.cpp 147 Error evalData(const RawTextData &Data, const MatchFinder::MatchResult &,
150 return Error::success();
153 Error evalData(const DebugPrintNodeData &Data,
158 if (auto Err = NodeOrErr.takeError())
162 return Error::success();
165 Error evalData(const UnaryOperationData &Data,
188 return Error::success();
191 Error evalData(const SelectorData &Data, const MatchFinder::MatchResult &Match,
197 return Error::success();
200 Error evalData(const AccessData &Data, const MatchFinder::MatchResult &Match,
220 Error evalData(const IfBoundData &Data, const MatchFinder::MatchResult &Match,
227 Error evalData(const MatchConsumer<std::string> &Fn,
233 return Error::success();
244 Error eval(const MatchFinder::MatchResult &Match,
270 if (auto Err = Part.eval(Match, &Result))
tools/clang/lib/Tooling/Transformer/Transformer.cpp 53 if (auto Err = AC.replace(*Result.SourceManager, T.Range, T.Replacement)) {
tools/clang/tools/clang-import-test/clang-import-test.cpp 284 llvm::Error ParseSource(const std::string &Path, CompilerInstance &CI,
294 return llvm::Error::success();
327 if (llvm::Error PE = ParseSource(Path, CI.getCompilerInstance(), Consumers))
357 if (auto E = ImportCI.takeError()) {
376 if (auto E = ExpressionCI.takeError()) {
tools/clang/tools/clang-offload-bundler/ClangOffloadBundler.cpp 130 virtual Error ReadHeader(MemoryBuffer &Input) = 0;
139 virtual Error ReadBundleEnd(MemoryBuffer &Input) = 0;
142 virtual Error ReadBundle(raw_fd_ostream &OS, MemoryBuffer &Input) = 0;
146 virtual Error WriteHeader(raw_fd_ostream &OS,
151 virtual Error WriteBundleStart(raw_fd_ostream &OS,
156 virtual Error WriteBundleEnd(raw_fd_ostream &OS, StringRef TargetTriple) = 0;
159 virtual Error WriteBundle(raw_fd_ostream &OS, MemoryBuffer &Input) = 0;
231 Error ReadHeader(MemoryBuffer &Input) final {
240 return Error::success();
245 return Error::success();
249 return Error::success();
259 return Error::success();
266 return Error::success();
273 return Error::success();
280 return Error::success();
287 return Error::success();
296 return Error::success();
306 Error ReadBundleEnd(MemoryBuffer &Input) final {
308 return Error::success();
311 Error ReadBundle(raw_fd_ostream &OS, MemoryBuffer &Input) final {
316 return Error::success();
319 Error WriteHeader(raw_fd_ostream &OS,
350 return Error::success();
353 Error WriteBundleStart(raw_fd_ostream &OS, StringRef TargetTriple) final {
354 return Error::success();
357 Error WriteBundleEnd(raw_fd_ostream &OS, StringRef TargetTriple) final {
358 return Error::success();
361 Error WriteBundle(raw_fd_ostream &OS, MemoryBuffer &Input) final {
363 return Error::success();
413 Error ReadHeader(MemoryBuffer &Input) final { return Error::success(); }
413 Error ReadHeader(MemoryBuffer &Input) final { return Error::success(); }
432 Error ReadBundleEnd(MemoryBuffer &Input) final { return Error::success(); }
432 Error ReadBundleEnd(MemoryBuffer &Input) final { return Error::success(); }
434 Error ReadBundle(raw_fd_ostream &OS, MemoryBuffer &Input) final {
440 return Error::success();
443 Error WriteHeader(raw_fd_ostream &OS,
449 return Error::success();
452 Error WriteBundleStart(raw_fd_ostream &OS, StringRef TargetTriple) final {
454 return Error::success();
457 Error WriteBundleEnd(raw_fd_ostream &OS, StringRef TargetTriple) final {
464 return Error::success();
503 return Error::success();
506 Error WriteBundle(raw_fd_ostream &OS, MemoryBuffer &Input) final {
507 return Error::success();
534 Error ReadHeader(MemoryBuffer &Input) final { return Error::success(); }
534 Error ReadHeader(MemoryBuffer &Input) final { return Error::success(); }
558 Error ReadBundleEnd(MemoryBuffer &Input) final {
569 return Error::success();
572 Error ReadBundle(raw_fd_ostream &OS, MemoryBuffer &Input) final {
582 return Error::success();
585 Error WriteHeader(raw_fd_ostream &OS,
587 return Error::success();
590 Error WriteBundleStart(raw_fd_ostream &OS, StringRef TargetTriple) final {
592 return Error::success();
595 Error WriteBundleEnd(raw_fd_ostream &OS, StringRef TargetTriple) final {
597 return Error::success();
600 Error WriteBundle(raw_fd_ostream &OS, MemoryBuffer &Input) final {
602 return Error::success();
665 static Error BundleFiles() {
695 if (Error Err = FH->WriteHeader(OutputFile, InputBuffers))
702 if (Error Err = FH->WriteBundleStart(OutputFile, Triple))
704 if (Error Err = FH->WriteBundle(OutputFile, **Input))
706 if (Error Err = FH->WriteBundleEnd(OutputFile, Triple))
710 return Error::success();
714 static Error UnbundleFiles() {
733 if (Error Err = FH->ReadHeader(Input))
770 if (Error Err = FH->ReadBundle(OutputFile, Input))
772 if (Error Err = FH->ReadBundleEnd(Input))
794 return Error::success();
811 return Error::success();
926 if (llvm::Error Err = Unbundle ? UnbundleFiles() : BundleFiles()) {
tools/clang/tools/clang-refactor/ClangRefactor.cpp 318 void handleError(llvm::Error Err) override {
372 llvm::Error Init() {
383 return llvm::Error::success();
619 if (auto Err = RefactorTool.Init()) {
tools/clang/tools/clang-refactor/TestSupport.cpp 128 void handleError(llvm::Error Err) override { handleResult(std::move(Err)); }
tools/clang/tools/extra/clang-apply-replacements/lib/Tooling/ApplyReplacements.cpp 203 llvm::Error Err =
tools/clang/tools/extra/clang-change-namespace/ChangeNamespace.cpp 150 auto Err = Replaces->add(R);
187 auto Err = (*FileToReplacements)[R.getFilePath()].add(R);
tools/clang/tools/extra/clang-doc/BitcodeReader.cpp 20 llvm::Error decodeRecord(Record R, llvm::SmallVectorImpl<char> &Field,
23 return llvm::Error::success();
26 llvm::Error decodeRecord(Record R, SymbolID &Field, llvm::StringRef Blob) {
35 return llvm::Error::success();
38 llvm::Error decodeRecord(Record R, bool &Field, llvm::StringRef Blob) {
40 return llvm::Error::success();
43 llvm::Error decodeRecord(Record R, int &Field, llvm::StringRef Blob) {
48 return llvm::Error::success();
51 llvm::Error decodeRecord(Record R, AccessSpecifier &Field,
59 return llvm::Error::success();
66 llvm::Error decodeRecord(Record R, TagTypeKind &Field, llvm::StringRef Blob) {
74 return llvm::Error::success();
81 llvm::Error decodeRecord(Record R, llvm::Optional<Location> &Field,
87 return llvm::Error::success();
90 llvm::Error decodeRecord(Record R, InfoType &Field, llvm::StringRef Blob) {
98 return llvm::Error::success();
104 llvm::Error decodeRecord(Record R, FieldId &Field, llvm::StringRef Blob) {
114 return llvm::Error::success();
120 llvm::Error decodeRecord(Record R,
124 return llvm::Error::success();
127 llvm::Error decodeRecord(Record R, llvm::SmallVectorImpl<Location> &Field,
133 return llvm::Error::success();
136 llvm::Error parseRecord(Record R, unsigned ID, llvm::StringRef Blob,
139 return llvm::Error::success();
144 llvm::Error parseRecord(Record R, unsigned ID, llvm::StringRef Blob,
159 llvm::Error parseRecord(Record R, unsigned ID, llvm::StringRef Blob,
182 llvm::Error parseRecord(Record R, unsigned ID, llvm::StringRef Blob,
205 llvm::Error parseRecord(Record R, unsigned ID, llvm::StringRef Blob,
226 llvm::Error parseRecord(Record R, unsigned ID, llvm::StringRef Blob,
247 llvm::Error parseRecord(Record R, unsigned ID, llvm::StringRef Blob,
249 return llvm::Error::success();
252 llvm::Error parseRecord(Record R, unsigned ID, llvm::StringRef Blob,
263 llvm::Error parseRecord(Record R, unsigned ID, llvm::StringRef Blob,
276 llvm::Error parseRecord(Record R, unsigned ID, llvm::StringRef Blob,
307 llvm::Error parseRecord(Record R, unsigned ID, llvm::StringRef Blob,
364 llvm::Error addTypeInfo(T I, TTypeInfo &&TI) {
369 template <> llvm::Error addTypeInfo(RecordInfo *I, MemberTypeInfo &&T) {
371 return llvm::Error::success();
374 template <> llvm::Error addTypeInfo(BaseRecordInfo *I, MemberTypeInfo &&T) {
376 return llvm::Error::success();
379 template <> llvm::Error addTypeInfo(FunctionInfo *I, TypeInfo &&T) {
381 return llvm::Error::success();
384 template <> llvm::Error addTypeInfo(FunctionInfo *I, FieldTypeInfo &&T) {
386 return llvm::Error::success();
389 template <typename T> llvm::Error addReference(T I, Reference &&R, FieldId F) {
394 template <> llvm::Error addReference(TypeInfo *I, Reference &&R, FieldId F) {
398 return llvm::Error::success();
406 llvm::Error addReference(FieldTypeInfo *I, Reference &&R, FieldId F) {
410 return llvm::Error::success();
418 llvm::Error addReference(MemberTypeInfo *I, Reference &&R, FieldId F) {
422 return llvm::Error::success();
429 template <> llvm::Error addReference(EnumInfo *I, Reference &&R, FieldId F) {
433 return llvm::Error::success();
441 llvm::Error addReference(NamespaceInfo *I, Reference &&R, FieldId F) {
445 return llvm::Error::success();
448 return llvm::Error::success();
451 return llvm::Error::success();
459 llvm::Error addReference(FunctionInfo *I, Reference &&R, FieldId F) {
463 return llvm::Error::success();
466 return llvm::Error::success();
473 template <> llvm::Error addReference(RecordInfo *I, Reference &&R, FieldId F) {
477 return llvm::Error::success();
480 return llvm::Error::success();
483 return llvm::Error::success();
486 return llvm::Error::success();
525 llvm::Error ClangDocBitcodeReader::readRecord(unsigned ID, T I) {
535 llvm::Error ClangDocBitcodeReader::readRecord(unsigned ID, Reference *I) {
546 llvm::Error ClangDocBitcodeReader::readBlock(unsigned ID, T I) {
547 if (llvm::Error Err = Stream.EnterSubBlock(ID))
559 return llvm::Error::success();
561 if (llvm::Error Err = readSubBlock(BlockOrCode, I)) {
562 if (llvm::Error Skipped = Stream.SkipBlock())
570 if (auto Err = readRecord(BlockOrCode, I))
576 llvm::Error ClangDocBitcodeReader::readSubBlock(unsigned ID, T I) {
584 if (auto Err = readBlock(ID, Comment.get()))
586 return llvm::Error::success();
590 if (auto Err = readBlock(ID, &TI))
592 if (auto Err = addTypeInfo(I, std::move(TI)))
594 return llvm::Error::success();
598 if (auto Err = readBlock(ID, &TI))
600 if (auto Err = addTypeInfo(I, std::move(TI)))
602 return llvm::Error::success();
606 if (auto Err = readBlock(ID, &TI))
608 if (auto Err = addTypeInfo(I, std::move(TI)))
610 return llvm::Error::success();
614 if (auto Err = readBlock(ID, &R))
616 if (auto Err = addReference(I, std::move(R), CurrentReferenceField))
618 return llvm::Error::success();
622 if (auto Err = readBlock(ID, &F))
625 return llvm::Error::success();
629 if (auto Err = readBlock(ID, &BR))
632 return llvm::Error::success();
636 if (auto Err = readBlock(ID, &E))
639 return llvm::Error::success();
678 if (llvm::Error Err = Stream.ReadAbbrevRecord()) {
692 llvm::Error ClangDocBitcodeReader::validateStream() {
706 return llvm::Error::success();
709 llvm::Error ClangDocBitcodeReader::readBlockInfoBlock() {
720 return llvm::Error::success();
727 if (auto Err = readBlock(ID, static_cast<T *>(I.get())))
753 if (auto Err = validateStream())
788 if (auto Err = readBlock(ID, VersionNumber))
792 if (auto Err = readBlockInfoBlock())
796 if (llvm::Error Err = Stream.SkipBlock()) {
tools/clang/tools/extra/clang-doc/BitcodeReader.h 41 llvm::Error validateStream();
42 llvm::Error readVersion();
43 llvm::Error readBlockInfoBlock();
47 template <typename T> llvm::Error readBlock(unsigned ID, T I);
50 template <typename T> llvm::Error readSubBlock(unsigned ID, T I);
54 template <typename T> llvm::Error readRecord(unsigned ID, T I);
tools/clang/tools/extra/clang-doc/Generators.cpp 60 llvm::Error Generator::createResources(ClangDocContext &CDCtx) {
61 return llvm::Error::success();
tools/clang/tools/extra/clang-doc/Generators.h 29 virtual llvm::Error generateDocForInfo(Info *I, llvm::raw_ostream &OS,
35 virtual llvm::Error createResources(ClangDocContext &CDCtx);
tools/clang/tools/extra/clang-doc/HTMLGenerator.cpp 830 llvm::Error generateDocForInfo(Info *I, llvm::raw_ostream &OS,
832 llvm::Error createResources(ClangDocContext &CDCtx) override;
837 llvm::Error HTMLGenerator::generateDocForInfo(Info *I, llvm::raw_ostream &OS,
867 return llvm::Error::success();
886 static llvm::Error SerializeIndex(ClangDocContext &CDCtx) {
915 return llvm::Error::success();
936 static llvm::Error GenIndex(const ClangDocContext &CDCtx) {
963 return llvm::Error::success();
966 static llvm::Error CopyFile(StringRef FilePath, StringRef OutDirectory) {
980 return llvm::Error::success();
983 llvm::Error HTMLGenerator::createResources(ClangDocContext &CDCtx) {
984 auto Err = SerializeIndex(CDCtx);
1001 return llvm::Error::success();
tools/clang/tools/extra/clang-doc/MDGenerator.cpp 253 llvm::Error generateDocForInfo(Info *I, llvm::raw_ostream &OS,
259 llvm::Error MDGenerator::generateDocForInfo(Info *I, llvm::raw_ostream &OS,
278 return llvm::Error::success();
tools/clang/tools/extra/clang-doc/YAMLGenerator.cpp 269 llvm::Error generateDocForInfo(Info *I, llvm::raw_ostream &OS,
275 llvm::Error YAMLGenerator::generateDocForInfo(Info *I, llvm::raw_ostream &OS,
295 return llvm::Error::success();
tools/clang/tools/extra/clang-doc/tool/ClangDocMain.cpp 241 auto Err =
318 if (auto Err = G->get()->generateDocForInfo(I, InfoOS, CDCtx))
tools/clang/tools/extra/clang-include-fixer/IncludeFixer.cpp 411 auto Err =
428 auto Err = Replaces.add(R);
tools/clang/tools/extra/clang-move/Move.cpp 754 auto Err = Context->FileToReplacements[FilePath].add(RemoveReplacement);
771 auto Err = FileAndReplacements.second.add(
tools/clang/tools/extra/clang-tidy/ClangTidy.cpp 146 llvm::Error Err = Replacements.add(R);
tools/clang/tools/extra/clang-tidy/ClangTidyDiagnosticConsumer.cpp 86 llvm::Error Err =
tools/clang/tools/extra/clangd/ClangdLSPServer.cpp 109 llvm::Error validateEdits(const DraftStore &DraftMgr, const Tweak::Effect &E) {
124 return llvm::Error::success();
232 auto Err = Result.takeError();
363 llvm::Error Err = Reply.takeError();
707 if (auto Err = validateEdits(DraftMgr, *R))
1243 if (auto Err = Transp.loop(*MsgHandler)) {
tools/clang/tools/extra/clangd/ClangdServer.cpp 412 if (llvm::Error Err = reformatEdit(E, Style))
tools/clang/tools/extra/clangd/CodeComplete.cpp 1117 if (llvm::Error Err = Action.Execute()) {
tools/clang/tools/extra/clangd/JSONTransport.cpp 17 llvm::json::Object encodeError(llvm::Error E) {
20 if (llvm::Error Unhandled = llvm::handleErrors(
24 return llvm::Error::success();
34 llvm::Error decodeError(const llvm::json::Object &O) {
82 llvm::Error loop(MessageHandler &Handler) override {
91 return llvm::Error::success(); // we saw the "exit" notification.
tools/clang/tools/extra/clangd/Logger.h 40 template <typename T> T &&wrap(T &&V) { return std::forward<T>(V); }
40 template <typename T> T &&wrap(T &&V) { return std::forward<T>(V); }
41 inline decltype(fmt_consume(llvm::Error::success())) wrap(llvm::Error &&V) {
41 inline decltype(fmt_consume(llvm::Error::success())) wrap(llvm::Error &&V) {
45 void log(Logger::Level L, const char *Fmt, Ts &&... Vals) {
46 detail::log(L, llvm::formatv(Fmt, detail::wrap(std::forward<Ts>(Vals))...));
56 template <typename... Ts> void elog(const char *Fmt, Ts &&... Vals) {
57 detail::log(Logger::Error, Fmt, std::forward<Ts>(Vals)...);
62 template <typename... Ts> void log(const char *Fmt, Ts &&... Vals) {
63 detail::log(Logger::Info, Fmt, std::forward<Ts>(Vals)...);
67 template <typename... Ts> void vlog(const char *Fmt, Ts &&... Vals) {
68 detail::log(Logger::Verbose, Fmt, std::forward<Ts>(Vals)...);
tools/clang/tools/extra/clangd/ParsedAST.cpp 366 if (llvm::Error Err = Action->Execute())
tools/clang/tools/extra/clangd/RIFF.cpp 16 static llvm::Error makeError(const char *Msg) {
tools/clang/tools/extra/clangd/SourceCode.cpp 1050 llvm::Error reformatEdit(Edit &E, const format::FormatStyle &Style) {
1055 return llvm::Error::success();
tools/clang/tools/extra/clangd/SourceCode.h 229 llvm::Error reformatEdit(Edit &E, const format::FormatStyle &Style);
tools/clang/tools/extra/clangd/Transport.h 61 virtual llvm::Error loop(MessageHandler &) = 0;
tools/clang/tools/extra/clangd/URI.cpp 24 inline llvm::Error make_string_error(const llvm::Twine &Message) {
tools/clang/tools/extra/clangd/index/Background.cpp 199 if (auto Error = index(std::move(Cmd)))
318 if (auto Error = IndexStorage->storeShard(Path, Shard))
343 llvm::Error BackgroundIndex::index(tooling::CompileCommand Cmd) {
414 if (llvm::Error Err = Action->Execute())
440 return llvm::Error::success();
tools/clang/tools/extra/clangd/index/Background.h 45 virtual llvm::Error storeShard(llvm::StringRef ShardIdentifier,
170 llvm::Error index(tooling::CompileCommand);
tools/clang/tools/extra/clangd/index/BackgroundIndexStorage.cpp 74 llvm::Error storeShard(llvm::StringRef ShardIdentifier,
80 return llvm::Error::success();
94 llvm::Error storeShard(llvm::StringRef ShardIdentifier,
98 return llvm::Error::success();
tools/clang/tools/extra/clangd/index/Serialization.cpp 28 llvm::Error makeError(const llvm::Twine &Msg) {
209 if (llvm::Error E = llvm::zlib::uncompress(R.rest(), UncompressedStorage,
tools/clang/tools/extra/clangd/indexer/IndexerMain.cpp 121 auto Err = Executor->get()->execute(
tools/clang/tools/extra/clangd/refactor/Rename.cpp 119 llvm::Error makeError(ReasonToReject Reason) {
193 if (auto Err = FilteredChanges.add(tooling::Replacement(
tools/clang/tools/extra/clangd/refactor/tweaks/AnnotateHighlightings.cpp 71 if (auto Err = Result.add(InsertReplacement))
tools/clang/tools/extra/clangd/refactor/tweaks/DefineInline.cpp 197 if (auto Err = Replacements.add(
374 if (auto Err = Edits.front().second.Replacements.add(DeleteFuncBody))
tools/clang/tools/extra/clangd/refactor/tweaks/ExpandAutoType.cpp 50 llvm::Error createErrorMessage(const std::string& Message,
109 llvm::Error ExpandAutoType::createErrorMessage(const std::string& Message,
tools/clang/tools/extra/clangd/refactor/tweaks/ExtractFunction.cpp 664 if (auto Err = Result.add(createFunctionDefinition(*ExtractedFunc, SM)))
666 if (auto Err = Result.add(replaceWithFuncCall(*ExtractedFunc, SM, LangOpts)))
tools/clang/tools/extra/clangd/refactor/tweaks/ExtractVariable.cpp 466 if (auto Err = Result.add(Target->insertDeclaration(VarName, Range)))
469 if (auto Err = Result.add(Target->replaceWithVar(Range, VarName)))
tools/clang/tools/extra/clangd/refactor/tweaks/RemoveUsingNamespace.cpp 188 if (auto Err = R.add(*RemoveUsing))
194 if (auto Err = R.add(tooling::Replacement(Ctx.getSourceManager(), Loc,
tools/clang/tools/extra/clangd/refactor/tweaks/SwapIfBranches.cpp 85 if (auto Err = Result.add(tooling::Replacement(Ctx.getSourceManager(),
89 if (auto Err = Result.add(tooling::Replacement(Ctx.getSourceManager(),
tools/clang/tools/extra/clangd/unittests/BackgroundIndexTests.cpp 56 llvm::Error storeShard(llvm::StringRef ShardIdentifier,
61 return llvm::Error::success();
tools/clang/tools/extra/clangd/unittests/FormatTests.cpp 32 if (llvm::Error E = Merged.add(R))
tools/clang/tools/extra/clangd/unittests/JSONTransportTests.cpp 108 auto Err = T->loop(E);
149 auto Err = T->loop(E);
194 auto Err = T->loop(E);
tools/clang/tools/extra/clangd/unittests/TUSchedulerTests.cpp 325 if (auto Err = E.takeError()) {
tools/clang/tools/extra/tool-template/ToolTemplate.cpp 113 auto Err = Executor->get()->execute(newFrontendActionFactory(&Finder));
tools/clang/tools/extra/unittests/clang-doc/HTMLGeneratorTest.cpp 61 auto Err = G->generateDocForInfo(&I, Actual, CDCtx);
172 auto Err = G->generateDocForInfo(&I, Actual, CDCtx);
289 auto Err = G->generateDocForInfo(&I, Actual, CDCtx);
336 auto Err = G->generateDocForInfo(&I, Actual, CDCtx);
421 auto Err = G->generateDocForInfo(&I, Actual, CDCtx);
tools/clang/tools/extra/unittests/clang-doc/MDGeneratorTest.cpp 42 auto Err = G->generateDocForInfo(&I, Actual, ClangDocContext());
105 auto Err = G->generateDocForInfo(&I, Actual, ClangDocContext());
168 auto Err = G->generateDocForInfo(&I, Actual, ClangDocContext());
196 auto Err = G->generateDocForInfo(&I, Actual, ClangDocContext());
327 auto Err = G->generateDocForInfo(&I, Actual, ClangDocContext());
tools/clang/tools/extra/unittests/clang-doc/YAMLGeneratorTest.cpp 45 auto Err = G->generateDocForInfo(&I, Actual, ClangDocContext());
109 auto Err = G->generateDocForInfo(&I, Actual, ClangDocContext());
195 auto Err = G->generateDocForInfo(&I, Actual, ClangDocContext());
243 auto Err = G->generateDocForInfo(&I, Actual, ClangDocContext());
381 auto Err = G->generateDocForInfo(&I, Actual, ClangDocContext());
tools/clang/tools/extra/unittests/clang-tidy/ClangTidyTest.h 146 auto Err = Fixes.add(Fix);
tools/clang/unittests/AST/ASTImporterFixtures.h 215 auto Err = llvm::handleErrors(
tools/clang/unittests/Basic/DiagnosticTest.cpp 83 llvm::Error Err = Value.takeError();
tools/clang/unittests/Tooling/ExecutionTest.cpp 100 llvm::Error
103 return llvm::Error::success();
190 auto Err = Executor.execute(newFrontendActionFactory<SyntaxOnlyAction>(),
201 auto Err = Executor.execute(std::unique_ptr<FrontendActionFactory>(
214 auto Err = Executor.execute(std::unique_ptr<FrontendActionFactory>(
259 auto Err = Executor.execute(std::unique_ptr<FrontendActionFactory>(
287 auto Err = Executor.execute(std::unique_ptr<FrontendActionFactory>(
tools/clang/unittests/Tooling/RefactoringActionRulesTest.cpp 40 void handleError(llvm::Error Err) override { Result = std::move(Err); }
78 llvm::Error E = Change.replace(SM, Loc, 1, "b");
181 void handleError(llvm::Error) override {}
tools/clang/unittests/Tooling/RefactoringCallbacksTest.cpp 127 llvm::Error E) {
tools/clang/unittests/Tooling/RefactoringTest.cpp 105 static bool checkReplacementError(llvm::Error &&Error,
146 auto Err = Replaces.add(Deletion);
175 auto Err = Replaces.add(R);
190 auto Err = Replaces.add(Replacement("x.cc", 0, 3, "345"));
210 auto Err = Replaces.add(Replacement("x.cc", 10, 3, "replace"));
232 auto Err = Replaces.add(ContainingReplacement);
254 auto Err = Replaces.add(Replacement("x.cc", 0, 2, ""));
281 auto Err = Replaces.add(Insertion);
301 auto Err = Replaces.add(Replacement("x.cc", 0, 2, ""));
322 auto Err = Replaces.add(First);
343 auto Err = Replaces.add(Replacement("x.cc", 0, 10, "1"));
365 auto Err = Replaces.add(Replacement("x.cc", 10, 2, ""));
385 auto Err = Replaces.add(Replacement("x.cc", 10, 0, "a"));
421 auto Err = Replaces.add(Replacement("x.cc", 10, 5, "a"));
473 auto Err = Replaces.add(Replacement(
495 auto Err = Replaces.add(ConflictReplacement);
1111 llvm::Error Err =
1163 llvm::Error Err = ExpectedChange.insert(Context.Sources, DefaultLoc, "aa",
1199 llvm::Error Err = Change.replace(Context.Sources, DefaultLoc, 2, "aa");
1215 llvm::Error Err = Change.replace(
1225 llvm::Error Err = Change.insert(Context.Sources, DefaultLoc, "aa");
1239 llvm::Error Err = Change.insert(Context.Sources, DefaultLoc, "aa");
1253 llvm::Error Err =
1269 llvm::Error Err =
1286 llvm::Error Err = Change.insert(Context.Sources, DefaultLoc, "a");
1321 llvm::Error Err =
1373 auto Err = Changes.back().replace(
1628 auto Err = Changes.back().replace(Context.Sources, getLoc(9), 3, "");
1655 auto Err = Changes.back().replace(Context.Sources, getLoc(7), 5, "");
1679 auto Err = Changes.back().replace(Context.Sources, getLoc(7), 5, "");
1707 auto Err = Changes.back().replace(Context.Sources, getLoc(4), 1, "");
tools/clang/unittests/Tooling/ReplacementTest.h 30 auto Err = Result.add(R);
tools/clang/unittests/Tooling/RewriterTest.cpp 41 auto Err = Replaces.add(Replacement("<file>", 6, 6, ""));
tools/clang/unittests/Tooling/StencilTest.cpp 102 auto Err = llvm::handleErrors(ResultOrErr.takeError(),
tools/dsymutil/BinaryHolder.cpp 44 Error BinaryHolder::ArchiveEntry::load(StringRef Filename,
83 return Error::success();
86 Error BinaryHolder::ObjectEntry::load(StringRef Filename, bool Verbose) {
121 return Error::success();
168 Error Err = Error::success();
168 Error Err = Error::success();
226 auto Err = AE.load(Filename, Timestamp, Verbose);
243 auto Err = OE.load(Filename, Verbose);
tools/dsymutil/BinaryHolder.h 57 Error load(StringRef Filename, bool Verbose = false);
108 Error load(StringRef Filename, TimestampTy Timestamp, bool Verbose = false);
tools/dsymutil/DebugMap.cpp 245 auto Err = ObjectEntry.takeError();
251 auto Err = Object.takeError();
tools/dsymutil/DwarfLinker.cpp 1724 if (Error E = RangeList.extract(RangeExtractor, &Offset)) {
1830 Error Err = LineTable.parse(LineExtractor, &StmtOffset, OrigDwarf,
2205 if (Error E = loadClangModule(CUDie, PCMfile, Name, DwoId, ModuleMap, DMO,
2220 auto Err = ObjectEntry.takeError();
2228 auto Err = Object.takeError();
2237 Error DwarfLinker::loadClangModule(
2287 return Error::success();
2344 return Error::success();
2355 return Error::success();
2505 static Error copySwiftInterfaces(
2539 return Error::success();
2851 if (auto E =
tools/dsymutil/DwarfLinker.h 209 Error loadClangModule(DWARFDie CUDie, StringRef FilePath,
tools/dsymutil/MachODebugMapParser.cpp 163 auto Err = ObjectEntry.takeError();
171 auto Err = Object.takeError();
352 auto Err = ObjectEntry.takeError();
360 auto Err = Objects.takeError();
tools/dsymutil/MachOUtils.cpp 29 llvm::Error ArchAndFile::createTempFile() {
39 return Error::success();
46 if (auto E = File->discard())
81 if (auto E = ArchFiles.front().File->keep(OutputFileName)) {
350 auto Err = ObjectEntry.takeError();
359 auto Err = Object.takeError();
tools/dsymutil/MachOUtils.h 30 llvm::Error createTempFile();
tools/dsymutil/dsymutil.cpp 150 static Error verifyOptions(const DsymutilOptions &Options) {
185 return Error::success();
269 if (Error E = verifyOptions(Options))
274 static Error createPlistFile(StringRef Bin, StringRef BundleRoot,
335 return Error::success();
338 static Error createBundleDir(StringRef BundleBase) {
346 return Error::success();
422 if (auto E = createBundleDir(Path))
424 if (auto E = createPlistFile(DwarfFile, Path, Options.Toolchain))
571 auto E = TempFiles.back().createTempFile();
tools/gold/gold-plugin.cpp 479 static void check(Error E, std::string Msg = "LLVM gold plugin") {
482 return Error::success();
tools/llc/llc.cpp 339 if (Error E = RemarksFileOrErr.takeError()) {
tools/lld/COFF/DebugTypes.cpp 250 Error err = pdb::NativeSession::createFromPdb(
tools/lld/COFF/Driver.cpp 786 if (Error e = writeImportLibrary(libName, tmpName, exports, config->machine,
tools/lld/COFF/DriverUtils.cpp 394 if (auto e = merger.merge(*defaultXmlCopy.get()))
401 if (auto e = merger.merge(*manifest.get()))
714 if (auto ec = parser.parse(rf, duplicates))
723 if (auto ec = rsf.load(f->getCOFFObj()))
726 if (auto ec = parser.parse(rsf, f->getName(), duplicates))
tools/lld/COFF/InputFiles.cpp 124 Error err = Error::success();
124 Error err = Error::success();
tools/lld/COFF/PDB.cpp 133 Error mergeInPrecompHeaderObj(ObjFile *file, CVIndexMap *objectIndexMap);
330 if (auto e = hash.takeError())
380 Error e = mergeInPrecompHeaderObj(file, objectIndexMap);
404 if (auto err = mergeTypeAndIdRecords(
410 if (auto err = mergeTypeAndIdRecords(tMerger.iDTable, tMerger.typeTable,
436 if (auto e = expectedTpi.takeError())
441 if (auto e = expectedIpi.takeError())
455 if (auto err =
464 if (auto err =
471 if (auto err = mergeTypeRecords(tMerger.typeTable, indexMap.tpiMap,
477 if (auto err = mergeIdRecords(tMerger.iDTable, indexMap.tpiMap,
486 Error PDBLinker::mergeInPrecompHeaderObj(ObjFile *file,
499 return Error::success();
507 return Error::success();
835 auto ec = forEachCodeViewRecord<CVSymbol>(
841 return Error::success();
886 return Error::success();
932 return Error::success();
tools/lld/COFF/Writer.cpp 630 if (auto e = buffer->commit())
tools/lld/Common/ErrorHandler.cpp 85 void lld::checkError(Error e) {
tools/lld/ELF/Driver.cpp 163 Error err = Error::success();
163 Error err = Error::success();
tools/lld/ELF/InputSection.cpp 153 if (Error e = zlib::uncompress(toStringRef(rawData), uncompressedBuf, size))
1124 if (Error e = zlib::uncompress(toStringRef(rawData),
tools/lld/ELF/OutputSections.cpp 275 if (Error e = zlib::compress(toStringRef(buf), compressedData))
tools/lld/ELF/SyntheticSections.cpp 2565 if (Error e = cu->tryExtractDIEsIfNeeded(false)) {
tools/lld/ELF/Writer.cpp 619 if (auto e = buffer->commit())
tools/lld/include/lld/Common/ErrorHandler.h 126 void checkError(Error e);
tools/lld/include/lld/Core/LinkingContext.h 202 virtual llvm::Error writeFile(const File &linkedFile) const;
216 virtual llvm::Error handleLoadedFile(File &file) = 0;
tools/lld/include/lld/Core/Pass.h 33 virtual llvm::Error perform(SimpleFile &mergedFile) = 0;
tools/lld/include/lld/Core/PassManager.h 34 llvm::Error runOnFile(SimpleFile &file) {
36 if (llvm::Error EC = pass->perform(file))
38 return llvm::Error::success();
tools/lld/include/lld/Core/Resolver.h 50 llvm::Error handleSharedLibrary(File &);
tools/lld/include/lld/Core/Writer.h 30 virtual llvm::Error writeFile(const File &linkedFile, StringRef path) = 0;
tools/lld/include/lld/ReaderWriter/MachOLinkingContext.h 413 llvm::Error handleLoadedFile(File &file) override;
tools/lld/lib/Core/LinkingContext.cpp 26 llvm::Error LinkingContext::writeFile(const File &linkedFile) const {
tools/lld/lib/Core/Resolver.cpp 33 if (auto ec = _ctx.handleLoadedFile(file))
65 if (auto ec = undefAddedOrError.takeError())
86 llvm::Error Resolver::handleSharedLibrary(File &file) {
90 if (auto ec = undefAddedOrError.takeError())
100 if (auto ec = undefAddedOrError.takeError())
102 return llvm::Error::success();
252 if (auto EC = undefAddedOrError.takeError()) {
266 if (auto EC = undefAddedOrError.takeError()) {
279 if (auto EC = handleSharedLibrary(*file)) {
tools/lld/lib/Driver/DarwinLdDriver.cpp 252 static llvm::Error loadFileList(StringRef fileListPath,
291 return llvm::Error::success();
1098 if (auto ec = loadFileList(arg->getValue(), ctx, globalWholeArchive)) {
1196 if (auto ec = pm.runOnFile(*merged)) {
1210 if (auto ec = ctx.writeFile(*merged)) {
tools/lld/lib/ReaderWriter/FileArchive.cpp 84 llvm::Error err = llvm::Error::success();
84 llvm::Error err = llvm::Error::success();
127 llvm::Error Err = llvm::Error::success();
127 llvm::Error Err = llvm::Error::success();
tools/lld/lib/ReaderWriter/MachO/ArchHandler.h 123 typedef std::function<llvm::Error (uint32_t sectionIndex, uint64_t addr,
129 typedef std::function<llvm::Error (uint32_t symbolIndex,
136 virtual llvm::Error
151 virtual llvm::Error
tools/lld/lib/ReaderWriter/MachO/ArchHandler_arm.cpp 82 llvm::Error getReferenceInfo(const normalized::Relocation &reloc,
91 llvm::Error
524 llvm::Error ArchHandler_arm::getReferenceInfo(
541 if (auto ec = atomFromSymbolIndex(reloc.symbol, target))
546 return llvm::Error::success();
564 if (auto ec = atomFromAddress(0, reloc.value, target, addend))
569 return llvm::Error::success();
577 if (auto ec = atomFromSymbolIndex(reloc.symbol, target))
582 return llvm::Error::success();
602 if (auto ec = atomFromAddress(0, reloc.value, target, addend))
607 return llvm::Error::success();
611 if (auto ec = atomFromSymbolIndex(reloc.symbol, target))
614 return llvm::Error::success();
618 if (auto ec = atomFromAddress(reloc.symbol, instruction, target, addend))
621 return llvm::Error::success();
625 if (auto ec = atomFromAddress(0, reloc.value, target, addend))
628 return llvm::Error::success();
632 return llvm::Error::success();
635 llvm::Error
803 if (auto ec = atomFromAddr(0, toAddress, target, &offsetInTo))
805 if (auto ec = atomFromAddr(0, fromAddress, &fromTarget, &offsetInFrom))
816 if (auto ec = atomFromAddr(0, toAddress, target, &offsetInTo))
818 if (auto ec = atomFromAddr(0, fromAddress, &fromTarget, &offsetInFrom))
853 return llvm::Error::success();
884 if (auto ec = atomFromSymbolIndex(reloc1.symbol, target))
895 if (auto ec = atomFromAddr(sectIndex, toAddress, target, &offsetInTo))
901 return llvm::Error::success();
tools/lld/lib/ReaderWriter/MachO/ArchHandler_arm64.cpp 137 llvm::Error getReferenceInfo(const normalized::Relocation &reloc,
146 llvm::Error
377 llvm::Error ArchHandler_arm64::getReferenceInfo(
388 if (auto ec = atomFromSymbolIndex(reloc.symbol, target))
391 return llvm::Error::success();
395 if (auto ec = atomFromSymbolIndex(reloc.symbol, target))
398 return llvm::Error::success();
402 if (auto ec = atomFromSymbolIndex(reloc.symbol, target))
405 return llvm::Error::success();
409 if (auto ec = atomFromSymbolIndex(reloc.symbol, target))
412 return llvm::Error::success();
416 if (auto ec = atomFromSymbolIndex(reloc.symbol, target))
419 return llvm::Error::success();
423 if (auto ec = atomFromSymbolIndex(reloc.symbol, target))
426 return llvm::Error::success();
430 if (auto ec = atomFromSymbolIndex(reloc.symbol, target))
433 return llvm::Error::success();
437 if (auto ec = atomFromSymbolIndex(reloc.symbol, target))
440 return llvm::Error::success();
449 if (auto ec = atomFromSymbolIndex(reloc.symbol, target))
452 return llvm::Error::success();
463 if (auto ec = atomFromSymbolIndex(reloc.symbol, target))
466 return llvm::Error::success();
472 llvm::Error ArchHandler_arm64::getPairReferenceInfo(
484 if (auto ec = atomFromSymbolIndex(reloc2.symbol, target))
487 return llvm::Error::success();
492 if (auto ec = atomFromSymbolIndex(reloc2.symbol, target))
495 return llvm::Error::success();
501 if (auto ec = atomFromSymbolIndex(reloc2.symbol, target))
504 return llvm::Error::success();
509 if (auto ec = atomFromSymbolIndex(reloc2.symbol, target))
524 return llvm::Error::success();
529 if (auto ec = atomFromSymbolIndex(reloc2.symbol, target))
532 return llvm::Error::success();
tools/lld/lib/ReaderWriter/MachO/ArchHandler_x86.cpp 88 llvm::Error getReferenceInfo(const normalized::Relocation &reloc,
97 llvm::Error
250 llvm::Error
267 if (auto ec = atomFromSymbolIndex(reloc.symbol, target))
283 if (auto ec = atomFromAddress(0, reloc.value, target, addend))
290 if (auto ec = atomFromSymbolIndex(reloc.symbol, target))
306 if (auto ec = atomFromAddress(0, reloc.value, target, addend))
317 if (auto ec = atomFromSymbolIndex(reloc.symbol, target))
337 if (auto ec = atomFromAddress(0, reloc.value, target, addend))
344 return llvm::Error::success();
347 llvm::Error
375 if (auto ec = atomFromAddr(0, toAddress, target, &offsetInTo))
377 if (auto ec = atomFromAddr(0, fromAddress, &fromTarget, &offsetInFrom))
402 return llvm::Error::success();
tools/lld/lib/ReaderWriter/MachO/ArchHandler_x86_64.cpp 145 llvm::Error getReferenceInfo(const normalized::Relocation &reloc,
154 llvm::Error
395 llvm::Error
413 if (auto ec = atomFromSymbolIndex(reloc.symbol, target))
416 return llvm::Error::success();
418 if (auto ec = atomFromSymbolIndex(reloc.symbol, target))
421 return llvm::Error::success();
423 if (auto ec = atomFromSymbolIndex(reloc.symbol, target))
426 return llvm::Error::success();
428 if (auto ec = atomFromSymbolIndex(reloc.symbol, target))
431 return llvm::Error::success();
447 if (auto ec = atomFromSymbolIndex(reloc.symbol, target))
450 return llvm::Error::success();
453 if (auto ec = atomFromSymbolIndex(reloc.symbol, target))
463 return llvm::Error::success();
472 llvm::Error
487 if (auto ec = atomFromSymbolIndex(reloc1.symbol, &fromTarget))
493 if (auto ec = atomFromSymbolIndex(reloc2.symbol, target))
508 return llvm::Error::success();
512 if (auto ec = atomFromSymbolIndex(reloc2.symbol, target))
524 return llvm::Error::success();
tools/lld/lib/ReaderWriter/MachO/CompactUnwindPass.cpp 283 llvm::Error perform(SimpleFile &mergedFile) override {
300 return llvm::Error::success();
357 return llvm::Error::success();
tools/lld/lib/ReaderWriter/MachO/File.h 244 if (auto ec = normFile.takeError())
247 if (auto ec = normalized::normalizedObjectToAtoms(this, **normFile, false))
334 if (auto ec = normFile.takeError())
337 if (auto ec = normalized::normalizedDylibToAtoms(this, **normFile, false))
tools/lld/lib/ReaderWriter/MachO/GOTPass.cpp 100 llvm::Error perform(SimpleFile &mergedFile) override {
136 return llvm::Error::success();
tools/lld/lib/ReaderWriter/MachO/LayoutPass.cpp 443 llvm::Error LayoutPass::perform(SimpleFile &mergedFile) {
477 return llvm::Error::success();
tools/lld/lib/ReaderWriter/MachO/LayoutPass.h 68 llvm::Error perform(SimpleFile &mergedFile) override;
tools/lld/lib/ReaderWriter/MachO/MachOLinkingContext.cpp 1025 llvm::Error MachOLinkingContext::handleLoadedFile(File &file) {
1028 return llvm::Error::success();
1095 return llvm::Error::success();
tools/lld/lib/ReaderWriter/MachO/MachONormalizedFile.h 288 llvm::Error writeBinary(const NormalizedFile &file, StringRef path);
301 llvm::Error
306 llvm::Error
tools/lld/lib/ReaderWriter/MachO/MachONormalizedFileBinaryReader.cpp 57 static llvm::Error forEachLoadCommand(
74 return llvm::Error::success();
79 return llvm::Error::success();
261 auto ec = forEachLoadCommand(lcRange, lcCount, isBig, is64,
513 Error Err = Error::success();
513 Error Err = Error::success();
tools/lld/lib/ReaderWriter/MachO/MachONormalizedFileBinaryWriter.cpp 122 llvm::Error writeBinary(StringRef path);
129 llvm::Error writeLoadCommands();
169 llvm::Error writeSingleSegmentLoadCommand(uint8_t *&lc);
170 template <typename T> llvm::Error writeSegmentLoadCommands(uint8_t *&lc);
622 llvm::Error MachOFileLayout::writeSingleSegmentLoadCommand(uint8_t *&lc) {
666 return llvm::Error::success();
670 llvm::Error MachOFileLayout::writeSegmentLoadCommands(uint8_t *&lc) {
736 return llvm::Error::success();
771 llvm::Error MachOFileLayout::writeLoadCommands() {
776 if (auto ec = writeSingleSegmentLoadCommand<MachO64Trait>(lc))
779 if (auto ec = writeSingleSegmentLoadCommand<MachO32Trait>(lc))
825 if (auto ec = writeSegmentLoadCommands<MachO64Trait>(lc))
828 if (auto ec = writeSegmentLoadCommands<MachO32Trait>(lc))
1017 return llvm::Error::success();
1526 llvm::Error MachOFileLayout::writeBinary(StringRef path) {
1536 if (Error E = fobOrErr.takeError())
1542 if (auto ec = writeLoadCommands())
1546 if (Error E = fob->commit())
1549 return llvm::Error::success();
1553 llvm::Error writeBinary(const NormalizedFile &file, StringRef path) {
tools/lld/lib/ReaderWriter/MachO/MachONormalizedFileFromAtoms.cpp 124 llvm::Error synthesizeDebugNotes(NormalizedFile &file);
125 llvm::Error addSymbols(const lld::File &atomFile, NormalizedFile &file);
169 llvm::Error getSymbolTableRegion(const DefinedAtom* atom,
795 llvm::Error Util::synthesizeDebugNotes(NormalizedFile &file) {
799 return llvm::Error::success();
944 return llvm::Error::success();
983 llvm::Error Util::getSymbolTableRegion(const DefinedAtom* atom,
991 return llvm::Error::success();
1003 return llvm::Error::success();
1009 return llvm::Error::success();
1015 return llvm::Error::success();
1019 return llvm::Error::success();
1024 return llvm::Error::success();
1033 llvm::Error Util::addSymbols(const lld::File &atomFile,
1062 if (auto ec = getSymbolTableRegion(atom, inGlobalsRegion, symbolScope)){
1145 return llvm::Error::success();
1637 if (auto err = util.synthesizeDebugNotes(normFile))
1641 if (auto ec = util.addSymbols(atomFile, normFile)) {
tools/lld/lib/ReaderWriter/MachO/MachONormalizedFileToAtoms.cpp 275 llvm::Error processSymboledSection(DefinedAtom::ContentType atomType,
326 return llvm::Error::success();
377 return llvm::Error::success();
380 llvm::Error processSection(DefinedAtom::ContentType atomType,
489 return llvm::Error::success();
521 llvm::Error convertRelocs(const Section §ion,
546 return llvm::Error::success();
582 return llvm::Error::success();
589 return llvm::Error::success();
622 auto relocErr = handler.getPairReferenceInfo(
658 auto relocErr = handler.getReferenceInfo(
686 return llvm::Error::success();
710 llvm::Error parseStabs(MachOFile &file,
715 return llvm::Error::success();
820 return llvm::Error::success();
938 llvm::Error parseDebugInfo(MachOFile &file,
961 return llvm::Error::success();
987 return llvm::Error::success();
1011 static llvm::Error processAugmentationString(const uint8_t *augStr,
1017 return llvm::Error::success();
1067 return llvm::Error::success();
1070 static llvm::Error processCIE(const NormalizedFile &normalizedFile,
1090 if (auto err = processAugmentationString(frameData + augmentationStringField,
1172 return llvm::Error::success();
1175 static llvm::Error processFDE(const NormalizedFile &normalizedFile,
1316 return llvm::Error::success();
1319 llvm::Error addEHFrameReferences(const NormalizedFile &normalizedFile,
1333 return llvm::Error::success();
1335 llvm::Error ehFrameErr = llvm::Error::success();
1335 llvm::Error ehFrameErr = llvm::Error::success();
1358 llvm::Error parseObjCImageInfo(const Section §,
1397 return llvm::Error::success();
1405 if (auto ec = normalizedObjectToAtoms(file.get(), normalizedFile, copyRefs))
1415 if (auto ec = normalizedDylibToAtoms(file.get(), normalizedFile, copyRefs))
1429 llvm::Error
1447 if (auto ec = parseObjCImageInfo(sect, normalizedFile, *file))
1457 if (auto ec = processSection(atomType, sect, customSectionName,
1479 if (llvm::Error ec = convertRelocs(sect, normalizedFile, scatterable,
1493 if (auto ec = addEHFrameReferences(normalizedFile, *file, *handler))
1553 if (auto err = parseDebugInfo(*file, normalizedFile, copyRefs))
1556 return llvm::Error::success();
1559 llvm::Error
1587 return llvm::Error::success();
tools/lld/lib/ReaderWriter/MachO/ObjCPass.cpp 104 llvm::Error perform(SimpleFile &mergedFile) override {
108 return llvm::Error::success();
tools/lld/lib/ReaderWriter/MachO/ShimPass.cpp 49 llvm::Error perform(SimpleFile &mergedFile) override {
68 return llvm::Error::success();
85 return llvm::Error::success();
tools/lld/lib/ReaderWriter/MachO/StubsPass.cpp 217 llvm::Error perform(SimpleFile &mergedFile) override {
220 return llvm::Error::success();
247 return llvm::Error::success();
324 return llvm::Error::success();
tools/lld/lib/ReaderWriter/MachO/TLVPass.cpp 74 llvm::Error perform(SimpleFile &mergedFile) override {
109 return llvm::Error::success();
tools/lld/lib/ReaderWriter/MachO/WriterMachO.cpp 30 llvm::Error writeFile(const lld::File &file, StringRef path) override {
34 if (auto ec = nFile.takeError())
40 if (auto ec = yamlWriter->writeFile(file, "-"))
tools/lld/lib/ReaderWriter/YAML/ReaderWriterYAML.cpp 1299 llvm::Error writeFile(const lld::File &file, StringRef outPath) override {
1316 return llvm::Error::success();
tools/lld/unittests/MachOTests/MachONormalizedFileBinaryReaderTests.cpp 750 llvm::Error ec2 = writeBinary(*f, tmpFl);
tools/lld/unittests/MachOTests/MachONormalizedFileBinaryWriterTests.cpp 150 llvm::Error ec2 = writeBinary(f, tmpFl);
263 llvm::Error ec2 = writeBinary(f, tmpFl);
382 llvm::Error ec2 = writeBinary(f, tmpFl);
539 llvm::Error ec2 = writeBinary(f, tmpFl);
tools/lld/wasm/Driver.cpp 196 Error err = Error::success();
196 Error err = Error::success();
tools/lld/wasm/Writer.cpp 1071 if (Error e = buffer->commit())
tools/lldb/include/lldb/Host/FileSystem.h 51 static llvm::Error Initialize(const FileSpec &mapping);
tools/lldb/include/lldb/Host/LZMA.h 27 llvm::Error uncompress(llvm::ArrayRef<uint8_t> InputBuffer,
tools/lldb/include/lldb/Host/ProcessLaunchInfo.h 55 llvm::Error SetUpPtyRedirection();
tools/lldb/include/lldb/Host/Socket.h 53 static llvm::Error Initialize();
tools/lldb/include/lldb/Initialization/SystemInitializer.h 23 virtual llvm::Error Initialize() = 0;
tools/lldb/include/lldb/Initialization/SystemInitializerCommon.h 28 llvm::Error Initialize() override;
tools/lldb/include/lldb/Initialization/SystemLifetimeManager.h 26 llvm::Error Initialize(std::unique_ptr<SystemInitializer> initializer,
tools/lldb/include/lldb/Target/Process.h 685 virtual llvm::Error LoadModules() {
tools/lldb/include/lldb/Utility/Log.h 146 void FormatError(llvm::Error error, llvm::StringRef file,
tools/lldb/include/lldb/Utility/RegularExpression.h 79 llvm::Error GetError() const;
tools/lldb/include/lldb/Utility/Reproducer.h 314 llvm::Error LoadIndex();
331 static llvm::Error Initialize(ReproducerMode mode,
350 llvm::Error SetCapture(llvm::Optional<FileSpec> root);
351 llvm::Error SetReplay(llvm::Optional<FileSpec> root);
tools/lldb/include/lldb/Utility/Status.h 72 explicit Status(llvm::Error error) { *this = std::move(error); }
73 const Status &operator=(llvm::Error error);
74 llvm::Error ToError() const;
tools/lldb/source/API/SBDebugger.cpp 160 if (auto e = g_debugger_lifetime->Initialize(
tools/lldb/source/API/SBModule.cpp 465 if (auto err = type_system_or_err.takeError()) {
483 if (auto err = type_system_or_err.takeError()) {
511 if (auto err = type_system_or_err.takeError()) {
tools/lldb/source/API/SBReproducer.cpp 110 if (auto e = Reproducer::Initialize(ReproducerMode::Capture, llvm::None)) {
119 if (auto e =
129 if (auto e = Reproducer::Initialize(ReproducerMode::Replay, FileSpec(path))) {
tools/lldb/source/API/SystemInitializerFull.cpp 168 llvm::Error SystemInitializerFull::Initialize() {
169 if (auto e = SystemInitializerCommon::Initialize())
295 return llvm::Error::success();
tools/lldb/source/API/SystemInitializerFull.h 26 llvm::Error Initialize() override;
tools/lldb/source/Breakpoint/Watchpoint.cpp 42 if (auto err = type_system_or_err.takeError()) {
tools/lldb/source/Commands/CommandObjectBreakpoint.cpp 640 if (llvm::Error err = regexp.GetError()) {
671 if (llvm::Error err = regexp.GetError()) {
tools/lldb/source/Commands/CommandObjectFrame.cpp 574 if (llvm::Error err = regex.GetError())
tools/lldb/source/Commands/CommandObjectReproducer.cpp 154 static void SetError(CommandReturnObject &result, Error err) {
239 if (Error err = loader->LoadIndex()) {
tools/lldb/source/Core/ValueObjectRegister.cpp 264 if (auto err = type_system_or_err.takeError()) {
tools/lldb/source/DataFormatters/VectorType.cpp 227 if (auto err = type_system_or_err.takeError()) {
tools/lldb/source/Expression/Materializer.cpp 867 if (auto error = type_system_or_err.takeError()) {
tools/lldb/source/Host/common/FileSystem.cpp 57 llvm::Error FileSystem::Initialize(const FileSpec &mapping) {
70 return llvm::Error::success();
tools/lldb/source/Host/common/LZMA.cpp 28 llvm::Error uncompress(llvm::ArrayRef<uint8_t> InputBuffer,
tools/lldb/source/Host/common/ProcessLaunchInfo.cpp 210 llvm::Error ProcessLaunchInfo::SetUpPtyRedirection() {
241 return llvm::Error::success();
tools/lldb/source/Host/common/Socket.cpp 84 llvm::Error Socket::Initialize() {
100 return llvm::Error::success();
tools/lldb/source/Initialization/SystemInitializerCommon.cpp 42 llvm::Error SystemInitializerCommon::Initialize() {
68 if (auto e = Reproducer::Initialize(ReproducerMode::Off, llvm::None))
76 if (llvm::Error e = FileSystem::Initialize(vfs_mapping))
104 llvm::Error error = Socket::Initialize();
120 return llvm::Error::success();
tools/lldb/source/Initialization/SystemLifetimeManager.cpp 26 llvm::Error SystemLifetimeManager::Initialize(
37 if (auto e = m_initializer->Initialize())
43 return llvm::Error::success();
tools/lldb/source/Interpreter/OptionValueRegex.cpp 53 } else if (llvm::Error err = m_regex.GetError()) {
tools/lldb/source/Plugins/DynamicLoader/POSIX-DYLD/DynamicLoaderPOSIXDYLD.cpp 97 auto error = m_process->LoadModules();
tools/lldb/source/Plugins/DynamicLoader/Windows-DYLD/DynamicLoaderWindowsDYLD.cpp 149 auto error = m_process->LoadModules();
169 auto error = m_process->LoadModules();
tools/lldb/source/Plugins/ExpressionParser/Clang/ClangASTSource.cpp 79 if (auto err = type_system_or_err.takeError()) {
tools/lldb/source/Plugins/Language/CPlusPlus/BlockPointer.cpp 45 if (auto err = type_system_or_err.takeError()) {
tools/lldb/source/Plugins/Language/ObjC/CoreMedia.cpp 33 if (auto err = type_system_or_err.takeError()) {
tools/lldb/source/Plugins/ObjectFile/ELF/ObjectFileELF.cpp 1884 auto err = lldb_private::lzma::uncompress(data.GetData(), uncompressedData);
3338 if (auto error = Decompressor->decompress(
tools/lldb/source/Plugins/Process/elf-core/ProcessElfCore.cpp 182 if (llvm::Error error = ParseThreadContextsFromNoteSegment(H, data))
443 static llvm::Error ParseNetBSDProcInfo(const DataExtractor &data,
484 return llvm::Error::success();
521 llvm::Error ProcessElfCore::parseFreeBSDNotes(llvm::ArrayRef<CoreNote> notes) {
567 return llvm::Error::success();
592 llvm::Error ProcessElfCore::parseNetBSDNotes(llvm::ArrayRef<CoreNote> notes) {
608 llvm::Error error = ParseNetBSDProcInfo(note.data, nlwps, signo,
723 return llvm::Error::success();
726 llvm::Error ProcessElfCore::parseOpenBSDNotes(llvm::ArrayRef<CoreNote> notes) {
755 return llvm::Error::success();
770 llvm::Error ProcessElfCore::parseLinuxNotes(llvm::ArrayRef<CoreNote> notes) {
851 return llvm::Error::success();
857 llvm::Error ProcessElfCore::ParseThreadContextsFromNoteSegment(
tools/lldb/source/Plugins/Process/elf-core/ProcessElfCore.h 149 llvm::Error ParseThreadContextsFromNoteSegment(
162 llvm::Error parseFreeBSDNotes(llvm::ArrayRef<lldb_private::CoreNote> notes);
163 llvm::Error parseNetBSDNotes(llvm::ArrayRef<lldb_private::CoreNote> notes);
164 llvm::Error parseOpenBSDNotes(llvm::ArrayRef<lldb_private::CoreNote> notes);
165 llvm::Error parseLinuxNotes(llvm::ArrayRef<lldb_private::CoreNote> notes);
tools/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunication.cpp 1250 llvm::Error
1256 if (llvm::Error error =
1276 if (llvm::Error error = accept_status.get().ToError())
1280 return llvm::Error::success();
tools/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunication.h 138 static llvm::Error ConnectLocally(GDBRemoteCommunication &client,
tools/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationReplayServer.cpp 179 llvm::Error
195 return Error::success();
tools/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationReplayServer.h 49 llvm::Error LoadReplayHistory(const FileSpec &path);
tools/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServer.cpp 115 GDBRemoteCommunicationServer::SendErrorResponse(llvm::Error error) {
tools/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServer.h 65 PacketResult SendErrorResponse(llvm::Error error);
tools/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServerLLGS.cpp 224 if (llvm::Error Err = m_process_launch_info.SetUpPtyRedirection())
tools/lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp 2327 auto error = LoadModules();
3397 if (auto error = m_gdb_replay_server.LoadReplayHistory(history_file))
3401 if (auto error = GDBRemoteCommunication::ConnectLocally(m_gdb_comm,
4815 llvm::Error ProcessGDBRemote::LoadModules() {
tools/lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.h 204 llvm::Error LoadModules() override;
tools/lldb/source/Plugins/ScriptInterpreter/Python/PythonDataObjects.cpp 710 Error PythonDictionary::SetItem(const PythonObject &key,
717 return Error::success();
720 Error PythonDictionary::SetItem(const Twine &key,
727 return Error::success();
732 Error error = SetItem(key, value);
1519 Error PythonScript::Init() {
1521 return Error::success();
1525 if (Error error = globals.SetItem("__builtins__", builtins))
1537 return Error::success();
tools/lldb/source/Plugins/ScriptInterpreter/Python/PythonDataObjects.h 178 inline llvm::Error nullDeref() {
183 inline llvm::Error exception(const char *s = nullptr) {
187 inline llvm::Error keyError() {
578 llvm::Error SetItem(const PythonObject &key, const PythonObject &value) const;
579 llvm::Error SetItem(const llvm::Twine &key, const PythonObject &value) const;
763 llvm::Error Init();
770 if (llvm::Error error = Init())
tools/lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.cpp 1199 llvm::Error error =
1201 llvm::Error error = llvm::createStringError(
tools/lldb/source/Plugins/StructuredData/DarwinLog/StructuredDataDarwinLog.cpp 291 if (llvm::Error err = regex.GetError()) {
tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFBaseDIE.cpp 116 if (auto err = type_system_or_err.takeError()) {
tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugAbbrev.cpp 24 llvm::Error
105 llvm::Error DWARFDebugAbbrev::parse(const DWARFDataExtractor &data) {
112 llvm::Error error = abbrevDeclSet.extract(data, &offset);
tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugAbbrev.h 40 llvm::Error extract(const lldb_private::DWARFDataExtractor &data,
73 llvm::Error parse(const lldb_private::DWARFDataExtractor &data);
tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugArangeSet.cpp 35 llvm::Error DWARFDebugArangeSet::extract(const DWARFDataExtractor &data,
tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugArangeSet.h 42 llvm::Error extract(const lldb_private::DWARFDataExtractor &data,
tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugAranges.cpp 34 llvm::Error
41 llvm::Error error = set.extract(debug_aranges_data, &offset);
tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugAranges.h 29 llvm::Error
tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugInfo.cpp 44 if (llvm::Error error = m_cu_aranges_up->extract(debug_aranges_data))
tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFUnit.h 232 llvm::Error ExtractHeader(SymbolFileDWARF &dwarf,
tools/lldb/source/Plugins/SymbolFile/DWARF/DebugNamesDWARFIndex.cpp 29 if (llvm::Error E = index_up->extract())
75 void DebugNamesDWARFIndex::MaybeLogLookupError(llvm::Error error,
tools/lldb/source/Plugins/SymbolFile/DWARF/DebugNamesDWARFIndex.h 72 static void MaybeLogLookupError(llvm::Error error,
tools/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp 613 llvm::Error error = abbr->parse(debug_abbrev_data);
801 if (auto err = type_system_or_err.takeError()) {
898 llvm::Error error = prologue.parse(data, &line_table_offset, ctx);
1988 if (auto err = type_system_or_err.takeError()) {
2866 if (auto err = type_system_or_err.takeError()) {
2972 if (auto err = type_system_or_err.takeError()) {
tools/lldb/source/Plugins/SymbolFile/NativePDB/PdbAstBuilder.cpp 323 llvm::Error visitKnownMember(CVMemberRecord &CVR,
344 llvm::Error error = visitMemberRecordStream(field_list.data(), process);
685 auto error =
tools/lldb/source/Plugins/SymbolFile/NativePDB/SymbolFileNativePDB.cpp 97 if (auto EC = File->parseFileHeaders()) {
101 if (auto EC = File->parseStreamData()) {
328 if (auto err = ts_or_err.takeError()) {
1082 if (auto EC = lines.initialize(reader)) {
tools/lldb/source/Plugins/SymbolFile/NativePDB/UdtRecordCompleter.cpp 26 using Error = llvm::Error;
100 return llvm::Error::success();
tools/lldb/source/Plugins/SymbolFile/PDB/SymbolFilePDB.cpp 139 auto error = loadDataForEXE(PDB_ReaderType::DIA, llvm::StringRef(exePath),
305 if (auto err = type_system_or_err.takeError()) {
559 if (auto err = type_system_or_err.takeError()) {
596 if (auto err = type_system_or_err.takeError()) {
618 if (auto err = type_system_or_err.takeError()) {
648 if (auto err = type_system_or_err.takeError()) {
678 if (auto err = type_system_or_err.takeError()) {
707 if (auto err = type_system_or_err.takeError()) {
1448 if (auto err = type_system_or_err.takeError()) {
1660 if (auto err = type_system_or_err.takeError()) {
1681 if (auto err = type_system_or_err.takeError()) {
1989 if (auto err = type_system_or_err.takeError()) {
tools/lldb/source/Plugins/SystemRuntime/MacOSX/AppleGetItemInfoHandler.cpp 175 if (auto err = type_system_or_err.takeError()) {
tools/lldb/source/Symbol/ClangASTImporter.cpp 958 if (llvm::Error err = ImportDefinition(from)) {
tools/lldb/source/Symbol/Type.cpp 524 if (auto err = type_system_or_err.takeError()) {
tools/lldb/source/Symbol/TypeSystem.cpp 223 llvm::Error error = llvm::Error::success();
223 llvm::Error error = llvm::Error::success();
292 llvm::Error error = llvm::Error::success();
292 llvm::Error error = llvm::Error::success();
tools/lldb/source/Target/StackFrame.cpp 1369 if (auto err = c_type_system_or_err.takeError()) {
tools/lldb/source/Target/Target.cpp 2175 if (auto err = type_system_or_err.takeError()) {
2192 if (auto err = type_system_or_err.takeError()) {
2215 if (auto err = type_system_or_err.takeError()) {
2239 if (auto err = type_system_or_err.takeError()) {
2262 if (auto err = type_system_or_err.takeError()) {
2366 if (auto err = type_system_or_err.takeError()) {
2424 llvm::Error error = llvm::Error::success();
2424 llvm::Error error = llvm::Error::success();
3147 llvm::Error Err = info.SetUpPtyRedirection();
tools/lldb/source/Target/ThreadPlanTracer.cpp 99 if (auto err = type_system_or_err.takeError()) {
tools/lldb/source/Utility/RegularExpression.cpp 35 llvm::Error RegularExpression::GetError() const {
40 return llvm::Error::success();
tools/lldb/source/Utility/Reproducer.cpp 23 llvm::Error Reproducer::Initialize(ReproducerMode mode,
51 return Error::success();
94 llvm::Error Reproducer::SetCapture(llvm::Optional<FileSpec> root) {
104 return Error::success();
108 return Error::success();
111 llvm::Error Reproducer::SetReplay(llvm::Optional<FileSpec> root) {
121 return Error::success();
125 if (auto e = m_loader->LoadIndex())
128 return Error::success();
204 llvm::Error Loader::LoadIndex() {
206 return llvm::Error::success();
225 return llvm::Error::success();
tools/lldb/source/Utility/Status.cpp 59 const Status &Status::operator=(llvm::Error error) {
72 return llvm::Error::success();
86 llvm::Error Status::ToError() const {
88 return llvm::Error::success();
tools/lldb/tools/lldb-server/SystemInitializerLLGS.cpp 46 llvm::Error SystemInitializerLLGS::Initialize() {
47 if (auto e = SystemInitializerCommon::Initialize())
62 return llvm::Error::success();
tools/lldb/tools/lldb-server/SystemInitializerLLGS.h 17 llvm::Error Initialize() override;
tools/lldb/tools/lldb-server/lldb-platform.cpp 109 if (auto Err =
tools/lldb/tools/lldb-server/lldb-server.cpp 42 if (auto e = g_debugger_lifetime->Initialize(
tools/lldb/tools/lldb-test/SystemInitializerTest.cpp 147 llvm::Error SystemInitializerTest::Initialize() {
148 if (auto e = SystemInitializerCommon::Initialize())
257 return llvm::Error::success();
tools/lldb/tools/lldb-test/SystemInitializerTest.h 26 llvm::Error Initialize() override;
tools/lldb/tools/lldb-test/lldb-test.cpp 188 static Error findFunctions(lldb_private::Module &Module);
189 static Error findBlocks(lldb_private::Module &Module);
190 static Error findNamespaces(lldb_private::Module &Module);
191 static Error findTypes(lldb_private::Module &Module);
192 static Error findVariables(lldb_private::Module &Module);
193 static Error dumpModule(lldb_private::Module &Module);
194 static Error dumpAST(lldb_private::Module &Module);
195 static Error dumpClangAST(lldb_private::Module &Module);
196 static Error verify(lldb_private::Module &Module);
198 static Expected<Error (*)(lldb_private::Module &)> getAction();
279 static Error make_string_error(const char *Format, Args &&... args) {
406 Error opts::symbols::findFunctions(lldb_private::Module &Module) {
456 return Error::success();
459 Error opts::symbols::findBlocks(lldb_private::Module &Module) {
493 return Error::success();
496 Error opts::symbols::findNamespaces(lldb_private::Module &Module) {
511 return Error::success();
514 Error opts::symbols::findTypes(lldb_private::Module &Module) {
538 return Error::success();
541 Error opts::symbols::findVariables(lldb_private::Module &Module) {
577 return Error::success();
580 Error opts::symbols::dumpModule(lldb_private::Module &Module) {
585 return Error::success();
588 Error opts::symbols::dumpAST(lldb_private::Module &Module) {
615 return Error::success();
618 Error opts::symbols::dumpClangAST(lldb_private::Module &Module) {
639 return Error::success();
642 Error opts::symbols::verify(lldb_private::Module &Module) {
689 return Error::success();
692 Expected<Error (*)(lldb_private::Module &)> opts::symbols::getAction() {
815 if (Error E = Action(*ModulePtr)) {
1072 if (auto e = DebuggerLifetime.Initialize(
tools/lldb/tools/lldb-vscode/lldb-vscode.cpp 2629 auto error = json_value.takeError();
tools/lldb/unittests/Process/gdb-remote/GDBRemoteCommunicationServerTest.cpp 42 auto error =
52 auto error = llvm::createStringError(llvm::inconvertibleErrorCode(),
64 auto error = llvm::joinErrors(llvm::make_error<PacketUnimplementedError>(),
tools/lldb/unittests/Process/minidump/MinidumpParserTest.cpp 55 llvm::Error SetUpFromYaml(llvm::StringRef yaml) {
70 return llvm::Error::success();
tools/lldb/unittests/ScriptInterpreter/Python/PythonDataObjectsTests.cpp 633 llvm::Error error = globals.SetItem("__builtins__", builtins);
tools/lldb/unittests/SymbolFile/DWARF/SymbolFileDWARFTests.cpp 114 llvm::Error error = abbrev_set.extract(data, &data_offset);
159 llvm::Error error = abbrev_set.extract(data, &data_offset);
204 llvm::Error error = abbrev_set.extract(data, &data_offset);
239 llvm::Error error = abbrev_set.extract(data, &data_offset);
268 llvm::Error error = abbrev_set.extract(data, &data_offset);
297 llvm::Error error = abbrev_set.extract(data, &data_offset);
323 llvm::Error error = abbrev_set.extract(data, &data_offset);
tools/lldb/unittests/Utility/RegularExpressionTest.cpp 35 Error err = r1.GetError();
45 Error err = r1.GetError();
tools/lldb/unittests/Utility/StatusTest.cpp 40 foo = llvm::Error::success();
47 llvm::Error eagain = Status(EAGAIN, ErrorType::eErrorTypePOSIX).ToError();
53 llvm::Error foo = Status("foo").ToError();
tools/lldb/unittests/tools/lldb-server/tests/MessageObjects.h 172 llvm::Error make_parsing_error(llvm::StringRef format, Args &&... args) {
tools/lldb/unittests/tools/lldb-server/tests/TestClient.cpp 44 Error TestClient::initializeConnection() {
49 if (Error E = SendMessage("QStartNoAckMode"))
53 return Error::success();
117 if (Error E = Client->initializeConnection())
121 if (Error E = Client->queryProcess())
128 Error TestClient::SetInferior(llvm::ArrayRef<std::string> inferior_args) {
142 if (Error E = SendMessage(command.str()))
144 if (Error E = SendMessage("qLaunchSuccess"))
146 if (Error E = queryProcess())
148 return Error::success();
151 Error TestClient::ListThreadsInStopReply() {
155 Error TestClient::SetBreakpoint(unsigned long address) {
159 Error TestClient::ContinueAll() { return Continue("vCont;c"); }
161 Error TestClient::ContinueThread(unsigned long thread_id) {
178 Error TestClient::SendMessage(StringRef message) {
183 Error TestClient::SendMessage(StringRef message, std::string &response_string) {
184 if (Error E = SendMessage(message, response_string, PacketResult::Success))
189 return Error::success();
192 Error TestClient::SendMessage(StringRef message, std::string &response_string,
204 return Error::success();
212 Error TestClient::qProcessInfo() {
218 return Error::success();
221 Error TestClient::qRegisterInfos() {
236 return Error::success();
239 Error TestClient::queryProcess() {
240 if (Error E = qProcessInfo())
242 if (Error E = qRegisterInfos())
244 return Error::success();
247 Error TestClient::Continue(StringRef message) {
268 return Error::success();
tools/lldb/unittests/tools/lldb-server/tests/TestClient.h 55 llvm::Error SetInferior(llvm::ArrayRef<std::string> inferior_args);
56 llvm::Error ListThreadsInStopReply();
57 llvm::Error SetBreakpoint(unsigned long address);
58 llvm::Error ContinueAll();
59 llvm::Error ContinueThread(unsigned long thread_id);
71 llvm::Error SendMessage(llvm::StringRef message);
72 llvm::Error SendMessage(llvm::StringRef message,
74 llvm::Error SendMessage(llvm::StringRef message, std::string &response_string,
85 llvm::Error initializeConnection();
86 llvm::Error qProcessInfo();
87 llvm::Error qRegisterInfos();
88 llvm::Error queryProcess();
89 llvm::Error Continue(llvm::StringRef message);
105 if (llvm::Error E = SendMessage(Message, ResponseText))
tools/lli/RemoteJITUtils.h 31 llvm::Error readBytes(char *Dst, unsigned Size) override {
46 return llvm::Error::success();
49 llvm::Error appendBytes(const char *Src, unsigned Size) override {
64 return llvm::Error::success();
67 llvm::Error send() override { return llvm::Error::success(); }
67 llvm::Error send() override { return llvm::Error::success(); }
tools/llvm-ar/llvm-ar.cpp 153 static void failIfError(Error E, Twine Context = "") {
590 Error Err = Error::success();
590 Error Err = Error::success();
663 Error Err = Error::success();
663 Error Err = Error::success();
701 Error Err = Error::success();
701 Error Err = Error::success();
779 Error Err = Error::success();
779 Error Err = Error::success();
916 Error E =
970 Error Err = Error::success();
970 Error Err = Error::success();
1032 Error Err = Error::success();
1032 Error Err = Error::success();
tools/llvm-bcanalyzer/llvm-bcanalyzer.cpp 67 static Error reportError(StringRef Message) {
75 if (Error E = MemBufOrErr.takeError())
tools/llvm-cfi-verify/lib/FileAnalysis.cpp 102 if (auto InitResponse = Analysis.initialiseDisassemblyMembers())
105 if (auto SectionParseResponse = Analysis.parseCodeSections())
108 if (auto SymbolTableParseResponse = Analysis.parseSymbolTable())
370 Error FileAnalysis::initialiseDisassemblyMembers() {
422 return Error::success();
425 Error FileAnalysis::parseCodeSections() {
468 return Error::success();
546 Error FileAnalysis::parseSymbolTable() {
577 return Error::success();
tools/llvm-cfi-verify/lib/FileAnalysis.h 185 Error initialiseDisassemblyMembers();
189 Error parseCodeSections();
193 Error parseSymbolTable();
tools/llvm-cov/CodeCoverage.cpp 356 if (Error E = CoverageOrErr.takeError()) {
526 if (Error E = OSOrErr.takeError()) {
893 if (Error E = Printer->createIndexFile(SourceFiles, *Coverage, Filters)) {
914 if (Error E = OSOrErr.takeError()) {
tools/llvm-cov/RenderingSupport.h 43 inline raw_ostream &operator<<(const ColoredRawOstream &OS, T &&Value) {
tools/llvm-cov/SourceCoverageView.h 115 virtual Error createIndexFile(ArrayRef<std::string> SourceFiles,
tools/llvm-cov/SourceCoverageViewHTML.cpp 389 Error CoveragePrinterHTML::createIndexFile(
394 if (Error E = CSSOrErr.takeError())
402 if (Error E = OSOrErr.takeError())
460 return Error::success();
tools/llvm-cov/SourceCoverageViewHTML.h 32 Error createIndexFile(ArrayRef<std::string> SourceFiles,
tools/llvm-cov/SourceCoverageViewText.cpp 30 Error CoveragePrinterText::createIndexFile(
34 if (Error E = OSOrErr.takeError())
45 return Error::success();
tools/llvm-cov/SourceCoverageViewText.h 30 Error createIndexFile(ArrayRef<std::string> SourceFiles,
tools/llvm-cvtres/llvm-cvtres.cpp 85 void error(Error EC) {
tools/llvm-cxxdump/llvm-cxxdump.cpp 51 LLVM_ATTRIBUTE_NORETURN static void error(Error Err) {
500 Error Err = Error::success();
500 Error Err = Error::success();
505 if (auto E = isNotObjectErrorInvalidFileType(ChildOrErr.takeError())) {
tools/llvm-cxxmap/llvm-cxxmap.cpp 68 static void exitWithError(Error E, StringRef Whence = "") {
82 if (Error E = Reader.read(RemappingFile))
tools/llvm-dwarfdump/llvm-dwarfdump.cpp 471 Error Err = Error::success();
471 Error Err = Error::success();
tools/llvm-dwp/llvm-dwp.cpp 365 static Error createError(StringRef Name, Error E) {
365 static Error createError(StringRef Name, Error E) {
372 static Error
376 return Error::success();
384 if (Error E = Dec->resizeAndDecompress(UncompressedSections.back()))
389 return Error::success();
392 static Error handleSection(
404 return Error::success();
407 return Error::success();
419 if (auto Err = handleCompressedSection(UncompressedSections, Name, Contents))
426 return Error::success();
463 return Error::success();
466 static Error
505 static Error write(MCStreamer &Out, ArrayRef<std::string> Inputs) {
554 if (auto Err = handleSection(
643 return Error::success();
741 if (auto Err = write(*MS, DWOFilenames)) {
tools/llvm-elfabi/ELFObjHandler.cpp 65 Error appendToError(Error Err, StringRef After) {
65 Error appendToError(Error Err, StringRef After) {
81 static Error populateDynamic(DynamicEntries &Dyn,
147 return Error::success();
261 static Error populateSymbols(ELFStub &TargetStub,
283 return Error::success();
311 if (Error Err = populateDynamic<ELFT>(DynEnt, *DynTable))
361 Error SymReadError = populateSymbols<ELFT>(*DestStub, DynSyms, DynStr);
tools/llvm-elfabi/ErrorCollector.cpp 23 void ErrorCollector::addError(Error &&Err, StringRef Tag) {
30 Error ErrorCollector::makeError() {
33 Error JoinedErrors = Error::success();
33 Error JoinedErrors = Error::success();
34 for (Error &E : Errors) {
59 for (Error &E : Errors) {
tools/llvm-elfabi/ErrorCollector.h 43 Error makeError();
47 void addError(Error &&E, StringRef Tag);
67 std::vector<Error> Errors;
tools/llvm-elfabi/llvm-elfabi.cpp 55 static Error writeTBE(StringRef FilePath, ELFStub &Stub) {
64 Error YAMLErr = writeTBEToOutputStream(Out, Stub);
68 return Error::success();
123 Error ReadError = StubOrErr.takeError();
136 Error TBEWriteError = writeTBE(EmitTBE, *TargetStub);
tools/llvm-exegesis/lib/Analysis.cpp 184 Error Analysis::run<Analysis::PrintClusters>(raw_ostream &OS) const {
186 return Error::success();
205 return Error::success();
535 Error Analysis::run<Analysis::PrintSchedClassInconsistencies>(
599 return Error::success();
tools/llvm-exegesis/lib/Analysis.h 49 template <typename Pass> Error run(raw_ostream &OS) const;
tools/llvm-exegesis/lib/BenchmarkResult.cpp 373 Error InstructionBenchmark::writeYamlTo(const LLVMState &State,
383 return Error::success();
386 Error InstructionBenchmark::readYamlFrom(const LLVMState &State,
394 return Error::success();
397 Error InstructionBenchmark::writeYaml(const LLVMState &State,
400 if (auto Err = writeYamlTo(State, outs()))
404 if (auto E = errorCodeToError(openFileForWrite(
409 if (auto Err = writeYamlTo(State, Ostr))
412 return Error::success();
tools/llvm-exegesis/lib/BenchmarkResult.h 84 class Error readYamlFrom(const LLVMState &State, StringRef InputContent);
87 class Error writeYamlTo(const LLVMState &State, raw_ostream &S);
89 class Error writeYaml(const LLVMState &State, const StringRef Filename);
tools/llvm-exegesis/lib/BenchmarkRunner.cpp 122 if (Error E = ObjectFilePath.takeError()) {
140 if (Error E = Measurements.takeError()) {
162 if (Error E = errorCodeToError(
tools/llvm-exegesis/lib/Clustering.cpp 94 Error InstructionBenchmarkClustering::validateAndSetup() {
125 return Error::success();
322 if (auto Error = Clustering.validateAndSetup()) {
tools/llvm-exegesis/lib/Clustering.h 126 Error validateAndSetup();
tools/llvm-exegesis/lib/X86/Target.cpp 27 static Error isInvalidMemoryInstr(const Instruction &Instr) {
115 return Error::success();
123 : Error::success();
140 return Error::success();
151 static Error IsInvalidOpcode(const Instruction &Instr) {
158 if (Error Error = isInvalidMemoryInstr(Instr))
171 return Error::success();
258 if (auto E = IsInvalidOpcode(Instr))
309 if (auto E = IsInvalidOpcode(Instr))
tools/llvm-exegesis/llvm-exegesis.cpp 312 if (auto Err = Analyzer.run<Pass>(ClustersOS))
tools/llvm-ifs/llvm-ifs.cpp 277 if (Error Result = TextAPIWriter::writeToStream(OS, File))
tools/llvm-jitlink/llvm-jitlink-macho.cpp 77 Error registerMachOStubsAndGOT(Session &S, LinkGraph &G) {
171 return Error::success();
tools/llvm-jitlink/llvm-jitlink.cpp 233 Error Err = Error::success();
233 Error Err = Error::success();
262 Error deallocate() override {
266 return Error::success();
270 Error applyProtections() {
280 return Error::success();
332 JITLinkSlabAllocator(uint64_t SlabSize, Error &Err) {
438 return Error::success();
444 return Error::success();
448 return Error::success();
456 return Error::success();
535 Error sanitizeArguments(const Session &S) {
546 return Error::success();
549 Error loadProcessSymbols(Session &S) {
563 return Error::success();
566 Error loadDylibs() {
577 return Error::success();
580 Error loadObjects(Session &S) {
656 if (auto Err = JD.define(absoluteSymbols({{S.ES.intern(Name), AbsDef}})))
670 return Error::success();
673 Error runChecks(Session &S) {
752 return Error::success();
tools/llvm-jitlink/llvm-jitlink.h 68 Error registerMachOStubsAndGOT(Session &S, jitlink::LinkGraph &G);
tools/llvm-lipo/llvm-lipo.cpp 39 LLVM_ATTRIBUTE_NORETURN static void reportError(StringRef File, Error E) {
176 Error Err = Error::success();
176 Error Err = Error::success();
581 if (Error E = OutFileOrError.get()->commit())
721 if (Error E = OutFile->commit())
tools/llvm-lto2/llvm-lto2.cpp 140 static void check(Error E, std::string Msg) {
tools/llvm-mca/CodeRegion.h 82 class CodeRegionParseError final : public Error {};
tools/llvm-mca/llvm-mca.cpp 382 if (auto Err =
471 if (auto NewE = handleErrors(
tools/llvm-mt/llvm-mt.cpp 81 void error(Error EC) {
tools/llvm-nm/llvm-nm.cpp 240 static void error(llvm::Error E, StringRef FileName, const Archive::Child &C,
269 static void error(llvm::Error E, StringRef FileName,
1237 if (Error E = Sym.printName(OS)) {
1304 Error Err = Error::success();
1304 Error Err = Error::success();
1464 Error BErr = Error::success();
1464 Error BErr = Error::success();
1518 Error LErr = Error::success();
1518 Error LErr = Error::success();
1579 Error WErr = Error::success();
1579 Error WErr = Error::success();
1817 Error Err = Error::success();
1817 Error Err = Error::success();
1822 if (auto E = isNotObjectErrorInvalidFileType(ChildOrErr.takeError()))
1880 } else if (auto E = isNotObjectErrorInvalidFileType(
1888 Error Err = Error::success();
1888 Error Err = Error::success();
1893 if (auto E = isNotObjectErrorInvalidFileType(
1952 } else if (auto E = isNotObjectErrorInvalidFileType(
1959 Error Err = Error::success();
1959 Error Err = Error::success();
1964 if (auto E = isNotObjectErrorInvalidFileType(
2016 } else if (auto E = isNotObjectErrorInvalidFileType(
2024 Error Err = Error::success();
2024 Error Err = Error::success();
2029 if (auto E = isNotObjectErrorInvalidFileType(
tools/llvm-objcopy/Buffer.cpp 21 static Error createEmptyFile(StringRef FileName) {
29 Error FileBuffer::allocate(size_t Size) {
35 return Error::success();
45 return Error::success();
48 Error FileBuffer::commit() {
53 Error Err = Buf->commit();
63 Error MemBuffer::allocate(size_t Size) {
65 return Error::success();
68 Error MemBuffer::commit() { return Error::success(); }
68 Error MemBuffer::commit() { return Error::success(); }
tools/llvm-objcopy/Buffer.h 30 virtual Error allocate(size_t Size) = 0;
32 virtual Error commit() = 0;
45 Error allocate(size_t Size) override;
47 Error commit() override;
56 Error allocate(size_t Size) override;
58 Error commit() override;
tools/llvm-objcopy/COFF/COFFObjcopy.cpp 92 static Error handleArgs(const CopyConfig &Config, Object &Obj) {
131 if (Error E = Obj.markSymbols())
213 return Error::success();
216 Error executeObjcopyOnBinary(const CopyConfig &Config, COFFObjectFile &In,
224 if (Error E = handleArgs(Config, *Obj))
227 if (Error E = Writer.write())
229 return Error::success();
tools/llvm-objcopy/COFF/COFFObjcopy.h 24 Error executeObjcopyOnBinary(const CopyConfig &Config,
tools/llvm-objcopy/COFF/Object.cpp 48 Error Object::markSymbols() {
60 return Error::success();
tools/llvm-objcopy/COFF/Object.h 123 Error markSymbols();
tools/llvm-objcopy/COFF/Reader.cpp 26 Error COFFReader::readExecutableHeaders(Object &Obj) const {
30 return Error::success();
53 return Error::success();
56 Error COFFReader::readSections(Object &Obj) const {
67 if (Error E = COFFObj.getSectionContents(Sec, Contents))
82 return Error::success();
85 Error COFFReader::readSymbols(Object &Obj, bool IsBigObj) const {
153 return Error::success();
156 Error COFFReader::setSymbolTargets(Object &Obj) const {
190 return Error::success();
211 if (Error E = readExecutableHeaders(*Obj))
213 if (Error E = readSections(*Obj))
215 if (Error E = readSymbols(*Obj, IsBigObj))
217 if (Error E = setSymbolTargets(*Obj))
tools/llvm-objcopy/COFF/Reader.h 28 Error readExecutableHeaders(Object &Obj) const;
29 Error readSections(Object &Obj) const;
30 Error readSymbols(Object &Obj, bool IsBigObj) const;
31 Error setSymbolTargets(Object &Obj) const;
tools/llvm-objcopy/COFF/Writer.cpp 26 Error COFFWriter::finalizeRelocTargets() {
37 return Error::success();
40 Error COFFWriter::finalizeSymbolContents() {
91 return Error::success();
158 Error COFFWriter::finalize(bool IsBigObj) {
164 if (Error E = finalizeRelocTargets())
166 if (Error E = finalizeSymbolContents())
232 return Error::success();
349 Error COFFWriter::write(bool IsBigObj) {
350 if (Error E = finalize(IsBigObj))
353 if (Error E = Buf.allocate(FileSize))
364 if (Error E = patchDebugDirectory())
373 Error COFFWriter::patchDebugDirectory() {
375 return Error::success();
378 return Error::success();
399 return Error::success();
406 Error COFFWriter::write() {
tools/llvm-objcopy/COFF/Writer.h 34 Error finalizeRelocTargets();
35 Error finalizeSymbolContents();
39 Error finalize(bool IsBigObj);
45 Error write(bool IsBigObj);
47 Error patchDebugDirectory();
51 Error write();
tools/llvm-objcopy/CopyConfig.cpp 263 static Error
266 llvm::function_ref<Error(Error)> ErrorCallback) {
266 llvm::function_ref<Error(Error)> ErrorCallback) {
279 if (Error E = Symbols.addMatcher(NameOrPattern::create(
284 return Error::success();
289 llvm::function_ref<Error(Error)> ErrorCallback) {
289 llvm::function_ref<Error(Error)> ErrorCallback) {
305 if (Error E = ErrorCallback(GlobOrErr.takeError()))
322 static Error addSymbolsToRenameFromFile(StringMap<StringRef> &SymbolsToRename,
346 return Error::success();
371 llvm::function_ref<Error(Error)> ErrorCallback) {
371 llvm::function_ref<Error(Error)> ErrorCallback) {
534 if (Error E = addSymbolsToRenameFromFile(Config.SymbolsToRename, DC.Alloc,
585 if (Error E = Config.ToRemove.addMatcher(NameOrPattern::create(
589 if (Error E = Config.KeepSection.addMatcher(NameOrPattern::create(
593 if (Error E = Config.OnlySection.addMatcher(NameOrPattern::create(
633 if (Error E = Config.SymbolsToLocalize.addMatcher(NameOrPattern::create(
637 if (Error E = addSymbolsFromFile(Config.SymbolsToLocalize, DC.Alloc,
642 if (Error E = Config.SymbolsToKeepGlobal.addMatcher(NameOrPattern::create(
646 if (Error E = addSymbolsFromFile(Config.SymbolsToKeepGlobal, DC.Alloc,
651 if (Error E = Config.SymbolsToGlobalize.addMatcher(NameOrPattern::create(
655 if (Error E = addSymbolsFromFile(Config.SymbolsToGlobalize, DC.Alloc,
660 if (Error E = Config.SymbolsToWeaken.addMatcher(NameOrPattern::create(
664 if (Error E = addSymbolsFromFile(Config.SymbolsToWeaken, DC.Alloc,
669 if (Error E = Config.SymbolsToRemove.addMatcher(NameOrPattern::create(
673 if (Error E = addSymbolsFromFile(Config.SymbolsToRemove, DC.Alloc,
678 if (Error E =
683 if (Error E = addSymbolsFromFile(Config.UnneededSymbolsToRemove, DC.Alloc,
688 if (Error E = Config.SymbolsToKeep.addMatcher(NameOrPattern::create(
692 if (Error E =
760 llvm::function_ref<Error(Error)> ErrorCallback) {
760 llvm::function_ref<Error(Error)> ErrorCallback) {
826 if (Error E = Config.KeepSection.addMatcher(NameOrPattern::create(
831 if (Error E = Config.ToRemove.addMatcher(NameOrPattern::create(
836 if (Error E = Config.SymbolsToRemove.addMatcher(NameOrPattern::create(
841 if (Error E = Config.SymbolsToKeep.addMatcher(NameOrPattern::create(
875 if (Error E = ErrorCallback(createStringError(
tools/llvm-objcopy/CopyConfig.h 115 llvm::function_ref<Error(Error)> ErrorCallback);
115 llvm::function_ref<Error(Error)> ErrorCallback);
131 Error addMatcher(Expected<NameOrPattern> Matcher) {
138 return Error::success();
227 Error parseELFConfig() {
234 return Error::success();
252 llvm::function_ref<Error(Error)> ErrorCallback);
252 llvm::function_ref<Error(Error)> ErrorCallback);
260 llvm::function_ref<Error(Error)> ErrorCallback);
260 llvm::function_ref<Error(Error)> ErrorCallback);
tools/llvm-objcopy/ELF/ELFObjcopy.cpp 171 if (auto Err = PhdrsOrErr.takeError())
177 Error Err = Error::success();
177 Error Err = Error::success();
206 static Error makeStringError(std::error_code EC, const Twine &Msg, Ts &&... Args) {
215 static Error linkToBuildIdDir(const CopyConfig &Config, StringRef ToLink,
261 return Error::success();
264 static Error splitDWOToFile(const CopyConfig &Config, const Reader &Reader,
270 if (Error E = DWOFile->removeSections(Config.AllowBrokenLinks,
279 if (Error E = Writer->finalize())
284 static Error dumpSectionToFile(StringRef SecName, StringRef Filename,
299 if (Error E = Buf->commit())
301 return Error::success();
347 static Error updateAndRemoveSymbols(const CopyConfig &Config, Object &Obj) {
351 return Error::success();
439 static Error replaceAndRemoveSections(const CopyConfig &Config, Object &Obj) {
593 static Error handleArgs(const CopyConfig &Config, Object &Obj,
597 if (Error E =
610 if (Error E = replaceAndRemoveSections(Config, Obj))
613 if (Error E = updateAndRemoveSymbols(Config, Obj))
713 if (Error E = dumpSectionToFile(SecName, File, Obj))
731 return Error::success();
734 static Error writeOutput(const CopyConfig &Config, Object &Obj, Buffer &Out,
738 if (Error E = Writer->finalize())
743 Error executeObjcopyOnIHex(const CopyConfig &Config, MemoryBuffer &In,
749 if (Error E = handleArgs(Config, *Obj, Reader, OutputElfType))
754 Error executeObjcopyOnRawBinary(const CopyConfig &Config, MemoryBuffer &In,
765 if (Error E = handleArgs(Config, *Obj, Reader, OutputElfType))
770 Error executeObjcopyOnBinary(const CopyConfig &Config,
782 if (auto E = BuildIdBytesOrErr.takeError())
794 if (Error E =
799 if (Error E = handleArgs(Config, *Obj, Reader, OutputElfType))
802 if (Error E = writeOutput(Config, *Obj, Out, OutputElfType))
805 if (Error E =
810 return Error::success();
tools/llvm-objcopy/ELF/ELFObjcopy.h 25 Error executeObjcopyOnIHex(const CopyConfig &Config, MemoryBuffer &In,
27 Error executeObjcopyOnRawBinary(const CopyConfig &Config, MemoryBuffer &In,
29 Error executeObjcopyOnBinary(const CopyConfig &Config,
tools/llvm-objcopy/ELF/Object.cpp 53 Error SectionBase::removeSectionReferences(
56 return Error::success();
59 Error SectionBase::removeSymbols(function_ref<bool(const Symbol &)> ToRemove) {
60 return Error::success();
208 static Error checkRecord(const IHexRecord &R) {
252 return Error::success();
258 static Error checkChars(StringRef Line) {
268 return Error::success();
279 if (Error E = checkChars(Line))
295 if (Error E = checkRecord(Rec))
434 if (Error E = zlib::uncompress(CompressedContent, DecompressedContent,
507 if (Error E = zlib::compress(
672 Error SymbolTableSection::removeSectionReferences(
699 Error SymbolTableSection::removeSymbols(
707 return Error::success();
804 Error RelocationSection::removeSectionReferences(
828 return Error::success();
893 Error RelocationSection::removeSymbols(
901 return Error::success();
928 Error DynamicRelocationSection::removeSectionReferences(
945 return Error::success();
948 Error Section::removeSectionReferences(
959 return Error::success();
967 Error GroupSection::removeSymbols(function_ref<bool(const Symbol &)> ToRemove) {
973 return Error::success();
1809 Error Object::removeSections(bool AllowBrokenLinks,
1845 if (Error E = KeepSec->removeSectionReferences(AllowBrokenLinks,
1857 return Error::success();
1860 Error Object::removeSymbols(function_ref<bool(const Symbol &)> ToRemove) {
1863 if (Error E = Sec->removeSymbols(ToRemove))
1865 return Error::success();
1990 template <class ELFT> Error ELFWriter<ELFT>::write() {
2002 static Error removeUnneededSections(Object &Obj) {
2009 return Error::success();
2021 template <class ELFT> Error ELFWriter<ELFT>::finalize() {
2030 if (Error E = removeUnneededSections(Obj))
2062 if (Error E = Obj.removeSections(false /*AllowBrokenLinks*/,
2118 if (Error E = Buf.allocate(totalSize()))
2121 return Error::success();
2124 Error BinaryWriter::write() {
2130 Error BinaryWriter::finalize() {
2192 if (Error E = Buf.allocate(TotalSize))
2195 return Error::success();
2231 Error IHexWriter::write() {
2246 Error IHexWriter::checkSection(const SectionBase &Sec) {
2253 return Error::success();
2256 Error IHexWriter::finalize() {
2282 if (Error E = checkSection(Sec))
2296 if (Error E = Buf.allocate(TotalSize))
2298 return Error::success();
tools/llvm-objcopy/ELF/Object.h 311 virtual Error finalize() = 0;
312 virtual Error write() = 0;
345 Error finalize() override;
346 Error write() override;
358 Error finalize() override;
359 Error write() override;
371 Error checkSection(const SectionBase &Sec);
377 Error finalize() override;
378 Error write() override;
411 virtual Error
414 virtual Error removeSymbols(function_ref<bool(const Symbol &)> ToRemove);
478 Error removeSectionReferences(bool AllowBrokenLinks,
687 Error removeSectionReferences(bool AllowBrokenLinks,
693 Error removeSymbols(function_ref<bool(const Symbol &)> ToRemove) override;
757 Error removeSectionReferences(bool AllowBrokenLinks,
759 Error removeSymbols(function_ref<bool(const Symbol &)> ToRemove) override;
796 Error removeSymbols(function_ref<bool(const Symbol &)> ToRemove) override;
836 Error removeSectionReferences(
956 Error parseError(size_t LineNo, Error E) const {
956 Error parseError(size_t LineNo, Error E) const {
963 Error parseError(size_t LineNo, char const *Fmt, const Ts &... Vals) const {
964 Error E = createStringError(errc::invalid_argument, Fmt, Vals...);
1052 Error removeSections(bool AllowBrokenLinks,
1054 Error removeSymbols(function_ref<bool(const Symbol &)> ToRemove);
tools/llvm-objcopy/MachO/MachOLayoutBuilder.cpp 215 Error MachOLayoutBuilder::layoutTail(uint64_t Offset) {
338 return Error::success();
341 Error MachOLayoutBuilder::layout() {
tools/llvm-objcopy/MachO/MachOLayoutBuilder.h 34 Error layoutTail(uint64_t Offset);
41 Error layout();
tools/llvm-objcopy/MachO/MachOObjcopy.cpp 35 static Error handleArgs(const CopyConfig &Config, Object &Obj) {
59 return Error::success();
62 Error executeObjcopyOnBinary(const CopyConfig &Config,
72 if (Error E = handleArgs(Config, *O))
80 if (auto E = Writer.finalize())
tools/llvm-objcopy/MachO/MachOObjcopy.h 25 Error executeObjcopyOnBinary(const CopyConfig &Config,
tools/llvm-objcopy/MachO/MachOWriter.cpp 476 Error MachOWriter::finalize() { return LayoutBuilder.layout(); }
478 Error MachOWriter::write() {
479 if (Error E = B.allocate(totalSize()))
tools/llvm-objcopy/MachO/MachOWriter.h 59 Error finalize();
60 Error write();
tools/llvm-objcopy/llvm-objcopy.cpp 62 LLVM_ATTRIBUTE_NORETURN void error(Error E) {
77 LLVM_ATTRIBUTE_NORETURN void reportError(StringRef File, Error E) {
87 ErrorSuccess reportWarning(Error E) {
90 return Error::success();
102 static Error deepWriteArchive(StringRef ArcName,
106 if (Error E = writeArchive(ArcName, NewMembers, WriteSymtab, Kind,
111 return Error::success();
123 if (Error E = FB.allocate(Member.Buf->getBufferSize()))
127 if (Error E = FB.commit())
130 return Error::success();
135 static Error executeObjcopyOnIHex(CopyConfig &Config, MemoryBuffer &In,
138 if (Error E = Config.parseELFConfig())
145 static Error executeObjcopyOnRawBinary(CopyConfig &Config, MemoryBuffer &In,
155 if (Error E = Config.parseELFConfig())
165 static Error executeObjcopyOnBinary(CopyConfig &Config, object::Binary &In,
168 if (Error E = Config.parseELFConfig())
180 static Error executeObjcopyOnArchive(CopyConfig &Config, const Archive &Ar) {
182 Error Err = Error::success();
182 Error Err = Error::success();
194 if (Error E = executeObjcopyOnBinary(Config, *ChildOrErr->get(), MB))
213 static Error restoreStatOnFile(StringRef Filename,
221 return Error::success();
250 return Error::success();
256 static Error executeObjcopy(CopyConfig &Config) {
265 using ProcessRawFn = Error (*)(CopyConfig &, MemoryBuffer &, Buffer &);
283 if (Error E = ProcessRaw(Config, *BufOrErr->get(), FB))
292 if (Error E = executeObjcopyOnArchive(Config, *Ar))
296 if (Error E = executeObjcopyOnBinary(Config,
302 if (Error E =
308 if (Error E =
313 return Error::success();
345 if (Error E = executeObjcopy(CopyConfig)) {
tools/llvm-objcopy/llvm-objcopy.h 22 LLVM_ATTRIBUTE_NORETURN extern void error(Error E);
23 LLVM_ATTRIBUTE_NORETURN extern void reportError(StringRef File, Error E);
tools/llvm-objdump/COFFDump.cpp 158 static Error resolveSectionAndAddress(const COFFObjectFile *Obj,
170 return Error::success();
175 static Error resolveSymbol(const std::vector<RelocationRef> &Rels,
181 return Error::success();
191 static Error
196 if (Error E = resolveSymbol(Rels, Offset, Sym))
199 if (Error E = resolveSectionAndAddress(Obj, Sym, Section, Addr))
207 static Error resolveSymbolName(const std::vector<RelocationRef> &Rels,
210 if (Error EC = resolveSymbol(Rels, Offset, Sym))
216 return Error::success();
463 if (Error E = Obj->getSectionContents(Pdata, Contents))
476 Error getCOFFRelocationValueString(const COFFObjectFile *Obj,
485 return Error::success();
581 if (Error E = getSectionContents(
tools/llvm-objdump/ELFDump.cpp 53 static Error getRelocationValueString(const ELFObjectFile<ELFT> *Obj,
113 return Error::success();
116 Error getELFRelocationValueString(const ELFObjectFileBase *Obj,
tools/llvm-objdump/MachODump.cpp 500 Error getMachORelocationValueString(const MachOObjectFile *Obj,
575 return Error::success();
675 return Error::success();
1948 if (Error Err = MachOOF->checkSymbolTable())
2290 Error Err = Error::success();
2290 Error Err = Error::success();
2328 if (Error E = isNotObjectErrorInvalidFileType(BinaryOrErr.takeError()))
2341 Error Err = Error::success();
2341 Error Err = Error::success();
2347 if (Error E = isNotObjectErrorInvalidFileType(ChildOrErr.takeError()))
2408 } else if (Error E = isNotObjectErrorInvalidFileType(
2422 Error Err = Error::success();
2422 Error Err = Error::success();
2428 if (Error E =
2473 } else if (Error E =
2483 Error Err = Error::success();
2483 Error Err = Error::success();
2489 if (Error E =
2524 } else if (Error E =
2536 Error Err = Error::success();
2536 Error Err = Error::success();
2542 if (Error E = isNotObjectErrorInvalidFileType(ChildOrErr.takeError()))
10256 Error Err = Error::success();
10256 Error Err = Error::success();
10320 Error Err = Error::success();
10320 Error Err = Error::success();
10364 Error Err = Error::success();
10364 Error Err = Error::success();
10394 Error Err = Error::success();
10394 Error Err = Error::success();
10419 Error Err = Error::success();
10419 Error Err = Error::success();
10452 Error Err = Error::success();
10452 Error Err = Error::success();
tools/llvm-objdump/WasmDump.cpp 29 Error getWasmRelocationValueString(const WasmObjectFile *Obj,
50 return Error::success();
tools/llvm-objdump/llvm-objdump.cpp 421 LLVM_ATTRIBUTE_NORETURN void reportError(Error E, StringRef FileName,
494 static Error getRelocationValueString(const RelocationRef &Rel,
679 if (Error E = getRelocationValueString(Rel, Val))
1645 if (Error E = getRelocationValueString(Reloc, ValueStr))
1679 if (Error E = getRelocationValueString(Reloc, ValueStr))
2211 Error Err = Error::success();
2211 Error Err = Error::success();
2217 if (auto E = isNotObjectErrorInvalidFileType(ChildOrErr.takeError()))
tools/llvm-objdump/llvm-objdump.h 96 Error getELFRelocationValueString(const object::ELFObjectFileBase *Obj,
99 Error getCOFFRelocationValueString(const object::COFFObjectFile *Obj,
102 Error getWasmRelocationValueString(const object::WasmObjectFile *Obj,
105 Error getMachORelocationValueString(const object::MachOObjectFile *Obj,
143 LLVM_ATTRIBUTE_NORETURN void reportError(Error E, StringRef FileName,
tools/llvm-opt-fuzzer/llvm-opt-fuzzer.cpp 146 auto Err = PB.parsePassPipeline(MPM, PassPipeline, false, false);
238 if (auto Err = PB.parsePassPipeline(MPM, PassPipeline, false, false)) {
tools/llvm-opt-report/OptReport.cpp 180 Error E = MaybeRemark.takeError();
tools/llvm-pdbutil/BytesOutputStyle.cpp 88 Error BytesOutputStyle::dump() {
193 return Error::success();
345 if (auto EC = ModStream.reload()) {
439 auto EC = Reader.readBytes(Data, Size);
tools/llvm-pdbutil/BytesOutputStyle.h 32 Error dump() override;
tools/llvm-pdbutil/DumpOutputStyle.cpp 84 Error DumpOutputStyle::dump() {
90 if (auto EC = dumpFileSummary())
96 if (auto EC = dumpStreamSummary())
102 if (auto EC = dumpSymbolStats())
108 if (auto EC = dumpUdtStats())
114 if (auto EC = dumpTypeStats())
120 if (auto EC = dumpNamedStreams())
126 if (auto EC = dumpStringTable())
132 if (auto EC = dumpModules())
137 if (auto EC = dumpModuleFiles())
142 if (auto EC = dumpLines())
147 if (auto EC = dumpInlineeLines())
152 if (auto EC = dumpXmi())
157 if (auto EC = dumpXme())
162 if (auto EC = dumpFpo())
169 if (auto EC = dumpTypesFromObjectFile())
174 if (auto EC = dumpTpiStream(StreamTPI))
180 if (auto EC = dumpTpiStream(StreamIPI))
186 if (auto EC = dumpGSIRecords())
191 if (auto EC = dumpGlobals())
196 if (auto EC = dumpPublics())
201 auto EC = File.isPdb() ? dumpModuleSymsForPdb() : dumpModuleSymsForObj();
207 if (auto EC = dumpTypeRefStats())
212 if (auto EC = dumpSectionHeaders())
217 if (auto EC = dumpSectionContribs())
222 if (auto EC = dumpSectionMap())
228 return Error::success();
237 Error DumpOutputStyle::dumpFileSummary() {
242 return Error::success();
269 return Error::success();
376 Error DumpOutputStyle::dumpStreamSummary() {
381 return Error::success();
409 return Error::success();
428 if (auto EC = ModS.reload())
492 if (auto EC = Subsection.initialize(Reader))
579 Error DumpOutputStyle::dumpModules() {
584 return Error::success();
589 return Error::success();
617 return Error::success();
620 Error DumpOutputStyle::dumpModuleFiles() {
625 return Error::success();
630 return Error::success();
644 return Error::success();
647 Error DumpOutputStyle::dumpSymbolStats() {
652 return Error::success();
696 return Error::success();
699 Error DumpOutputStyle::dumpTypeStats() {
725 return Error::success();
770 Error DumpOutputStyle::dumpUdtStats() {
775 return Error::success();
905 return Error::success();
942 Error DumpOutputStyle::dumpLines() {
947 return Error::success();
980 return Error::success();
983 Error DumpOutputStyle::dumpInlineeLines() {
988 return Error::success();
1008 return Error::success();
1011 Error DumpOutputStyle::dumpXmi() {
1016 return Error::success();
1049 return Error::success();
1052 Error DumpOutputStyle::dumpXme() {
1057 return Error::success();
1071 return Error::success();
1088 Error DumpOutputStyle::dumpOldFpo(PDBFile &File) {
1096 return Error::success();
1112 return Error::success();
1115 Error DumpOutputStyle::dumpNewFpo(PDBFile &File) {
1123 return Error::success();
1146 return Error::success();
1149 Error DumpOutputStyle::dumpFpo() {
1152 return Error::success();
1158 return Error::success();
1161 if (auto EC = dumpOldFpo(File))
1163 if (auto EC = dumpNewFpo(File))
1165 return Error::success();
1168 Error DumpOutputStyle::dumpStringTableFromPdb() {
1174 return Error::success();
1236 return Error::success();
1239 Error DumpOutputStyle::dumpStringTableFromObj() {
1257 return Error::success();
1260 Error DumpOutputStyle::dumpNamedStreams() {
1265 return Error::success();
1281 return Error::success();
1284 Error DumpOutputStyle::dumpStringTable() {
1322 if (auto EC = codeview::visitTypeStream(Types, V)) {
1351 if (auto EC = codeview::visitTypeRecord(Dep.second, Dep.first, V))
1361 if (auto EC = codeview::visitTypeRecord(Type, TI, V))
1368 Error DumpOutputStyle::dumpTypesFromObjectFile() {
1392 if (auto EC = Reader.readInteger(Magic))
1423 return Error::success();
1426 Error DumpOutputStyle::dumpTpiStream(uint32_t StreamIdx) {
1460 return Error::success();
1526 return Error::success();
1529 Error DumpOutputStyle::dumpModuleSymsForObj() {
1546 std::unique_ptr<llvm::Error> SymbolError;
1554 if (auto EC = Visitor.visitSymbolRecord(Symbol)) {
1555 SymbolError = std::make_unique<Error>(std::move(EC));
1564 return Error::success();
1567 Error DumpOutputStyle::dumpModuleSymsForPdb() {
1572 return Error::success();
1601 if (auto EC =
1608 return Error::success();
1611 Error DumpOutputStyle::dumpTypeRefStats() {
1636 return Error::success();
1639 Error DumpOutputStyle::dumpGSIRecords() {
1644 return Error::success();
1649 return Error::success();
1668 if (auto E = Visitor.visitSymbolStream(Records.getSymbolArray(), 0))
1670 return Error::success();
1673 Error DumpOutputStyle::dumpGlobals() {
1678 return Error::success();
1683 return Error::success();
1719 if (auto E = Visitor.visitSymbolRecord(Result.second, Result.first))
1724 return Error::success();
1727 Error DumpOutputStyle::dumpPublics() {
1732 return Error::success();
1737 return Error::success();
1756 return Error::success();
1783 return Error::success();
1786 Error DumpOutputStyle::dumpSymbolsFromGSI(const GSIHashTable &Table,
1819 if (auto E = Visitor.visitSymbolRecord(*Sym, PubSymOff))
1842 return Error::success();
1861 Error DumpOutputStyle::dumpSectionHeaders() {
1864 return Error::success();
1918 Error DumpOutputStyle::dumpSectionContribs() {
1923 return Error::success();
1928 return Error::success();
1960 return Error::success();
1963 Error DumpOutputStyle::dumpSectionMap() {
1968 return Error::success();
1973 return Error::success();
1994 return Error::success();
tools/llvm-pdbutil/DumpOutputStyle.h 72 Error dump() override;
81 Error dumpFileSummary();
82 Error dumpStreamSummary();
83 Error dumpSymbolStats();
84 Error dumpUdtStats();
85 Error dumpTypeStats();
86 Error dumpNamedStreams();
87 Error dumpStringTable();
88 Error dumpStringTableFromPdb();
89 Error dumpStringTableFromObj();
90 Error dumpLines();
91 Error dumpInlineeLines();
92 Error dumpXmi();
93 Error dumpXme();
94 Error dumpFpo();
95 Error dumpOldFpo(PDBFile &File);
96 Error dumpNewFpo(PDBFile &File);
97 Error dumpTpiStream(uint32_t StreamIdx);
98 Error dumpTypesFromObjectFile();
99 Error dumpTypeRefStats();
100 Error dumpModules();
101 Error dumpModuleFiles();
102 Error dumpModuleSymsForPdb();
103 Error dumpModuleSymsForObj();
104 Error dumpGSIRecords();
105 Error dumpGlobals();
106 Error dumpPublics();
107 Error dumpSymbolsFromGSI(const GSIHashTable &Table, bool HashExtras);
108 Error dumpSectionHeaders();
109 Error dumpSectionContribs();
110 Error dumpSectionMap();
tools/llvm-pdbutil/ExplainOutputStyle.cpp 34 Error ExplainOutputStyle::dump() {
44 Error ExplainOutputStyle::explainPdbFile() {
47 return Error::success();
62 return Error::success();
65 Error ExplainOutputStyle::explainBinaryFile() {
72 if (auto EC = Dbi.reload(nullptr))
79 if (auto EC = Info.reload())
87 return Error::success();
tools/llvm-pdbutil/ExplainOutputStyle.h 30 Error dump() override;
33 Error explainPdbFile();
34 Error explainBinaryFile();
tools/llvm-pdbutil/InputFile.cpp 59 if (auto EC = ModS.reload())
277 if (auto Err = loadDataForPDB(PDB_ReaderType::Native, Path, Session))
tools/llvm-pdbutil/MinimalSymbolDumper.cpp 341 Error MinimalSymbolDumper::visitSymbolBegin(codeview::CVSymbol &Record) {
345 Error MinimalSymbolDumper::visitSymbolBegin(codeview::CVSymbol &Record,
354 return Error::success();
357 Error MinimalSymbolDumper::visitSymbolEnd(CVSymbol &Record) {
363 return Error::success();
387 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR, BlockSym &Block) {
393 return Error::success();
396 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR, Thunk32Sym &Thunk) {
405 return Error::success();
408 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR,
416 return Error::success();
419 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR,
431 return Error::success();
434 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR, CoffGroupSym &CG) {
444 return Error::success();
447 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR,
452 return Error::success();
455 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR,
458 return Error::success();
461 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR,
466 return Error::success();
469 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR,
475 return Error::success();
478 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR, FileStaticSym &FS) {
489 return Error::success();
495 return Error::success();
498 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR, ExportSym &Export) {
503 return Error::success();
506 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR,
524 return Error::success();
527 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR,
543 return Error::success();
546 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR,
552 return Error::success();
555 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR, DataSym &Data) {
560 return Error::success();
563 Error MinimalSymbolDumper::visitKnownRecord(
566 return Error::success();
569 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR,
576 return Error::success();
579 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR,
589 return Error::success();
592 Error MinimalSymbolDumper::visitKnownRecord(
604 return Error::success();
607 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR,
616 return Error::success();
619 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR,
625 return Error::success();
628 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR, DefRangeSym &Def) {
633 return Error::success();
636 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR, FrameCookieSym &FC) {
641 return Error::success();
644 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR, FrameProcSym &FP) {
659 return Error::success();
662 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR,
668 return Error::success();
671 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR, InlineSiteSym &IS) {
756 return Error::success();
759 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR,
766 return Error::success();
769 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR,
776 return Error::success();
779 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR, ProcRefSym &PR) {
784 return Error::success();
787 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR, LabelSym &Label) {
793 return Error::success();
796 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR, LocalSym &Local) {
803 return Error::success();
806 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR,
809 return Error::success();
812 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR, ProcSym &Proc) {
833 return Error::success();
836 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR,
838 return Error::success();
841 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR, CallerSym &Caller) {
846 return Error::success();
849 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR,
856 return Error::success();
859 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR,
865 return Error::success();
868 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR, UDTSym &UDT) {
872 return Error::success();
875 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR,
878 return Error::success();
881 Error MinimalSymbolDumper::visitKnownRecord(CVSymbol &CVR,
887 return Error::success();
tools/llvm-pdbutil/MinimalSymbolDumper.h 36 Error visitSymbolBegin(codeview::CVSymbol &Record) override;
37 Error visitSymbolBegin(codeview::CVSymbol &Record, uint32_t Offset) override;
38 Error visitSymbolEnd(codeview::CVSymbol &Record) override;
tools/llvm-pdbutil/MinimalTypeDumper.cpp 220 Error MinimalTypeDumpVisitor::visitTypeBegin(CVType &Record, TypeIndex Index) {
254 return Error::success();
257 Error MinimalTypeDumpVisitor::visitTypeEnd(CVType &Record) {
263 return Error::success();
266 Error MinimalTypeDumpVisitor::visitMemberBegin(CVMemberRecord &Record) {
268 return Error::success();
271 Error MinimalTypeDumpVisitor::visitMemberEnd(CVMemberRecord &Record) {
276 return Error::success();
285 Error MinimalTypeDumpVisitor::visitKnownRecord(CVType &CVR,
287 if (auto EC = codeview::visitMemberRecordStream(FieldList.Data, *this))
290 return Error::success();
293 Error MinimalTypeDumpVisitor::visitKnownRecord(CVType &CVR,
296 return Error::success();
299 Error MinimalTypeDumpVisitor::visitKnownRecord(CVType &CVR,
303 return Error::success();
311 return Error::success();
314 Error MinimalTypeDumpVisitor::visitKnownRecord(CVType &CVR,
318 return Error::success();
326 return Error::success();
329 Error MinimalTypeDumpVisitor::visitKnownRecord(CVType &CVR,
340 return Error::success();
343 Error MinimalTypeDumpVisitor::visitKnownRecord(CVType &CVR,
353 return Error::success();
356 Error MinimalTypeDumpVisitor::visitKnownRecord(CVType &CVR, EnumRecord &Enum) {
365 return Error::success();
368 Error MinimalTypeDumpVisitor::visitKnownRecord(CVType &CVR, ArrayRecord &AT) {
376 return Error::success();
379 Error MinimalTypeDumpVisitor::visitKnownRecord(CVType &CVR,
391 return Error::success();
394 Error MinimalTypeDumpVisitor::visitKnownRecord(CVType &CVR,
398 return Error::success();
401 Error MinimalTypeDumpVisitor::visitKnownRecord(CVType &CVR,
408 return Error::success();
411 Error MinimalTypeDumpVisitor::visitKnownRecord(CVType &CVR,
420 return Error::success();
423 Error MinimalTypeDumpVisitor::visitKnownRecord(CVType &CVR,
427 return Error::success();
430 Error MinimalTypeDumpVisitor::visitKnownRecord(CVType &CVR,
433 return Error::success();
436 Error MinimalTypeDumpVisitor::visitKnownRecord(CVType &CVR,
440 return Error::success();
443 Error MinimalTypeDumpVisitor::visitKnownRecord(CVType &CVR,
447 return Error::success();
450 Error MinimalTypeDumpVisitor::visitKnownRecord(CVType &CVR,
452 return Error::success();
455 Error MinimalTypeDumpVisitor::visitKnownRecord(CVType &CVR,
459 return Error::success();
462 Error MinimalTypeDumpVisitor::visitKnownRecord(CVType &CVR,
466 return Error::success();
469 Error MinimalTypeDumpVisitor::visitKnownRecord(CVType &CVR,
473 return Error::success();
476 Error MinimalTypeDumpVisitor::visitKnownRecord(
481 return Error::success();
484 Error MinimalTypeDumpVisitor::visitKnownRecord(CVType &CVR,
488 return Error::success();
496 return Error::success();
499 Error MinimalTypeDumpVisitor::visitKnownRecord(CVType &CVR, LabelRecord &R) {
502 return Error::success();
505 Error MinimalTypeDumpVisitor::visitKnownRecord(CVType &CVR,
511 return Error::success();
514 Error MinimalTypeDumpVisitor::visitKnownRecord(CVType &CVR,
517 return Error::success();
520 Error MinimalTypeDumpVisitor::visitKnownMember(CVMemberRecord &CVR,
523 return Error::success();
526 Error MinimalTypeDumpVisitor::visitKnownMember(CVMemberRecord &CVR,
532 return Error::success();
535 Error MinimalTypeDumpVisitor::visitKnownMember(CVMemberRecord &CVR,
539 return Error::success();
542 Error MinimalTypeDumpVisitor::visitKnownMember(CVMemberRecord &CVR,
546 return Error::success();
549 Error MinimalTypeDumpVisitor::visitKnownMember(CVMemberRecord &CVR,
553 return Error::success();
556 Error MinimalTypeDumpVisitor::visitKnownMember(CVMemberRecord &CVR,
560 return Error::success();
563 Error MinimalTypeDumpVisitor::visitKnownMember(CVMemberRecord &CVR,
568 return Error::success();
571 Error MinimalTypeDumpVisitor::visitKnownMember(CVMemberRecord &CVR,
578 return Error::success();
581 Error MinimalTypeDumpVisitor::visitKnownMember(CVMemberRecord &CVR,
584 return Error::success();
587 Error MinimalTypeDumpVisitor::visitKnownMember(CVMemberRecord &CVR,
590 return Error::success();
tools/llvm-pdbutil/MinimalTypeDumper.h 37 Error visitTypeBegin(codeview::CVType &Record,
39 Error visitTypeEnd(codeview::CVType &Record) override;
40 Error visitMemberBegin(codeview::CVMemberRecord &Record) override;
41 Error visitMemberEnd(codeview::CVMemberRecord &Record) override;
tools/llvm-pdbutil/OutputStyle.h 22 virtual Error dump() = 0;
tools/llvm-pdbutil/YAMLOutputStyle.cpp 45 Error YAMLOutputStyle::dump() {
49 if (auto EC = dumpFileHeaders())
52 if (auto EC = dumpStreamMetadata())
55 if (auto EC = dumpStreamDirectory())
58 if (auto EC = dumpStringTable())
61 if (auto EC = dumpPDBStream())
64 if (auto EC = dumpDbiStream())
67 if (auto EC = dumpTpiStream())
70 if (auto EC = dumpIpiStream())
73 if (auto EC = dumpPublics())
77 return Error::success();
81 Error YAMLOutputStyle::dumpFileHeaders() {
83 return Error::success();
100 return Error::success();
103 Error YAMLOutputStyle::dumpStringTable() {
108 return Error::success();
124 return Error::success();
127 Error YAMLOutputStyle::dumpStreamMetadata() {
129 return Error::success();
134 return Error::success();
137 Error YAMLOutputStyle::dumpStreamDirectory() {
139 return Error::success();
149 return Error::success();
152 Error YAMLOutputStyle::dumpPDBStream() {
154 return Error::success();
168 return Error::success();
195 Error YAMLOutputStyle::dumpDbiStream() {
197 return Error::success();
200 return Error::success();
236 if (auto EC = ModS.reload())
279 return Error::success();
282 Error YAMLOutputStyle::dumpTpiStream() {
284 return Error::success();
300 return Error::success();
303 Error YAMLOutputStyle::dumpIpiStream() {
305 return Error::success();
311 return Error::success();
328 return Error::success();
331 Error YAMLOutputStyle::dumpPublics() {
333 return Error::success();
339 return Error::success();
348 return Error::success();
364 return Error::success();
tools/llvm-pdbutil/YAMLOutputStyle.h 26 Error dump() override;
29 Error dumpStringTable();
30 Error dumpFileHeaders();
31 Error dumpStreamMetadata();
32 Error dumpStreamDirectory();
33 Error dumpPDBStream();
34 Error dumpDbiStream();
35 Error dumpTpiStream();
36 Error dumpIpiStream();
37 Error dumpPublics();
tools/llvm-profdata/llvm-profdata.cpp 67 static void exitWithError(Error E, StringRef Whence = "") {
100 static void handleMergeWriterError(Error E, StringRef WhenceFile = "",
187 std::vector<std::pair<Error, std::string>> Errors;
205 if (Error E = ReaderOrErr.takeError()) {
234 if (Error E = ReaderOrErr.takeError()) {
274 if (Error E = Reader->getError())
372 if (Error E = Writer.writeText(Output))
705 Error E = Overlap.accumulateCounts(BaseFilename, TestFilename, IsCS);
826 if (Error E = ReaderOrErr.takeError())
tools/llvm-rc/ResourceFileWriter.cpp 46 static Error createError(const Twine &Message,
51 static Error checkNumberFits(uint32_t Number, size_t MaxBits,
55 return Error::success();
62 static Error checkNumberFits(uint32_t Number, const Twine &FieldName) {
68 static Error checkSignedNumberFits(uint32_t Number, const Twine &FieldName,
82 return Error::success();
85 static Error checkRCInt(RCInt Number, const Twine &FieldName) {
87 return Error::success();
91 static Error checkIntOrString(IntOrString Value, const Twine &FieldName) {
93 return Error::success();
145 static Error processString(StringRef Str, NullHandlingMethod NullHandler,
174 return Error::success();
191 return Error::success();
359 return Error::success();
368 Error ResourceFileWriter::writeCString(StringRef Str, bool WriteTerminator) {
378 return Error::success();
381 Error ResourceFileWriter::writeIdentifier(const IntOrString &Ident) {
385 Error ResourceFileWriter::writeIntOrString(const IntOrString &Value) {
391 return Error::success();
401 Error ResourceFileWriter::appendFile(StringRef Filename) {
410 return Error::success();
422 Error ResourceFileWriter::handleError(Error Err, const RCResource *Res) {
422 Error ResourceFileWriter::handleError(Error Err, const RCResource *Res) {
428 return Error::success();
431 Error ResourceFileWriter::visitNullResource(const RCResource *Res) {
435 Error ResourceFileWriter::visitAcceleratorsResource(const RCResource *Res) {
439 Error ResourceFileWriter::visitBitmapResource(const RCResource *Res) {
443 Error ResourceFileWriter::visitCursorResource(const RCResource *Res) {
447 Error ResourceFileWriter::visitDialogResource(const RCResource *Res) {
451 Error ResourceFileWriter::visitIconResource(const RCResource *Res) {
455 Error ResourceFileWriter::visitCaptionStmt(const CaptionStmt *Stmt) {
457 return Error::success();
460 Error ResourceFileWriter::visitClassStmt(const ClassStmt *Stmt) {
462 return Error::success();
465 Error ResourceFileWriter::visitHTMLResource(const RCResource *Res) {
469 Error ResourceFileWriter::visitMenuResource(const RCResource *Res) {
473 Error ResourceFileWriter::visitStringTableResource(const RCResource *Base) {
499 return Error::success();
502 Error ResourceFileWriter::visitUserDefinedResource(const RCResource *Res) {
506 Error ResourceFileWriter::visitVersionInfoResource(const RCResource *Res) {
510 Error ResourceFileWriter::visitCharacteristicsStmt(
513 return Error::success();
516 Error ResourceFileWriter::visitExStyleStmt(const ExStyleStmt *Stmt) {
518 return Error::success();
521 Error ResourceFileWriter::visitFontStmt(const FontStmt *Stmt) {
528 return Error::success();
531 Error ResourceFileWriter::visitLanguageStmt(const LanguageResource *Stmt) {
535 return Error::success();
538 Error ResourceFileWriter::visitStyleStmt(const StyleStmt *Stmt) {
540 return Error::success();
543 Error ResourceFileWriter::visitVersionStmt(const VersionStmt *Stmt) {
545 return Error::success();
548 Error ResourceFileWriter::writeResource(
583 return Error::success();
588 Error ResourceFileWriter::writeNullBody(const RCResource *) {
589 return Error::success();
594 Error ResourceFileWriter::writeSingleAccelerator(
639 return Error::success();
667 return Error::success();
686 return Error::success();
689 Error ResourceFileWriter::writeAcceleratorsBody(const RCResource *Base) {
697 return Error::success();
702 Error ResourceFileWriter::writeBitmapBody(const RCResource *Base) {
720 return Error::success();
833 Error ResourceFileWriter::writeSingleIconOrCursorBody(const RCResource *Base) {
847 return Error::success();
850 Error ResourceFileWriter::writeIconOrCursorGroupBody(const RCResource *Base) {
857 return Error::success();
860 Error ResourceFileWriter::visitSingleIconOrCursor(const RCResource *Res) {
864 Error ResourceFileWriter::visitIconOrCursorGroup(const RCResource *Res) {
868 Error ResourceFileWriter::visitIconOrCursorResource(const RCResource *Base) {
978 return Error::success();
983 Error ResourceFileWriter::writeSingleDialogControl(const Control &Ctl,
1050 return Error::success();
1053 Error ResourceFileWriter::writeDialogBody(const RCResource *Base) {
1155 return Error::success();
1165 return Error::success();
1170 Error ResourceFileWriter::writeHTMLBody(const RCResource *Base) {
1176 Error ResourceFileWriter::writeMenuDefinition(
1187 return Error::success();
1193 return Error::success();
1202 Error ResourceFileWriter::writeMenuDefinitionList(
1213 return Error::success();
1216 Error ResourceFileWriter::writeMenuBody(const RCResource *Base) {
1242 Error ResourceFileWriter::visitStringTableBundle(const RCResource *Res) {
1246 Error ResourceFileWriter::insertStringIntoBundle(
1253 return Error::success();
1256 Error ResourceFileWriter::writeStringTableBundleBody(const RCResource *Base) {
1275 return Error::success();
1278 Error ResourceFileWriter::dumpAllStringTables() {
1292 return Error::success();
1297 Error ResourceFileWriter::writeUserDefinedBody(const RCResource *Base) {
1329 return Error::success();
1334 Error ResourceFileWriter::writeVersionInfoBlock(const VersionInfoBlock &Blk) {
1365 return Error::success();
1368 Error ResourceFileWriter::writeVersionInfoValue(const VersionInfoValue &Val) {
1424 return Error::success();
1436 Error ResourceFileWriter::writeVersionInfoBody(const RCResource *Base) {
1502 return Error::success();
tools/llvm-rc/ResourceFileWriter.h 51 Error visitNullResource(const RCResource *) override;
52 Error visitAcceleratorsResource(const RCResource *) override;
53 Error visitCursorResource(const RCResource *) override;
54 Error visitDialogResource(const RCResource *) override;
55 Error visitHTMLResource(const RCResource *) override;
56 Error visitIconResource(const RCResource *) override;
57 Error visitMenuResource(const RCResource *) override;
58 Error visitVersionInfoResource(const RCResource *) override;
59 Error visitStringTableResource(const RCResource *) override;
60 Error visitUserDefinedResource(const RCResource *) override;
62 Error visitCaptionStmt(const CaptionStmt *) override;
63 Error visitCharacteristicsStmt(const CharacteristicsStmt *) override;
64 Error visitClassStmt(const ClassStmt *) override;
65 Error visitExStyleStmt(const ExStyleStmt *) override;
66 Error visitFontStmt(const FontStmt *) override;
67 Error visitLanguageStmt(const LanguageResource *) override;
68 Error visitStyleStmt(const StyleStmt *) override;
69 Error visitVersionStmt(const VersionStmt *) override;
73 Error dumpAllStringTables();
118 Error handleError(Error Err, const RCResource *Res);
118 Error handleError(Error Err, const RCResource *Res);
120 Error
125 Error writeNullBody(const RCResource *);
128 Error writeSingleAccelerator(const AcceleratorsResource::Accelerator &,
130 Error writeAcceleratorsBody(const RCResource *);
133 Error visitBitmapResource(const RCResource *) override;
134 Error writeBitmapBody(const RCResource *);
137 Error visitIconOrCursorResource(const RCResource *);
138 Error visitIconOrCursorGroup(const RCResource *);
139 Error visitSingleIconOrCursor(const RCResource *);
140 Error writeSingleIconOrCursorBody(const RCResource *);
141 Error writeIconOrCursorGroupBody(const RCResource *);
144 Error writeSingleDialogControl(const Control &, bool IsExtended);
145 Error writeDialogBody(const RCResource *);
148 Error writeHTMLBody(const RCResource *);
151 Error writeMenuDefinition(const std::unique_ptr<MenuDefinition> &,
153 Error writeMenuDefinitionList(const MenuDefinitionList &List);
154 Error writeMenuBody(const RCResource *);
157 Error visitStringTableBundle(const RCResource *);
158 Error writeStringTableBundleBody(const RCResource *);
159 Error insertStringIntoBundle(StringTableInfo::Bundle &Bundle,
163 Error writeUserDefinedBody(const RCResource *);
166 Error writeVersionInfoBody(const RCResource *);
167 Error writeVersionInfoBlock(const VersionInfoBlock &);
168 Error writeVersionInfoValue(const VersionInfoValue &);
195 Error writeCString(StringRef Str, bool WriteTerminator = true);
197 Error writeIdentifier(const IntOrString &Ident);
198 Error writeIntOrString(const IntOrString &Data);
202 Error appendFile(StringRef Filename);
tools/llvm-rc/ResourceScriptParser.cpp 261 Error RCParser::consumeType(Kind TokenKind) {
264 return Error::success();
308 if (auto CommaError = consumeType(Kind::Comma))
843 Error RCParser::getExpectedError(const Twine &Message, bool IsAlreadyRead) {
tools/llvm-rc/ResourceScriptParser.h 96 Error consumeType(Kind TokenKind);
182 Error getExpectedError(const Twine &Message, bool IsAlreadyRead = false);
tools/llvm-rc/ResourceScriptStmt.h 224 virtual Error visit(Visitor *) const {
230 virtual Error applyStmts(Visitor *) const { return Error::success(); }
230 virtual Error applyStmts(Visitor *) const { return Error::success(); }
256 Error visit(Visitor *V) const override { return V->visitNullResource(this); }
275 Error visit(Visitor *V) const override {
277 if (auto Err = StmtPtr->visit(V))
279 return Error::success();
292 virtual Error applyStmts(Visitor *V) const { return OptStatements->visit(V); }
311 Error visit(Visitor *V) const override { return V->visitLanguageStmt(this); }
359 Error visit(Visitor *V) const override {
383 Error visit(Visitor *V) const override {
405 Error visit(Visitor *V) const override {
427 Error visit(Visitor *V) const override { return V->visitIconResource(this); }
447 Error visit(Visitor *V) const override { return V->visitHTMLResource(this); }
572 Error visit(Visitor *V) const override { return V->visitMenuResource(this); }
593 Error visit(Visitor *V) const override {
674 Error visit(Visitor *V) const override {
707 Error visit(Visitor *V) const override {
836 Error visit(Visitor *V) const override {
856 Error visit(Visitor *V) const override {
872 Error visit(Visitor *V) const override { return V->visitVersionStmt(this); }
885 Error visit(Visitor *V) const override { return V->visitCaptionStmt(this); }
906 Error visit(Visitor *V) const override { return V->visitFontStmt(this); }
919 Error visit(Visitor *V) const override { return V->visitStyleStmt(this); }
932 Error visit(Visitor *V) const override { return V->visitExStyleStmt(this); }
945 Error visit(Visitor *V) const override { return V->visitClassStmt(this); }
tools/llvm-rc/ResourceScriptToken.cpp 78 static Error getStringError(const Twine &message) {
98 Error consumeToken(const Kind TokenKind);
172 if (Error TokenError = consumeToken(TokenKind))
209 Error Tokenizer::consumeToken(const Kind TokenKind) {
216 return Error::success();
221 return Error::success();
231 return Error::success();
236 return Error::success();
241 return Error::success();
260 return Error::success();
tools/llvm-rc/ResourceVisitor.h 34 virtual Error visitNullResource(const RCResource *) = 0;
35 virtual Error visitAcceleratorsResource(const RCResource *) = 0;
36 virtual Error visitBitmapResource(const RCResource *) = 0;
37 virtual Error visitCursorResource(const RCResource *) = 0;
38 virtual Error visitDialogResource(const RCResource *) = 0;
39 virtual Error visitHTMLResource(const RCResource *) = 0;
40 virtual Error visitIconResource(const RCResource *) = 0;
41 virtual Error visitMenuResource(const RCResource *) = 0;
42 virtual Error visitStringTableResource(const RCResource *) = 0;
43 virtual Error visitUserDefinedResource(const RCResource *) = 0;
44 virtual Error visitVersionInfoResource(const RCResource *) = 0;
46 virtual Error visitCaptionStmt(const CaptionStmt *) = 0;
47 virtual Error visitClassStmt(const ClassStmt *) = 0;
48 virtual Error visitCharacteristicsStmt(const CharacteristicsStmt *) = 0;
49 virtual Error visitExStyleStmt(const ExStyleStmt *) = 0;
50 virtual Error visitFontStmt(const FontStmt *) = 0;
51 virtual Error visitLanguageStmt(const LanguageResource *) = 0;
52 virtual Error visitStyleStmt(const StyleStmt *) = 0;
53 virtual Error visitVersionStmt(const VersionStmt *) = 0;
tools/llvm-readobj/ARMWinEHPrinter.cpp 1096 Error Decoder::dumpProcedureData(const COFFObjectFile &COFF) {
1106 return Error::success();
tools/llvm-readobj/ARMWinEHPrinter.h 159 Error dumpProcedureData(const object::COFFObjectFile &COFF);
tools/llvm-readobj/COFFDumper.cpp 63 static inline Error createError(const Twine &Err) {
204 if (auto EC = Reader.readLongestContiguousChunk(Data)) {
913 if (Error E = Reader.readInteger(SubType))
915 if (Error E = Reader.readInteger(SubSectionSize))
919 if (Error E = Reader.readFixedString(Contents, SubSectionSize))
925 if (Error E = CVFileChecksumTable.initialize(ST))
929 if (Error E = CVStringTable.initialize(ST))
937 if (Error E = Reader.skip(PaddedSize - SubSectionSize))
956 if (Error E = consume(Data, Magic))
972 if (Error E = consume(Data, SubType))
974 if (Error E = consume(Data, SubSectionSize))
1056 if (Error E = FrameData.initialize(SR))
1121 if (Error E = LineInfo.initialize(Reader))
1171 if (Error E = Reader.readArray(Symbols, Reader.getLength())) {
1176 if (Error E = CVSD.dump(Symbols)) {
1187 if (Error E = Checksums.initialize(Stream))
1207 if (Error E = Lines.initialize(SR))
1257 if (Error E = consume(Data, Magic))
1266 if (auto EC = Reader.readArray(Types, Reader.getLength())) {
1277 if (Error E =
1282 if (Error E = mergeTypeAndIdRecords(CVIDs, CVTypes, SourceToDest, Types,
1300 if (Error E = consume(Data, Magic))
1311 if (Error E = codeview::visitTypeStream(Types, TDV))
1770 Error E = RSF.load(Obj, S);
1968 if (Error Err = codeview::visitTypeStream(TpiTypes, TDV))
1980 if (Error Err = codeview::visitTypeStream(IpiTypes, TDV))
tools/llvm-readobj/DwarfCFIEHPrinter.h 51 if (Error E = Sections.takeError())
66 if (Error E = PHs.takeError())
85 if (Error E = Sections.takeError())
90 if (Error E = SectionName.takeError())
111 if (Error E = SectionName.takeError())
186 if (Error E = Result.takeError())
tools/llvm-readobj/ELFDumper.cpp 382 return Error::success();
436 std::function<Error(const Twine &Msg)> WarningHandler;
1695 Error Err =
4669 Error Err = Error::success();
4669 Error Err = Error::success();
4681 Error Err = Error::success();
4681 Error Err = Error::success();
5913 Error Err = Error::success();
5913 Error Err = Error::success();
5926 Error Err = Error::success();
5926 Error Err = Error::success();
tools/llvm-readobj/ObjDumper.cpp 26 static inline Error createError(const Twine &Msg) {
tools/llvm-readobj/Win64EHDumper.cpp 292 if (Error E = Ctx.COFF.getSectionContents(XData, Contents))
320 if (Error E = Ctx.COFF.getSectionContents(PData, Contents))
tools/llvm-readobj/WindowsResourceDumper.cpp 39 Error Dumper::printData() {
49 if (auto Err = EntryPtr.moveNext(IsEnd))
52 return Error::success();
tools/llvm-readobj/WindowsResourceDumper.h 23 Error printData();
tools/llvm-readobj/llvm-readobj.cpp 374 LLVM_ATTRIBUTE_NORETURN void reportError(Error Err, StringRef Input) {
383 void reportWarning(Error Err, StringRef Input) {
553 Error Err = Error::success();
553 Error Err = Error::success();
557 if (auto E = isNotObjectErrorInvalidFileType(ChildOrErr.takeError()))
580 else if (auto E = isNotObjectErrorInvalidFileType(ObjOrErr.takeError()))
591 if (auto Err = Dumper.printData())
tools/llvm-readobj/llvm-readobj.h 24 LLVM_ATTRIBUTE_NORETURN void reportError(Error Err, StringRef Input);
25 void reportWarning(Error Err, StringRef Input);
tools/llvm-reduce/TestRunner.cpp 34 Error E = make_error<StringError>("Error running interesting-ness test: " +
tools/llvm-rtdyld/llvm-rtdyld.cpp 232 else if (auto Err = Sym.takeError())
tools/llvm-size/llvm-size.cpp 118 static void error(llvm::Error E, StringRef FileName, const Archive::Child &C,
146 static void error(llvm::Error E, StringRef FileName,
551 Error Err = Error::success();
551 Error Err = Error::success();
555 if (auto E = isNotObjectErrorInvalidFileType(ChildOrErr.takeError()))
610 } else if (auto E = isNotObjectErrorInvalidFileType(
620 Error Err = Error::success();
620 Error Err = Error::success();
624 if (auto E = isNotObjectErrorInvalidFileType(
701 } else if (auto E = isNotObjectErrorInvalidFileType(UO.takeError())) {
709 Error Err = Error::success();
709 Error Err = Error::success();
713 if (auto E = isNotObjectErrorInvalidFileType(
777 } else if (auto E = isNotObjectErrorInvalidFileType(UO.takeError())) {
785 Error Err = Error::success();
785 Error Err = Error::success();
789 if (auto E = isNotObjectErrorInvalidFileType(
tools/llvm-xray/xray-account.cpp 410 static CommandRegistration Unused(&Account, []() -> Error {
479 return Error::success();
tools/llvm-xray/xray-converter.cpp 368 static CommandRegistration Unused(&Convert, []() -> Error {
416 return Error::success();
tools/llvm-xray/xray-extract.cpp 73 static CommandRegistration Unused(&Extract, []() -> Error {
93 return Error::success();
tools/llvm-xray/xray-fdr-dump.cpp 36 static CommandRegistration Unused(&Dump, []() -> Error {
70 if (auto E = C.consume(std::move(R.get())))
73 return Error::success();
84 if (auto E = Ptr->apply(RP))
88 if (auto E = C.consume(std::move(R.get())))
96 if (auto E = Ptr->apply(BI))
99 if (auto E = BI.flush())
108 if (auto E = R->apply(BV))
110 if (auto E = R->apply(BP))
118 return Error::success();
tools/llvm-xray/xray-graph-diff.cpp 427 static CommandRegistration Unused(&GraphDiff, []() -> Error {
482 return Error::success();
tools/llvm-xray/xray-graph.cpp 191 Error GraphRenderer::accountRecord(const XRayRecord &Record) {
254 return Error::success();
447 auto E = GR.accountRecord(Record);
488 static CommandRegistration Unused(&GraphC, []() -> Error {
516 return Error::success();
tools/llvm-xray/xray-graph.h 139 Error accountRecord(const XRayRecord &Record);
tools/llvm-xray/xray-registry.cpp 20 using HandlerType = std::function<Error()>;
tools/llvm-xray/xray-registry.h 31 CommandRegistration(cl::SubCommand *SC, std::function<Error()> Command);
35 std::function<Error()> dispatch(cl::SubCommand *SC);
tools/llvm-xray/xray-stacks.cpp 688 static CommandRegistration Unused(&Stack, []() -> Error {
783 return Error::success();
794 return Error::success();
tools/obj2yaml/elf2yaml.cpp 51 Error dumpSymbols(const Elf_Shdr *Symtab,
53 Error dumpSymbol(const Elf_Sym *Sym, const Elf_Shdr *SymTab,
55 Error dumpCommonSection(const Elf_Shdr *Shdr, ELFYAML::Section &S);
56 Error dumpCommonRelocationSection(const Elf_Shdr *Shdr,
59 Error dumpRelocation(const RelT *Rel, const Elf_Shdr *SymTab,
209 if (Error E = dumpSymbols(SymTab, *Y->Symbols))
214 if (Error E = dumpSymbols(DynSymTab, Y->DynamicSymbols))
347 Error ELFDumper<ELFT>::dumpSymbols(const Elf_Shdr *Symtab,
350 return Error::success();
368 if (auto EC = dumpSymbol(&Sym, Symtab, StrTable, S))
373 return Error::success();
377 Error ELFDumper<ELFT>::dumpSymbol(const Elf_Sym *Sym, const Elf_Shdr *SymTab,
393 return Error::success();
401 return Error::success();
408 return Error::success();
413 Error ELFDumper<ELFT>::dumpRelocation(const RelT *Rel, const Elf_Shdr *SymTab,
427 return Error::success();
442 return Error::success();
446 Error ELFDumper<ELFT>::dumpCommonSection(const Elf_Shdr *Shdr,
477 return Error::success();
493 Error ELFDumper<ELFT>::dumpCommonRelocationSection(
495 if (Error E = dumpCommonSection(Shdr, S))
507 return Error::success();
514 if (Error E = dumpCommonSection(Shdr, *S))
547 if (Error E = dumpCommonSection(Shdr, *S))
587 if (Error E = dumpCommonSection(Shdr, *S))
604 if (auto E = dumpCommonRelocationSection(Shdr, *S))
618 if (Error E = dumpRelocation(&Rel, SymTab, R))
628 if (Error E = dumpRelocation(&Rel, SymTab, R))
642 if (Error E = dumpCommonSection(Shdr, *S))
666 if (Error E = dumpCommonSection(Shdr, *S))
681 if (Error E = dumpCommonSection(Shdr, *S))
692 if (Error E = dumpCommonSection(Shdr, *S))
728 if (Error E = dumpCommonSection(Shdr, *S))
772 if (Error E = dumpCommonSection(Shdr, *S))
821 if (Error E = dumpCommonSection(Shdr, *S))
840 if (Error E = dumpCommonSection(Shdr, *S))
911 if (Error E = dumpCommonSection(Shdr, *S))
947 if (Error E = dumpCommonSection(Shdr, *S))
971 static Error elf2yaml(raw_ostream &Out, const object::ELFFile<ELFT> &Obj) {
981 return Error::success();
984 Error elf2yaml(raw_ostream &Out, const object::ObjectFile &Obj) {
tools/obj2yaml/macho2yaml.cpp 499 Error macho2yaml(raw_ostream &Out, const object::MachOObjectFile &Obj) {
510 return Error::success();
513 Error macho2yaml(raw_ostream &Out, const object::MachOUniversalBinary &Obj) {
543 return Error::success();
548 if (auto Err = macho2yaml(Out, *MachOObj)) {
555 if (auto Err = macho2yaml(Out, *MachOObj)) {
tools/obj2yaml/minidump2yaml.cpp 17 Error minidump2yaml(raw_ostream &Out, const object::MinidumpFile &Obj) {
23 return llvm::Error::success();
tools/obj2yaml/obj2yaml.cpp 20 static Error dumpObject(const ObjectFile &Obj) {
36 static Error dumpInput(StringRef File) {
52 return Error::success();
55 static void reportError(StringRef Input, Error Err) {
73 if (Error Err = dumpInput(InputFilename)) {
tools/obj2yaml/obj2yaml.h 24 llvm::Error elf2yaml(llvm::raw_ostream &Out,
28 llvm::Error minidump2yaml(llvm::raw_ostream &Out,
tools/opt/NewPMDriver.cpp 125 if (auto Err = PB.parsePassPipeline(PM, PipelineOpt)) {
300 if (auto Err = PB.parseAAPipeline(AA, AAPipeline)) {
326 if (auto Err =
tools/opt/opt.cpp 561 if (Error E = RemarksFileOrErr.takeError()) {
tools/polly/lib/Exchange/JSONExporter.cpp 713 if (Error E = ParseResult.takeError()) {
tools/sancov/sancov.cpp 195 static void failIfError(Error Err) {
779 Error Err = Error::success();
779 Error Err = Error::success();
unittests/ADT/FallibleIteratorTest.cpp 50 Error inc() {
54 return Error::success();
60 Error dec() {
64 return Error::success();
120 Error Err = Error::success();
120 Error Err = Error::success();
137 Error Err = Error::success();
137 Error Err = Error::success();
155 Error Err = Error::success();
155 Error Err = Error::success();
200 Error Err = Error::success();
200 Error Err = Error::success();
208 Error Err = Error::success();
208 Error Err = Error::success();
218 Error Err = Error::success();
218 Error Err = Error::success();
226 Error Err = Error::success();
226 Error Err = Error::success();
246 Error Err = Error::success();
246 Error Err = Error::success();
253 Error Err = Error::success();
253 Error Err = Error::success();
272 Error Err = Error::success();
272 Error Err = Error::success();
unittests/DebugInfo/CodeView/RandomAccessVisitorTest.cpp 66 virtual Error visitTypeBegin(CVType &CVR, TypeIndex Index) {
68 return Error::success();
70 virtual Error visitKnownRecord(CVType &CVR, ArrayRecord &AR) {
73 return Error::success();
unittests/DebugInfo/DWARF/DWARFDebugLineTest.cpp 27 : LineData("", true, 0), Recoverable(Error::success()),
30 Unrecoverable(Error::success()),
88 void recordRecoverable(Error Err) {
91 void recordUnrecoverable(Error Err) {
95 void checkError(ArrayRef<StringRef> ExpectedMsgs, Error Err) {
98 Error Remaining =
109 void checkError(StringRef ExpectedMsg, Error Err) {
137 Error Recoverable;
138 std::function<void(Error)> RecordRecoverable;
139 Error Unrecoverable;
140 std::function<void(Error)> RecordUnrecoverable;
268 Recoverable = Error::success();
281 Recoverable = Error::success();
288 Recoverable = Error::success();
629 Unrecoverable = Error::success();
unittests/DebugInfo/DWARF/DwarfGenerator.cpp 386 llvm::Error error = GenUP->init(TheTriple, DwarfVersion);
392 llvm::Error dwarfgen::Generator::init(Triple TheTriple, uint16_t V) {
475 return Error::success();
unittests/DebugInfo/DWARF/DwarfGenerator.h 268 llvm::Error init(Triple TheTriple, uint16_t DwarfVersion);
unittests/DebugInfo/GSYM/GSYMTest.cpp 30 void checkError(ArrayRef<std::string> ExpectedMsgs, Error Err) {
33 Error Remaining =
44 void checkError(std::string ExpectedMsg, Error Err) {
323 llvm::Error Err = Inline.encode(FW, BaseAddr);
355 llvm::Error Err = Inline.encode(FW, BaseAddr);
804 llvm::Error Err = LT.encode(FW, BaseAddr);
957 llvm::Error Err = H.encode(FW);
1014 llvm::Error Err = H.encode(FW);
1035 llvm::Error Err = H.encode(FW);
1058 llvm::Error Err = GC.encode(FW);
1084 llvm::Error finalizeErr = GC.finalize(OS);
1132 llvm::Error Err = GC.encode(FW);
1156 Error Err = GC.finalize(llvm::nulls());
1182 Error Err = GC.finalize(llvm::nulls());
1208 Error Err = GC.finalize(llvm::nulls());
1234 Error Err = GC.finalize(llvm::nulls());
1277 Error FinalizeErr = GC.finalize(llvm::nulls());
1282 llvm::Error Err = GC.encode(FW);
unittests/DebugInfo/MSF/MappedBlockStreamTest.cpp 39 Error readBytes(uint32_t Offset, uint32_t Size,
41 if (auto EC = checkOffsetForRead(Offset, Size))
44 return Error::success();
47 Error readLongestContiguousChunk(uint32_t Offset,
49 if (auto EC = checkOffsetForRead(Offset, 1))
52 return Error::success();
57 Error writeBytes(uint32_t Offset, ArrayRef<uint8_t> SrcData) override {
58 if (auto EC = checkOffsetForWrite(Offset, SrcData.size()))
61 return Error::success();
63 Error commit() override { return Error::success(); }
63 Error commit() override { return Error::success(); }
unittests/DebugInfo/PDB/NativeSymbolReuseTest.cpp 32 Error E = pdb::loadDataForPDB(PDB_ReaderType::Native, InputsDir, S);
59 Error E = pdb::loadDataForPDB(PDB_ReaderType::Native, InputsDir, S);
101 Error E = pdb::loadDataForPDB(PDB_ReaderType::Native, InputsDir, S);
unittests/ExecutionEngine/JITLink/JITLinkTestCommon.cpp 23 Error Err = Error::success();
23 Error Err = Error::success();
41 Error &Err)
45 if (auto Err2 = initializeTripleSpecifics(TT)) {
52 Error JITLinkTestCommon::TestResources::initializeTripleSpecifics(Triple &TT) {
82 return Error::success();
144 void JITLinkTestCommon::TestJITLinkContext::notifyFailed(Error Err) {
188 Error JITLinkTestCommon::TestJITLinkContext::modifyPassConfig(
193 return Error::success();
195 return Error::success();
unittests/ExecutionEngine/JITLink/JITLinkTestCommon.h 53 bool LargeCodeModel, MCTargetOptions Options, Error &Err);
55 Error initializeTripleSpecifics(Triple &TT);
104 void notifyFailed(Error Err) override;
115 Error modifyPassConfig(const Triple &TT,
unittests/ExecutionEngine/Orc/CoreAPIsTest.cpp 143 auto Err = JD.remove({Foo, Bar, Baz, Qux});
152 auto Err = JD.remove({Foo, Bar, Baz});
164 auto Err = JD.remove({Foo, Bar, Baz});
1228 auto Err = JD.define(MU2);
unittests/ExecutionEngine/Orc/LazyCallThroughAndReexportsTest.cpp 58 return Error::success();
unittests/ExecutionEngine/Orc/LegacyCompileOnDemandLayerTest.cpp 34 Error createStub(StringRef StubName, JITTargetAddress InitAddr,
39 Error createStubs(const StubInitsMap &StubInits) override {
51 Error updatePointer(StringRef Name, JITTargetAddress NewAddr) override {
unittests/ExecutionEngine/Orc/ObjectTransformLayerTest.cpp 49 template <typename ObjPtrT> llvm::Error addObject(VModuleKey K, ObjPtrT Obj) {
53 return llvm::Error::success();
66 llvm::Error removeObject(VModuleKey K) {
69 return llvm::Error::success();
121 llvm::Error emitAndFinalize(VModuleKey K) {
124 return llvm::Error::success();
unittests/ExecutionEngine/Orc/OrcTestCommon.h 201 using RemoveModuleSignature = Error(ModuleHandleT H);
207 using EmitAndFinalizeSignature = Error(ModuleHandleT H);
222 Error removeModule(ModuleHandleT H) {
241 Error emitAndFinaliez(ModuleHandleT H) {
unittests/ExecutionEngine/Orc/QueueChannel.h 41 using ErrorInjector = std::function<Error()>;
44 : ReadError([]() { return Error::success(); }),
45 WriteError([]() { return Error::success(); }) {}
54 Error checkReadError() { return ReadError(); }
55 Error checkWriteError() { return WriteError(); }
70 std::function<Error()> ReadError, WriteError;
85 Error startSendMessage(const FunctionIdT &FnId, const SequenceIdT &SeqNo) {
90 Error endSendMessage() {
97 Error startReceiveMessage(FunctionIdT &FnId, SequenceNumberT &SeqNo) {
102 Error endReceiveMessage() {
108 Error readBytes(char *Dst, unsigned Size) override {
112 Error Err = InQueue->checkReadError();
125 return Error::success();
128 Error appendBytes(const char *Src, unsigned Size) override {
131 if (Error Err = OutQueue->checkWriteError())
137 return Error::success();
140 Error send() override {
142 return Error::success();
unittests/ExecutionEngine/Orc/RPCUtilsTest.cpp 34 static Error serialize(QueueChannel&, const RPCFoo&) {
35 return Error::success();
38 static Error deserialize(QueueChannel&, RPCFoo&) {
39 return Error::success();
79 SerializationTraits<ChannelT, Error>::
88 if (auto Err = deserializeSeq(C, Val))
91 return Error::success();
104 static Error serialize(QueueChannel&, const RPCBar&) {
105 return Error::success();
108 static Error deserialize(QueueChannel&, RPCBar&) {
109 return Error::success();
148 class ErrorFunc : public Function<ErrorFunc, Error()> {
190 auto Err = Server.handleOne();
196 auto Err = Server.handleOne();
203 auto Err = Client.callAsync<DummyRPCAPI::VoidBool>(
206 return Error::success();
213 auto Err = Client.handleOne();
245 auto Err = Server.handleOne();
251 auto Err = Server.handleOne();
257 auto Err = Client.callAsync<DummyRPCAPI::IntInt>(
262 return Error::success();
269 auto Err = Client.handleOne();
286 cantFail(SendResult(Error::success()));
287 return Error::success();
292 auto Err = Server.handleOne();
298 auto Err = Server.handleOne();
304 auto Err = Client.callAsync<DummyRPCAPI::VoidBool>(
307 return Error::success();
314 auto Err = Client.handleOne();
336 auto Err = Server.handleOne();
342 auto Err = Server.handleOne();
348 auto Err = Client.callAsync<DummyRPCAPI::IntInt>(
353 return Error::success();
360 auto Err = Client.handleOne();
374 Error handler(std::function<Error(Expected<int32_t>)> SendResult,
374 Error handler(std::function<Error(Expected<int32_t>)> SendResult,
387 auto Err = Server.handleOne();
393 auto Err = Server.handleOne();
399 auto Err = Client.callAsync<DummyRPCAPI::IntInt>(
404 return Error::success();
411 auto Err = Client.handleOne();
432 auto Err = Server.handleOne();
439 auto Err = Client.callB<DummyRPCAPI::VoidString>(std::string("hello"));
445 auto Err = Client.callB<DummyRPCAPI::VoidString>(StringRef("hello"));
451 auto Err = Client.callB<DummyRPCAPI::VoidString>("hello");
487 return Error::success();
492 auto Err = Server.handleOne();
498 auto Err = Server.handleOne();
508 auto Err = Client.callAsync<DummyRPCAPI::AllTheTypes>(
511 return Error::success();
523 auto Err = Client.handleOne();
541 auto Err = Server.handleOne();
547 auto Err = Server.handleOne();
554 auto Err = Client.callAsync<DummyRPCAPI::CustomType>(
558 return Error::success();
565 auto Err = Client.handleOne();
584 auto Err = Server.handleOne();
590 auto Err = Server.handleOne();
597 auto Err = Client.callAsync<DummyRPCAPI::CustomType>(
601 return Error::success();
608 auto Err = Client.handleOne();
626 return Error::success();
637 return Error::success();
704 return Error::success();
734 auto Err = ValOrErr.takeError();
763 auto Err = Server.handleOne();
773 auto Err = PCG.call(
778 return Error::success();
784 auto Err = PCG.call(
789 return Error::success();
795 auto Err = PCG.call(
800 return Error::success();
807 auto Err = Client.handleOne();
844 auto Err = Server.handleOne();
850 auto Err = DummyCalls1::negotiate(Client);
855 auto Err = DummyCalls3::negotiate(Client);
860 auto Err = DummyCallsAll::negotiate(Client);
unittests/ExecutionEngine/Orc/RemoteObjectLayerTest.cpp 47 Error removeObject(ObjHandleT H) {
49 return Error::success();
58 else if (auto Err = Sym.takeError())
73 Error emitAndFinalize(ObjHandleT H) {
75 return Error::success();
315 auto Err = Client.removeObject(H);
389 auto Err = Sym2.takeError();
400 auto Err = Sym3.takeError();
476 auto Err = Sym2.takeError();
527 auto Err = Client.emitAndFinalize(H);
577 auto Err = Client.emitAndFinalize(H);
unittests/ProfileData/CoverageMappingTest.cpp 26 ErrorEquals(coveragemap_error Expected, Error E) {
92 Error readNextRecord(CoverageMappingRecord &Record) override {
99 return Error::success();
247 Error loadCoverageMapping(bool EmitFilenames = true) {
254 return Error::success();
308 static const auto Err = [](Error E) { FAIL(); };
unittests/ProfileData/InstrProfTest.cpp 24 ErrorEquals(instrprof_error Expected, Error E) {
68 static const auto Err = [](Error E) {
134 Error E1 = Reader->getFunctionCounts("foo", 0x5678, Counts);
137 Error E2 = Reader->getFunctionCounts("bar", 0x1234, Counts);
unittests/Remarks/BitstreamRemarksParsingTest.cpp 41 Error E = Remark.takeError();
71 Error BSE = BSRemark.takeError();
220 Error E = MaybeRemark.takeError();
unittests/Remarks/YAMLRemarksParsingTest.cpp 27 Error E = Remark.takeError();
43 Error E = Remark.takeError();
462 Error E = MaybeRemark.takeError();
634 Error E = MaybeRemark.takeError();
unittests/Support/BinaryStreamTest.cpp 34 Error readBytes(uint32_t Offset, uint32_t Size,
36 if (auto EC = checkOffsetForRead(Offset, Size))
42 return Error::success();
50 return Error::success();
53 Error readLongestContiguousChunk(uint32_t Offset,
55 if (auto EC = checkOffsetForRead(Offset, 1))
59 return Error::success();
64 Error writeBytes(uint32_t Offset, ArrayRef<uint8_t> SrcData) override {
65 if (auto EC = checkOffsetForWrite(Offset, SrcData.size()))
68 return Error::success();
75 return Error::success();
81 return Error::success();
83 Error commit() override { return Error::success(); }
83 Error commit() override { return Error::success(); }
469 Error operator()(BinaryStreamRef Stream, uint32_t &Len, StringRef &Item) {
479 if (auto EC = Stream.readBytes(0, Len, Bytes))
484 return Error::success();
unittests/Support/ErrorTest.cpp 88 static Error handleCustomError(const CustomError &CE) {
89 return Error::success();
94 static Error handleCustomErrorUP(std::unique_ptr<CustomError> CE) {
95 return Error::success();
103 Error E = Error::success();
103 Error E = Error::success();
117 void errAsOutParamHelper(Error &Err) {
120 Err = Error::success();
128 Error E = Error::success();
128 Error E = Error::success();
148 Error E = make_error<CustomError>(42);
160 Error E = make_error<CustomError>(1);
161 Error F = make_error<CustomSubError>(1, 2);
162 Error G = Error::success();
162 Error G = Error::success();
204 [](const CustomError &CE) mutable -> Error { return Error::success(); });
210 [](CustomError &CE) -> Error { return Error::success(); });
215 [](CustomError &CE) mutable -> Error { return Error::success(); });
221 [](std::unique_ptr<CustomError> CE) -> Error { return Error::success(); });
228 [](std::unique_ptr<CustomError> CE) mutable -> Error { return Error::success(); });
301 Error E =
372 Error E = Error::success();
372 Error E = Error::success();
377 Error E = make_error<CustomError>(7);
424 Error E = handleErrors(
482 ExitOnErr(Error::success());
502 cantFail(Error::success());
589 Error E = A.takeError();
667 auto Err = ValOrErr.takeError();
730 Error E1 = make_error<CustomError>(0);
733 Error E2 = make_error<CustomError>(0);
738 Error E3 = joinErrors(make_error<CustomError>(0), make_error<CustomError>(1));
747 Error OK = Error::success();
747 Error OK = Error::success();
755 Error E1 = make_error<CustomError>(0);
881 Error E1 = make_error<CustomError>(1);
882 Error FE1 = createFileError("file.bin", std::move(E1));
885 Error E2 = make_error<CustomError>(2);
886 Error FE2 = createFileError("file.bin", std::move(E2));
891 Error E3 = make_error<CustomError>(3);
892 Error FE3 = createFileError("file.bin", std::move(E3));
893 auto E31 = handleErrors(std::move(FE3), [](std::unique_ptr<FileError> F) {
900 Error FE4 =
959 auto E1 = make_error<TestDebugError>(test_error_code::error_1);
962 auto E2 = make_error<TestDebugError>(test_error_code::error_1,
967 auto E3 = make_error<TestDebugError>(test_error_code::error_2);
972 auto E4 = joinErrors(make_error<TestDebugError>(test_error_code::error_1,
unittests/Support/FileCheckTest.cpp 47 Error Err) {
56 static void expectUndefError(const Twine &ExpectedUndefVarName, Error Err) {
unittests/Support/FileUtilitiesTest.cpp 44 llvm::Error Err = llvm::writeFileAtomically(TempUniqTestFileModel, FinalTestfilePath, TestfileContent);
unittests/Support/FormatVariadicTest.cpp 685 auto E1 = make_error<StringError>("X", inconvertibleErrorCode());
unittests/Support/SymbolRemappingReaderTest.cpp 23 Error E = Reader.read(*Buffer);
30 Error E = Reader.read(*Buffer);
unittests/TextAPI/TextStubV1Tests.cpp 210 auto Result = TextAPIWriter::writeToStream(OS, File);
unittests/TextAPI/TextStubV2Tests.cpp 231 auto Result = TextAPIWriter::writeToStream(OS, File);
unittests/TextAPI/TextStubV3Tests.cpp 187 auto Result = TextAPIWriter::writeToStream(OS, File);
unittests/TextAPI/TextStubV4Tests.cpp 232 auto Result = TextAPIWriter::writeToStream(OS, File);
unittests/XRay/FDRProducerConsumerTest.cpp 146 if (auto E = C.consume(std::move(R.get())))
187 if (auto E = C.consume(std::move(R.get())))
unittests/tools/llvm-cfi-verify/FileAnalysis.cpp 58 Error initialiseDisassemblyMembers() {
70 if (auto Err = Analysis.initialiseDisassemblyMembers()) {
unittests/tools/llvm-cfi-verify/GraphBuilder.cpp 120 Error initialiseDisassemblyMembers() {
130 if (auto Err = Analysis.initialiseDisassemblyMembers()) {
unittests/tools/llvm-exegesis/ClusteringTest.cpp 76 auto Error =
88 auto Error =
unittests/tools/llvm-exegesis/X86/SnippetFileTest.cpp 89 auto Error = TestCommon(R"(
99 auto Error = TestCommon(R"(
109 auto Error = TestCommon(R"(
unittests/tools/llvm-exegesis/X86/SnippetGeneratorTest.cpp 156 auto Error = Generator.generateCodeTemplates(Instr, AllRegisters).takeError();
379 auto Error =
usr/include/c++/7.4.0/bits/alloc_traits.h 387 using allocator_type = allocator<_Tp>;
389 using value_type = _Tp;
392 using pointer = _Tp*;
395 using const_pointer = const _Tp*;
474 construct(allocator_type& __a, _Up* __p, _Args&&... __args)
474 construct(allocator_type& __a, _Up* __p, _Args&&... __args)
475 { __a.construct(__p, std::forward<_Args>(__args)...); }
486 destroy(allocator_type& __a, _Up* __p)
usr/include/c++/7.4.0/bits/allocator.h 108 class allocator: public __allocator_base<_Tp>
113 typedef _Tp* pointer;
114 typedef const _Tp* const_pointer;
115 typedef _Tp& reference;
116 typedef const _Tp& const_reference;
117 typedef _Tp value_type;
137 allocator(const allocator<_Tp1>&) throw() { }
usr/include/c++/7.4.0/bits/invoke.h 73 return ((*std::forward<_Tp>(__t)).*__f)(std::forward<_Args>(__args)...);
96 std::forward<_Args>(__args)...);
usr/include/c++/7.4.0/bits/move.h 46 inline _GLIBCXX_CONSTEXPR _Tp*
47 __addressof(_Tp& __r) _GLIBCXX_NOEXCEPT
72 constexpr _Tp&&
73 forward(typename std::remove_reference<_Tp>::type& __t) noexcept
83 constexpr _Tp&&
84 forward(typename std::remove_reference<_Tp>::type&& __t) noexcept
97 constexpr typename std::remove_reference<_Tp>::type&&
98 move(_Tp&& __t) noexcept
104 : public __and_<__not_<is_nothrow_move_constructible<_Tp>>,
105 is_copy_constructible<_Tp>>::type { };
136 inline _GLIBCXX17_CONSTEXPR _Tp*
137 addressof(_Tp& __r) noexcept
143 const _Tp* addressof(const _Tp&&) = delete;
143 const _Tp* addressof(const _Tp&&) = delete;
usr/include/c++/7.4.0/bits/std_function.h 62 : std::unary_function<_T1, _Res> { };
62 : std::unary_function<_T1, _Res> { };
67 : std::binary_function<_T1, _T2, _Res> { };
67 : std::binary_function<_T1, _T2, _Res> { };
298 static _Res
299 _M_invoke(const _Any_data& __functor, _ArgTypes&&... __args)
302 std::forward<_ArgTypes>(__args)...);
314 _M_invoke(const _Any_data& __functor, _ArgTypes&&... __args)
317 std::forward<_ArgTypes>(__args)...);
390 : public _Maybe_unary_or_binary_function<_Res, _ArgTypes...>,
390 : public _Maybe_unary_or_binary_function<_Res, _ArgTypes...>,
395 struct _Callable : __check_func_return_type<_Res2, _Res> { };
395 struct _Callable : __check_func_return_type<_Res2, _Res> { };
406 typedef _Res result_type;
595 _Res operator()(_ArgTypes... __args) const;
595 _Res operator()(_ArgTypes... __args) const;
628 using _Invoker_type = _Res (*)(const _Any_data&, _ArgTypes&&...);
628 using _Invoker_type = _Res (*)(const _Any_data&, _ArgTypes&&...);
689 typedef _Function_handler<_Res(_ArgTypes...), _Functor> _My_handler;
689 typedef _Function_handler<_Res(_ArgTypes...), _Functor> _My_handler;
706 return _M_invoker(_M_functor, std::forward<_ArgTypes>(__args)...);
usr/include/c++/7.4.0/bits/stl_construct.h 74 _Construct(_T1* __p, _Args&&... __args)
74 _Construct(_T1* __p, _Args&&... __args)
75 { ::new(static_cast<void*>(__p)) _T1(std::forward<_Args>(__args)...); }
75 { ::new(static_cast<void*>(__p)) _T1(std::forward<_Args>(__args)...); }
97 _Destroy(_Tp* __pointer)
204 allocator<_Tp>&)
usr/include/c++/7.4.0/bits/stl_function.h 108 typedef _Arg argument_type;
111 typedef _Result result_type;
124 typedef _Arg2 second_argument_type;
127 typedef _Result result_type;
usr/include/c++/7.4.0/bits/stl_iterator.h 1224 __make_move_if_noexcept_iterator(_Tp* __i)
usr/include/c++/7.4.0/bits/stl_iterator_base_types.h 181 typedef _Tp value_type;
183 typedef _Tp* pointer;
184 typedef _Tp& reference;
192 typedef _Tp value_type;
194 typedef const _Tp* pointer;
195 typedef const _Tp& reference;
usr/include/c++/7.4.0/bits/stl_pair.h 100 return __and_<is_constructible<_T1, const _U1&>,
100 return __and_<is_constructible<_T1, const _U1&>,
101 is_constructible<_T2, const _U2&>>::value;
101 is_constructible<_T2, const _U2&>>::value;
107 return __and_<is_convertible<const _U1&, _T1>,
107 return __and_<is_convertible<const _U1&, _T1>,
108 is_convertible<const _U2&, _T2>>::value;
108 is_convertible<const _U2&, _T2>>::value;
114 return __and_<is_constructible<_T1, _U1&&>,
114 return __and_<is_constructible<_T1, _U1&&>,
115 is_constructible<_T2, _U2&&>>::value;
115 is_constructible<_T2, _U2&&>>::value;
121 return __and_<is_convertible<_U1&&, _T1>,
121 return __and_<is_convertible<_U1&&, _T1>,
122 is_convertible<_U2&&, _T2>>::value;
122 is_convertible<_U2&&, _T2>>::value;
128 using __do_converts = __and_<is_convertible<const _U1&, _T1>,
128 using __do_converts = __and_<is_convertible<const _U1&, _T1>,
129 is_convertible<_U2&&, _T2>>;
129 is_convertible<_U2&&, _T2>>;
133 return __and_<is_constructible<_T1, const _U1&>,
133 return __and_<is_constructible<_T1, const _U1&>,
134 is_constructible<_T2, _U2&&>,
134 is_constructible<_T2, _U2&&>,
142 using __do_converts = __and_<is_convertible<_U1&&, _T1>,
142 using __do_converts = __and_<is_convertible<_U1&&, _T1>,
143 is_convertible<const _U2&, _T2>>;
143 is_convertible<const _U2&, _T2>>;
147 return __and_<is_constructible<_T1, _U1&&>,
147 return __and_<is_constructible<_T1, _U1&&>,
148 is_constructible<_T2, const _U2&&>,
148 is_constructible<_T2, const _U2&&>,
209 : private __pair_base<_T1, _T2>
209 : private __pair_base<_T1, _T2>
211 typedef _T1 first_type; /// @c first_type is the first bound type
212 typedef _T2 second_type; /// @c second_type is the second bound type
214 _T1 first; /// @c first is a copy of the first object
215 _T2 second; /// @c second is a copy of the second object
252 using _PCCP = _PCC<true, _T1, _T2>;
252 using _PCCP = _PCC<true, _T1, _T2>;
260 constexpr pair(const _T1& __a, const _T2& __b)
260 constexpr pair(const _T1& __a, const _T2& __b)
269 explicit constexpr pair(const _T1& __a, const _T2& __b)
269 explicit constexpr pair(const _T1& __a, const _T2& __b)
283 _T1, _T2>;
283 _T1, _T2>;
311 constexpr pair(_U1&& __x, const _T2& __y)
311 constexpr pair(_U1&& __x, const _T2& __y)
312 : first(std::forward<_U1>(__x)), second(__y) { }
318 explicit constexpr pair(_U1&& __x, const _T2& __y)
325 constexpr pair(const _T1& __x, _U2&& __y)
325 constexpr pair(const _T1& __x, _U2&& __y)
332 explicit pair(const _T1& __x, _U2&& __y)
341 constexpr pair(_U1&& __x, _U2&& __y)
341 constexpr pair(_U1&& __x, _U2&& __y)
342 : first(std::forward<_U1>(__x)), second(std::forward<_U2>(__y)) { }
342 : first(std::forward<_U1>(__x)), second(std::forward<_U2>(__y)) { }
360 constexpr pair(pair<_U1, _U2>&& __p)
362 second(std::forward<_U2>(__p.second)) { }
379 __and_<is_copy_assignable<_T1>,
380 is_copy_assignable<_T2>>::value,
390 __and_<is_move_assignable<_T1>,
391 is_move_assignable<_T2>>::value,
413 typename enable_if<__and_<is_assignable<_T1&, _U1&&>,
413 typename enable_if<__and_<is_assignable<_T1&, _U1&&>,
416 operator=(pair<_U1, _U2>&& __p)
523 typename __decay_and_strip<_T2>::__type>
524 make_pair(_T1&& __x, _T2&& __y)
527 typedef typename __decay_and_strip<_T2>::__type __ds_type2;
529 return __pair_type(std::forward<_T1>(__x), std::forward<_T2>(__y));
usr/include/c++/7.4.0/bits/stl_uninitialized.h 288 _ForwardIterator __result, allocator<_Tp>&)
usr/include/c++/7.4.0/bits/stl_vector.h 77 rebind<_Tp>::other _Tp_alloc_type;
216 class vector : protected _Vector_base<_Tp, _Alloc>
227 typedef _Vector_base<_Tp, _Alloc> _Base;
232 typedef _Tp value_type;
919 _Tp*
923 const _Tp*
962 emplace_back(_Args&&... __args);
1483 _M_realloc_insert(iterator __position, _Args&&... __args);
usr/include/c++/7.4.0/bits/unique_ptr.h 68 default_delete(const default_delete<_Up>&) noexcept { }
72 operator()(_Tp* __ptr) const
74 static_assert(!is_void<_Tp>::value,
76 static_assert(sizeof(_Tp)>0,
122 using type = _Up*;
137 using pointer = typename _Ptr<_Tp, _Dp>::type;
161 typename __uniq_ptr_impl<_Tp, _Up>::_DeleterConstraint::type;
163 __uniq_ptr_impl<_Tp, _Dp> _M_t;
166 using pointer = typename __uniq_ptr_impl<_Tp, _Dp>::pointer;
167 using element_type = _Tp;
252 unique_ptr(unique_ptr<_Up, _Ep>&& __u) noexcept
297 __safe_conversion_up<_Up, _Ep>,
301 operator=(unique_ptr<_Up, _Ep>&& __u) noexcept
811 { typedef unique_ptr<_Tp> __single_object; };
823 inline typename _MakeUniq<_Tp>::__single_object
824 make_unique(_Args&&... __args)
825 { return unique_ptr<_Tp>(new _Tp(std::forward<_Args>(__args)...)); }
825 { return unique_ptr<_Tp>(new _Tp(std::forward<_Args>(__args)...)); }
usr/include/c++/7.4.0/bits/vector.tcc 101 std::forward<_Args>(__args)...);
105 _M_realloc_insert(end(), std::forward<_Args>(__args)...);
418 std::forward<_Args>(__args)...);
usr/include/c++/7.4.0/ext/alloc_traits.h 117 { typedef typename _Base_type::template rebind_alloc<_Tp> other; };
usr/include/c++/7.4.0/ext/new_allocator.h 63 typedef _Tp* pointer;
64 typedef const _Tp* const_pointer;
65 typedef _Tp& reference;
66 typedef const _Tp& const_reference;
67 typedef _Tp value_type;
111 return static_cast<_Tp*>(::operator new(__n * sizeof(_Tp)));
130 { return size_t(-1) / sizeof(_Tp); }
135 construct(_Up* __p, _Args&&... __args)
135 construct(_Up* __p, _Args&&... __args)
136 { ::new((void *)__p) _Up(std::forward<_Args>(__args)...); }
136 { ::new((void *)__p) _Up(std::forward<_Args>(__args)...); }
140 destroy(_Up* __p) { __p->~_Up(); }
usr/include/c++/7.4.0/functional 110 = _Maybe_unary_or_binary_function<_Res, _Class*, _ArgTypes...>;
411 _Safe_tuple_element_t<(is_placeholder<_Arg>::value - 1), _Tuple>&&
411 _Safe_tuple_element_t<(is_placeholder<_Arg>::value - 1), _Tuple>&&
547 operator()(_Args&&... __args)
550 std::forward_as_tuple(std::forward<_Args>(__args)...),
558 operator()(_Args&&... __args) const
576 operator()(_Args&&... __args) volatile
588 operator()(_Args&&... __args) const volatile
usr/include/c++/7.4.0/tuple 125 constexpr _Head_base(const _Head& __h)
132 constexpr _Head_base(_UHead&& __h)
133 : _M_head_impl(std::forward<_UHead>(__h)) { }
159 static constexpr _Head&
162 static constexpr const _Head&
350 static constexpr _Head&
353 static constexpr const _Head&
360 constexpr _Tuple_impl(const _Head& __head)
365 constexpr _Tuple_impl(_UHead&& __head)
366 : _Base(std::forward<_UHead>(__head)) { }
390 const _Head& __head)
473 return __and_<is_constructible<_Elements, const _UElements&>...>::value;
479 return __and_<is_convertible<const _UElements&, _Elements>...>::value;
485 return __and_<is_constructible<_Elements, _UElements&&>...>::value;
491 return __and_<is_convertible<_UElements&&, _Elements>...>::value;
510 typename remove_reference<_UElements...>::type
608 constexpr tuple(const _Elements&... __elements)
619 explicit constexpr tuple(const _Elements&... __elements)
646 constexpr tuple(_UElements&&... __elements)
647 : _Inherited(std::forward<_UElements>(__elements)...) { }
730 const _Elements&... __elements)
741 const _Elements&... __elements)
1288 typedef _Head type;
1302 constexpr _Head&
1307 constexpr const _Head&
1313 constexpr __tuple_element_t<__i, tuple<_Elements...>>&
1319 constexpr const __tuple_element_t<__i, tuple<_Elements...>>&
1325 constexpr __tuple_element_t<__i, tuple<_Elements...>>&&
1329 return std::forward<__element_type&&>(std::get<__i>(__t));
1458 constexpr tuple<_Elements&&...>
1459 forward_as_tuple(_Elements&&... __args) noexcept
1460 { return tuple<_Elements&&...>(std::forward<_Elements>(__args)...); }
usr/include/c++/7.4.0/type_traits 194 { typedef _Tp type; };
215 : public __is_void_helper<typename remove_cv<_Tp>::type>::type
326 : public __is_integral_helper<typename remove_cv<_Tp>::type>::type
354 : public __is_floating_point_helper<typename remove_cv<_Tp>::type>::type
381 : public __is_pointer_helper<typename remove_cv<_Tp>::type>::type
417 typename remove_cv<_Tp>::type>::type
432 typename remove_cv<_Tp>::type>::type
567 : public __is_null_pointer_helper<typename remove_cv<_Tp>::type>::type
581 : public __or_<is_lvalue_reference<_Tp>,
582 is_rvalue_reference<_Tp>>::type
588 : public __or_<is_integral<_Tp>, is_floating_point<_Tp>>::type
588 : public __or_<is_integral<_Tp>, is_floating_point<_Tp>>::type
601 : public __not_<__or_<is_function<_Tp>, is_reference<_Tp>,
601 : public __not_<__or_<is_function<_Tp>, is_reference<_Tp>,
602 is_void<_Tp>>>::type
611 : public __or_<is_arithmetic<_Tp>, is_enum<_Tp>, is_pointer<_Tp>,
611 : public __or_<is_arithmetic<_Tp>, is_enum<_Tp>, is_pointer<_Tp>,
611 : public __or_<is_arithmetic<_Tp>, is_enum<_Tp>, is_pointer<_Tp>,
612 is_member_pointer<_Tp>, is_null_pointer<_Tp>>::type
612 is_member_pointer<_Tp>, is_null_pointer<_Tp>>::type
631 : public __is_member_pointer_helper<typename remove_cv<_Tp>::type>::type
638 : public __or_<is_object<_Tp>, is_reference<_Tp>>::type
638 : public __or_<is_object<_Tp>, is_reference<_Tp>>::type
762 typename add_rvalue_reference<_Tp>::type declval() noexcept;
777 : public __and_<is_array<_Tp>, __not_<extent<_Tp>>>
777 : public __and_<is_array<_Tp>, __not_<extent<_Tp>>>
798 typedef decltype(__test<_Tp>(0)) type;
811 remove_all_extents<_Tp>::type>::type
825 : public __is_destructible_safe<_Tp>::type
984 typedef decltype(__test<_Tp, _Arg>(0)) type;
989 : public __and_<is_destructible<_Tp>,
990 __is_direct_constructible_impl<_Tp, _Arg>>
1072 __is_direct_constructible_ref_cast<_Tp, _Arg>,
1073 __is_direct_constructible_new_safe<_Tp, _Arg>
1079 : public __is_direct_constructible_new<_Tp, _Arg>::type
1119 : public __is_direct_constructible<_Tp, _Arg>
1130 : public __is_constructible_impl<_Tp, _Args...>::type
1142 : public is_constructible<_Tp, const _Tp&>
1142 : public is_constructible<_Tp, const _Tp&>
1148 : public __is_copy_constructible_impl<_Tp>
1160 : public is_constructible<_Tp, _Tp&&>
1160 : public is_constructible<_Tp, _Tp&&>
1166 : public __is_move_constructible_impl<_Tp>
1215 : public __and_<is_constructible<_Tp, _Args...>,
1216 __is_nt_constructible_impl<_Tp, _Args...>>
1246 : public is_nothrow_constructible<_Tp, _Tp&&>
1246 : public is_nothrow_constructible<_Tp, _Tp&&>
1252 : public __is_nothrow_move_constructible_impl<_Tp>
1286 : public is_assignable<_Tp&, const _Tp&>
1286 : public is_assignable<_Tp&, const _Tp&>
1292 : public __is_copy_assignable_impl<_Tp>
1304 : public is_assignable<_Tp&, _Tp&&>
1304 : public is_assignable<_Tp&, _Tp&&>
1310 : public __is_move_assignable_impl<_Tp>
1526 static void __test_aux(_To1);
1538 typedef decltype(__test<_From, _To>(0)) type;
1538 typedef decltype(__test<_From, _To>(0)) type;
1545 : public __is_convertible_helper<_From, _To>::type
1545 : public __is_convertible_helper<_From, _To>::type
1554 { typedef _Tp type; };
1563 { typedef _Tp type; };
1574 remove_const<typename remove_volatile<_Tp>::type>::type type;
1629 { typedef _Tp type; };
1633 { typedef _Tp type; };
1637 { typedef _Tp type; };
1645 { typedef _Tp& type; };
1650 : public __add_lvalue_reference_helper<_Tp>
1659 { typedef _Tp&& type; };
1664 : public __add_rvalue_reference_helper<_Tp>
1955 { typedef _Tp type; };
2104 { typedef typename remove_cv<_Up>::type __type; };
2118 typedef typename remove_reference<_Tp>::type __remove_type;
2131 typedef _Tp __type;
2144 typename decay<_Tp>::type>::__type __type;
2157 { typedef _Tp type; };
2277 struct __result_of_success : __success_type<_Tp>
2304 ((*std::declval<_Tp1>()).*std::declval<_Fp>())(std::declval<_Args>()...)
2315 typedef decltype(_S_test<_MemPtr, _Arg, _Args...>(0)) type;
2427 static __result_of_success<decltype(
2428 std::declval<_Fn>()(std::declval<_Args>()...)
2439 typedef decltype(_S_test<_Functor, _ArgTypes...>(0)) type;
2452 _Functor, _ArgTypes...
2458 : public __invoke_result<_Functor, _ArgTypes...>
2783 std::declval<_Args>()...));
utils/TableGen/GlobalISelEmitter.cpp 299 static Error failedImport(const Twine &Reason) {
303 static Error isTrivialOperatorNode(const TreePatternNode *N) {
369 return Error::success();
920 Error defineComplexSubOperand(StringRef SymbolicName, Record *ComplexPattern,
930 return Error::success();
1524 Error addTypeCheckPredicate(const TypeSetByHwMode &VTy,
1588 Error OperandMatcher::addTypeCheckPredicate(const TypeSetByHwMode &VTy,
1595 return Error::success();
1609 return Error::success();
3275 Error importRulePredicates(RuleMatcher &M, ArrayRef<Predicate> Predicates);
3280 Error importComplexPatternOperandMatcher(OperandMatcher &OM, Record *R,
3282 Error importChildMatcher(RuleMatcher &Rule, InstructionMatcher &InsnMatcher,
3306 Error importDefaultOperandRenderers(action_iterator InsertPt, RuleMatcher &M,
3309 Error
3451 Error
3461 return Error::success();
3498 if (auto Error = OM.addTypeCheckPredicate(VTy, false /* OperandIsAPointer */))
3747 if (auto Error =
3757 Error GlobalISelEmitter::importComplexPatternOperandMatcher(
3766 return Error::success();
3787 Error GlobalISelEmitter::importChildMatcher(RuleMatcher &Rule,
3801 return Error::success();
3813 return Error::success();
3817 return Error::success();
3822 if (auto Error =
3835 if (auto Error = importComplexPatternOperandMatcher(
3842 if (auto Error = Rule.defineComplexSubOperand(SubOperand->getName(),
3849 return Error::success();
3865 if (auto Error = InsnMatcherOrError.takeError())
3868 return Error::success();
3877 return Error::success();
3889 return Error::success();
3903 return Error::success();
3910 return Error::success();
3999 if (auto Error = InsertPtOrError.takeError())
4078 if (auto Error = InsertPtOrError.takeError())
4097 if (auto Error = importExplicitUseRenderers(InsertPt, M, DstMIBuilder, Dst)
4112 if (auto Error = InsertPtOrError.takeError())
4123 if (auto Error = InsertPtOrError.takeError())
4295 if (auto Error = InsertPtOrError.takeError())
4325 if (auto Error = importDefaultOperandRenderers(
4334 if (auto Error = InsertPtOrError.takeError())
4350 Error GlobalISelEmitter::importDefaultOperandRenderers(
4395 return Error::success();
4398 Error GlobalISelEmitter::importImplicitDefRenderers(
4403 return Error::success();
4535 if (auto Error = importRulePredicates(M, P.getPredicates()))
4543 if (auto Err = isTrivialOperatorNode(Dst))
4546 if (auto Err = isTrivialOperatorNode(Src))
4575 if (auto Error = InsnMatcherOrError.takeError())
4693 if (auto Error = DstMIBuilderOrError.takeError())
4699 if (auto Error = importImplicitDefRenderers(DstMIBuilder, P.getDstRegs()))
5031 if (auto Err = MatcherOrErr.takeError()) {
utils/unittest/googlemock/include/gmock/gmock-actions.h 507 explicit ByMoveWrapper(T value) : payload(internal::move(value)) {}
508 T payload;
1096 internal::ByMoveWrapper<R> ByMove(R x) {
1096 internal::ByMoveWrapper<R> ByMove(R x) {
utils/unittest/googletest/include/gtest/gtest-message.h 116 inline Message& operator <<(const T& val) {
utils/unittest/googletest/include/gtest/internal/custom/raw-ostream.h 35 auto printable(const T &V) -> decltype(StreamSwitch<T>::printable(V)) {
35 auto printable(const T &V) -> decltype(StreamSwitch<T>::printable(V)) {
37 return StreamSwitch<T>::printable(V);
54 const T& V;
55 friend std::ostream &operator<<(std::ostream &S, const RawStreamProxy<T> &V) {
69 static const RawStreamProxy<T> printable(const T &V) { return {V}; }
69 static const RawStreamProxy<T> printable(const T &V) { return {V}; }