LLDB mainline
ArchitectureRISCV.h
Go to the documentation of this file.
1//===----------------------------------------------------------------------===//
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 LLDB_SOURCE_PLUGINS_ARCHITECTURE_RISCV_ARCHITECTURERISCV_H
10#define LLDB_SOURCE_PLUGINS_ARCHITECTURE_RISCV_ARCHITECTURERISCV_H
11
13
14namespace lldb_private {
15
17public:
18 static llvm::StringRef GetPluginNameStatic() { return "riscv"; }
19 static void Initialize();
20 static void Terminate();
21
22 llvm::StringRef GetPluginName() override { return GetPluginNameStatic(); }
23
24 void OverrideStopInfo(Thread &thread) const override {}
25
26 bool IsValidTrapInstruction(llvm::ArrayRef<uint8_t> reference,
27 llvm::ArrayRef<uint8_t> observed) const override;
28
29private:
30 static std::unique_ptr<Architecture> Create(const ArchSpec &arch);
31 ArchitectureRISCV() = default;
32};
33
34} // namespace lldb_private
35
36#endif // LLDB_SOURCE_PLUGINS_ARCHITECTURE_RISCV_ARCHITECTURERISCV_H
An architecture specification class.
Definition ArchSpec.h:32
llvm::StringRef GetPluginName() override
static std::unique_ptr< Architecture > Create(const ArchSpec &arch)
bool IsValidTrapInstruction(llvm::ArrayRef< uint8_t > reference, llvm::ArrayRef< uint8_t > observed) const override
Returns whether a given byte sequence is a valid trap instruction for the architecture.
void OverrideStopInfo(Thread &thread) const override
This is currently intended to handle cases where a program stops at an instruction that won't get exe...
static llvm::StringRef GetPluginNameStatic()
A class that represents a running process on the host machine.