7 #ifndef JLM_RVSDG_BITSTRING_BITOPERATION_CLASSES_HPP
8 #define JLM_RVSDG_BITSTRING_BITOPERATION_CLASSES_HPP
32 return *std::static_pointer_cast<const BitType>(
argument(0));
44 virtual std::unique_ptr<BitUnaryOperation>
63 const noexcept
override;
71 virtual BitValueRepresentation
75 virtual std::unique_ptr<BitBinaryOperation>
81 return *std::static_pointer_cast<const BitType>(
result(0));
103 const noexcept
override;
115 virtual std::unique_ptr<BitCompareOperation>
121 return *std::static_pointer_cast<const BitType>(
argument(0));
~BitBinaryOperation() noexcept override
binop_reduction_path_t can_reduce_operand_pair(const jlm::rvsdg::Output *arg1, const jlm::rvsdg::Output *arg2) const noexcept override
virtual std::unique_ptr< BitBinaryOperation > create(size_t nbits) const =0
virtual BitValueRepresentation reduce_constants(const BitValueRepresentation &arg1, const BitValueRepresentation &arg2) const =0
const BitType & type() const noexcept
jlm::rvsdg::Output * reduce_operand_pair(binop_reduction_path_t path, jlm::rvsdg::Output *arg1, jlm::rvsdg::Output *arg2) const override
const BitType & type() const noexcept
binop_reduction_path_t can_reduce_operand_pair(const jlm::rvsdg::Output *arg1, const jlm::rvsdg::Output *arg2) const noexcept override
jlm::rvsdg::Output * reduce_operand_pair(binop_reduction_path_t path, jlm::rvsdg::Output *arg1, jlm::rvsdg::Output *arg2) const override
virtual std::unique_ptr< BitCompareOperation > create(size_t nbits) const =0
virtual compare_result reduce_constants(const BitValueRepresentation &arg1, const BitValueRepresentation &arg2) const =0
~BitCompareOperation() noexcept override
static std::shared_ptr< const BitType > Create(std::size_t nbits)
Creates bit type of specified width.
~BitUnaryOperation() noexcept override
virtual std::unique_ptr< BitUnaryOperation > create(size_t nbits) const =0
unop_reduction_path_t can_reduce_operand(const jlm::rvsdg::Output *arg) const noexcept override
jlm::rvsdg::Output * reduce_operand(unop_reduction_path_t path, jlm::rvsdg::Output *arg) const override
virtual BitValueRepresentation reduce_constant(const BitValueRepresentation &arg) const =0
const BitType & type() const noexcept
const std::shared_ptr< const rvsdg::Type > & argument(size_t index) const noexcept
const std::shared_ptr< const rvsdg::Type > & result(size_t index) const noexcept
size_t unop_reduction_path_t
size_t binop_reduction_path_t