LLVM  12.0.0git
ObjectFileTransformer.h
Go to the documentation of this file.
1 //===- ObjectFileTransformer.h ----------------------------------*- C++ -*-===//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
8 
9 #ifndef LLVM_DEBUGINFO_GSYM_OBJECTFILETRANSFORMER_H
10 #define LLVM_DEBUGINFO_GSYM_OBJECTFILETRANSFORMER_H
11 
12 #include "llvm/Support/Error.h"
13 
14 namespace llvm {
15 
16 class raw_ostream;
17 
18 namespace object {
19 class ObjectFile;
20 }
21 
22 namespace gsym {
23 
24 struct CUInfo;
25 class GsymCreator;
26 
28 public:
29  /// Extract any object file data that is needed by the GsymCreator.
30  ///
31  /// The extracted information includes the UUID of the binary and converting
32  /// all function symbols from any symbol tables into FunctionInfo objects.
33  ///
34  /// \param Obj The object file that contains the DWARF debug info.
35  ///
36  /// \param Log The stream to log warnings and non fatal issues to.
37  ///
38  /// \param Gsym The GSYM creator to populate with the function information
39  /// from the debug info.
40  ///
41  /// \returns An error indicating any fatal issues that happen when parsing
42  /// the DWARF, or Error::success() if all goes well.
43  static llvm::Error convert(const object::ObjectFile &Obj,
44  raw_ostream &Log,
45  GsymCreator &Gsym);
46 };
47 
48 } // namespace gsym
49 } // namespace llvm
50 
51 #endif // #ifndef LLVM_DEBUGINFO_GSYM_OBJECTFILETRANSFORMER_H
This class represents lattice values for constants.
Definition: AllocatorList.h:23
This class is the base class for all object file types.
Definition: ObjectFile.h:225
GsymCreator is used to emit GSYM data to a stand alone file or section within a file.
Definition: GsymCreator.h:134
Lightweight error class with error context and mandatory checking.
Definition: Error.h:157
This class implements an extremely fast bulk output stream that can only output to a stream...
Definition: raw_ostream.h:46