| 1 | //===-- XCOFFDump.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_TOOLS_LLVM_OBJDUMP_XCOFFDUMP_H |
| 10 | #define LLVM_TOOLS_LLVM_OBJDUMP_XCOFFDUMP_H |
| 11 | |
| 12 | #include "llvm/Object/XCOFFObjectFile.h" |
| 13 | |
| 14 | namespace llvm { |
| 15 | |
| 16 | class formatted_raw_ostream; |
| 17 | class MCSubtargetInfo; |
| 18 | struct SymbolInfoTy; |
| 19 | |
| 20 | namespace objdump { |
| 21 | std::optional<XCOFF::StorageMappingClass> |
| 22 | getXCOFFSymbolCsectSMC(const object::XCOFFObjectFile &Obj, |
| 23 | const object::SymbolRef &Sym); |
| 24 | |
| 25 | std::optional<object::SymbolRef> |
| 26 | getXCOFFSymbolContainingSymbolRef(const object::XCOFFObjectFile &Obj, |
| 27 | const object::SymbolRef &Sym); |
| 28 | |
| 29 | bool isLabel(const object::XCOFFObjectFile &Obj, const object::SymbolRef &Sym); |
| 30 | |
| 31 | std::string getXCOFFSymbolDescription(const SymbolInfoTy &SymbolInfo, |
| 32 | StringRef SymbolName); |
| 33 | |
| 34 | Error getXCOFFRelocationValueString(const object::XCOFFObjectFile &Obj, |
| 35 | const object::RelocationRef &RelRef, |
| 36 | bool SymbolDescription, |
| 37 | llvm::SmallVectorImpl<char> &Result); |
| 38 | |
| 39 | void dumpTracebackTable(ArrayRef<uint8_t> Bytes, uint64_t Address, |
| 40 | formatted_raw_ostream &OS, uint64_t End, |
| 41 | const MCSubtargetInfo &STI, |
| 42 | const object::XCOFFObjectFile *Obj); |
| 43 | } // namespace objdump |
| 44 | } // namespace llvm |
| 45 | #endif |
| 46 | |