diff options
Diffstat (limited to 'backend/include/rcc/CodeGen')
| -rw-r--r-- | backend/include/rcc/CodeGen/MachineInstr.h | 2 | ||||
| -rw-r--r-- | backend/include/rcc/CodeGen/MachineStripDebug.h | 16 |
2 files changed, 18 insertions, 0 deletions
diff --git a/backend/include/rcc/CodeGen/MachineInstr.h b/backend/include/rcc/CodeGen/MachineInstr.h index 60f8014..6de4a4e 100644 --- a/backend/include/rcc/CodeGen/MachineInstr.h +++ b/backend/include/rcc/CodeGen/MachineInstr.h @@ -79,6 +79,8 @@ public: return ParentBlock != nullptr; } + [[nodiscard]] bool isDebugInstr() const noexcept; + [[nodiscard]] std::size_t operandCount() const noexcept { return Operands.size(); } diff --git a/backend/include/rcc/CodeGen/MachineStripDebug.h b/backend/include/rcc/CodeGen/MachineStripDebug.h new file mode 100644 index 0000000..eb89155 --- /dev/null +++ b/backend/include/rcc/CodeGen/MachineStripDebug.h @@ -0,0 +1,16 @@ +// SPDX-License-Identifier: GPL-3.0-or-later + +#ifndef RCC_CODEGEN_MACHINESTRIPDEBUG_H +#define RCC_CODEGEN_MACHINESTRIPDEBUG_H + +#include "rcc/Support/Error.h" + +namespace rcc { + +class MachineFunction; + +[[nodiscard]] Expected<bool> stripDebugMachineFunction(MachineFunction &Function); + +} // namespace rcc + +#endif // RCC_CODEGEN_MACHINESTRIPDEBUG_H |
