aboutsummaryrefslogtreecommitdiff
path: root/backend/include/rcc/CodeGen/GlobalISel/LegalizerHelper.h
diff options
context:
space:
mode:
Diffstat (limited to 'backend/include/rcc/CodeGen/GlobalISel/LegalizerHelper.h')
-rw-r--r--backend/include/rcc/CodeGen/GlobalISel/LegalizerHelper.h6
1 files changed, 5 insertions, 1 deletions
diff --git a/backend/include/rcc/CodeGen/GlobalISel/LegalizerHelper.h b/backend/include/rcc/CodeGen/GlobalISel/LegalizerHelper.h
index 9ad66a2..39304ba 100644
--- a/backend/include/rcc/CodeGen/GlobalISel/LegalizerHelper.h
+++ b/backend/include/rcc/CodeGen/GlobalISel/LegalizerHelper.h
@@ -15,6 +15,7 @@ namespace rcc {
class MachineFunction;
class MachineInstr;
class GISelChangeObserver;
+struct LibcallLoweringInfo;
class LegalizerHelper final {
public:
@@ -22,7 +23,8 @@ public:
GISelChangeObserver &Observer;
LegalizerHelper(MachineFunction &Function, const LegalizerInfo &Info,
- GISelChangeObserver &Observer, MachineIRBuilder &MIRBuilder);
+ GISelChangeObserver &Observer, MachineIRBuilder &MIRBuilder,
+ const LibcallLoweringInfo *Libcalls = nullptr);
[[nodiscard]] Expected<void> legalize(MachineInstr &Instruction,
const LegalizationDecision &Decision);
@@ -35,6 +37,7 @@ public:
[[nodiscard]] Expected<void> lowerThreewayCompare(MachineInstr &Instruction);
[[nodiscard]] Expected<void> lowerRotate(MachineInstr &Instruction);
[[nodiscard]] Expected<void> lowerVAArg(MachineInstr &Instruction);
+ [[nodiscard]] Expected<void> libcall(MachineInstr &Instruction);
[[nodiscard]] Expected<void> widenScalar(MachineInstr &Instruction, std::size_t TypeIndex,
LowLevelType WideType);
[[nodiscard]] Expected<void> widenScalarSrc(MachineInstr &Instruction, LowLevelType WideType,
@@ -118,6 +121,7 @@ private:
MachineFunction &Function;
MachineRegisterInfo &MRI;
const LegalizerInfo &Info;
+ const LibcallLoweringInfo *Libcalls = nullptr;
};
} // namespace rcc