Files
revng-revng/include/revng/Yield/Assembly/DisassemblyHelper.h
Ivan Krysak c6e38cd485 Return to using constant name builders
Because of how name builders used to lazy gather namespaces on the first
requested name, the objects were self mutating. As such only non-const
references could be used to pass them around.

Since that is no longer the case, this restores most of lost const
qualifiers.
2025-04-17 11:19:17 +03:00

43 lines
1013 B
C++

#pragma once
//
// This file is distributed under the MIT License. See LICENSE.md for details.
//
#include <map>
#include <memory>
#include "revng/Yield/Function.h"
namespace detail {
class DissassemblyHelperImpl;
}
namespace model {
class Function;
}
namespace efa {
class ControlFlowGraph;
}
class LLVMDisassemblerInterface;
class RawBinaryView;
class DissassemblyHelper {
private:
std::unique_ptr<detail::DissassemblyHelperImpl> Internal;
public:
explicit DissassemblyHelper();
~DissassemblyHelper();
yield::Function disassemble(const model::Function &Function,
const efa::ControlFlowGraph &Metadata,
const RawBinaryView &BinaryView,
const model::Binary &Binary,
const model::AssemblyNameBuilder &NameBuilder);
private:
LLVMDisassemblerInterface &
getDisassemblerFor(MetaAddressType::Values AddressType,
const model::DisassemblyConfiguration &);
};