mirror of
https://github.com/llvm/llvm-project.git
synced 2025-05-10 18:06:05 +00:00

Summary: for xcoff : implement the getSymbolFlag and getSymbolType() for option --syms. llvm-objdump --sym , if the symbol is label, print the containing section for the symbol too. when using llvm-objdump --sym --symbol--description, print the symbol index and qualname for symbol. for example: --symbol-description 00000000000000c0 l .text (csect: (idx: 2) .foov[PR]) (idx: 3) .foov and without --symbol-description 00000000000000c0 l .text (csect: .foov) .foov Reviewers: James Henderson,Esme Yi Differential Revision: https://reviews.llvm.org/D109452
38 lines
1.3 KiB
C++
38 lines
1.3 KiB
C++
//===-- XCOFFDump.h ---------------------------------------------*- C++ -*-===//
|
|
//
|
|
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
|
|
// See https://llvm.org/LICENSE.txt for license information.
|
|
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
|
|
//
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
#ifndef LLVM_TOOLS_LLVM_OBJDUMP_XCOFFDUMP_H
|
|
#define LLVM_TOOLS_LLVM_OBJDUMP_XCOFFDUMP_H
|
|
|
|
#include "llvm/Object/XCOFFObjectFile.h"
|
|
|
|
namespace llvm {
|
|
|
|
struct SymbolInfoTy;
|
|
|
|
namespace objdump {
|
|
Optional<XCOFF::StorageMappingClass>
|
|
getXCOFFSymbolCsectSMC(const object::XCOFFObjectFile *Obj,
|
|
const object::SymbolRef &Sym);
|
|
|
|
Optional<object::SymbolRef>
|
|
getXCOFFSymbolContainingSymbolRef(const object::XCOFFObjectFile *Obj,
|
|
const object::SymbolRef &Sym);
|
|
|
|
bool isLabel(const object::XCOFFObjectFile *Obj, const object::SymbolRef &Sym);
|
|
|
|
std::string getXCOFFSymbolDescription(const SymbolInfoTy &SymbolInfo,
|
|
StringRef SymbolName);
|
|
|
|
Error getXCOFFRelocationValueString(const object::XCOFFObjectFile *Obj,
|
|
const object::RelocationRef &RelRef,
|
|
llvm::SmallVectorImpl<char> &Result);
|
|
} // namespace objdump
|
|
} // namespace llvm
|
|
#endif
|