1 //===-- XCOFFDump.h ---------------------------------------------*- C++ -*-===//
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
7 //===----------------------------------------------------------------------===//
9 #ifndef LLVM_TOOLS_LLVM_OBJDUMP_XCOFFDUMP_H
10 #define LLVM_TOOLS_LLVM_OBJDUMP_XCOFFDUMP_H
12 #include "llvm/Object/XCOFFObjectFile.h"
16 class formatted_raw_ostream
;
17 class MCSubtargetInfo
;
21 std::optional
<XCOFF::StorageMappingClass
>
22 getXCOFFSymbolCsectSMC(const object::XCOFFObjectFile
&Obj
,
23 const object::SymbolRef
&Sym
);
25 std::optional
<object::SymbolRef
>
26 getXCOFFSymbolContainingSymbolRef(const object::XCOFFObjectFile
&Obj
,
27 const object::SymbolRef
&Sym
);
29 bool isLabel(const object::XCOFFObjectFile
&Obj
, const object::SymbolRef
&Sym
);
31 std::string
getXCOFFSymbolDescription(const SymbolInfoTy
&SymbolInfo
,
32 StringRef SymbolName
);
34 Error
getXCOFFRelocationValueString(const object::XCOFFObjectFile
&Obj
,
35 const object::RelocationRef
&RelRef
,
36 llvm::SmallVectorImpl
<char> &Result
);
38 void dumpTracebackTable(ArrayRef
<uint8_t> Bytes
, uint64_t Address
,
39 formatted_raw_ostream
&OS
, uint64_t End
,
40 const MCSubtargetInfo
&STI
,
41 const object::XCOFFObjectFile
*Obj
);
42 } // namespace objdump