Loading...
Searching...
No Matches
Halide::Internal::IRMatcher::Rewriter< Instance > Struct Template Reference

`#include <IRMatch.h>`

## Public Member Functions

HALIDE_ALWAYS_INLINE | Rewriter (Instance instance, halide_type_t ot, halide_type_t wt)
template<typename After>
HALIDE_NEVER_INLINE void | build_replacement (After after)
template<typename Before, typename After, typename = typename enable_if_pattern<Before>::type, typename = typename enable_if_pattern<After>::type>
HALIDE_ALWAYS_INLINE bool | operator() (Before before, After after)
template<typename Before, typename = typename enable_if_pattern<Before>::type>
HALIDE_ALWAYS_INLINE bool | operator() (Before before, const Expr &after) noexcept
template<typename Before, typename = typename enable_if_pattern<Before>::type>
HALIDE_ALWAYS_INLINE bool | operator() (Before before, int64_t after) noexcept
template<typename Before, typename After, typename Predicate, typename = typename enable_if_pattern<Before>::type, typename = typename enable_if_pattern<After>::type, typename = typename enable_if_pattern<Predicate>::type>
HALIDE_ALWAYS_INLINE bool | operator() (Before before, After after, Predicate pred)
template<typename Before, typename Predicate, typename = typename enable_if_pattern<Before>::type, typename = typename enable_if_pattern<Predicate>::type>
HALIDE_ALWAYS_INLINE bool | operator() (Before before, const Expr &after, Predicate pred)
template<typename Before, typename Predicate, typename = typename enable_if_pattern<Before>::type, typename = typename enable_if_pattern<Predicate>::type>
HALIDE_ALWAYS_INLINE bool | operator() (Before before, int64_t after, Predicate pred)

## Public Attributes

Instance | instance
Expr | result
MatcherState | state
halide_type_t | output_type
halide_type_t | wildcard_type
bool | validate

## Detailed Description

template<typename Instance>
struct Halide::Internal::IRMatcher::Rewriter< Instance >

Definition at line 2863 of file IRMatch.h.

## Constructor & Destructor Documentation

## Rewriter()

template<typename Instance>

HALIDE_ALWAYS_INLINE Halide::Internal::IRMatcher::Rewriter< Instance >::Rewriter | ( | Instance | instance,
|  | halide_type_t | ot,
|  | halide_type_t | wt )

inline

Definition at line 2871 of file IRMatch.h.

References instance, output_type, and wildcard_type.

## Member Function Documentation

## build_replacement()

template<typename Instance>
template<typename After>

HALIDE_NEVER_INLINE void Halide::Internal::IRMatcher::Rewriter< Instance >::build_replacement | ( | After | after | ) |

inline

Definition at line 2876 of file IRMatch.h.

References debug, HALIDE_NEVER_INLINE, instance, output_type, result, and state.

Referenced by operator()(), and operator()().

## operator()() [1/6]

template<typename Instance>
template<typename Before, typename After, typename = typename enable_if_pattern<Before>::type, typename = typename enable_if_pattern<After>::type>

HALIDE_ALWAYS_INLINE bool Halide::Internal::IRMatcher::Rewriter< Instance >::operator() | ( | Before | before,
|  | After | after )

inline

Definition at line 2887 of file IRMatch.h.

References build_replacement(), debug, Halide::Internal::IRMatcher::fuzz_test_rule(), HALIDE_ALWAYS_INLINE, instance, output_type, result, state, Halide::Internal::IRMatcher::unwrap(), and wildcard_type.

## operator()() [2/6]

template<typename Instance>
template<typename Before, typename = typename enable_if_pattern<Before>::type>

HALIDE_ALWAYS_INLINE bool Halide::Internal::IRMatcher::Rewriter< Instance >::operator() | ( | Before | before,
|  | const Expr & | after )

inline noexcept

Definition at line 2910 of file IRMatch.h.

References debug, HALIDE_ALWAYS_INLINE, instance, result, state, and Halide::Internal::IRMatcher::unwrap().

## operator()() [3/6]

template<typename Instance>
template<typename Before, typename = typename enable_if_pattern<Before>::type>

HALIDE_ALWAYS_INLINE bool Halide::Internal::IRMatcher::Rewriter< Instance >::operator() | ( | Before | before,
|  | int64_t | after )

inline noexcept

Definition at line 2928 of file IRMatch.h.

References debug, Halide::Internal::IRMatcher::fuzz_test_rule(), HALIDE_ALWAYS_INLINE, instance, Halide::Internal::make_const(), output_type, result, state, Halide::Internal::IRMatcher::unwrap(), and wildcard_type.

## operator()() [4/6]

template<typename Instance>
template<typename Before, typename After, typename Predicate, typename = typename enable_if_pattern<Before>::type, typename = typename enable_if_pattern<After>::type, typename = typename enable_if_pattern<Predicate>::type>

HALIDE_ALWAYS_INLINE bool Halide::Internal::IRMatcher::Rewriter< Instance >::operator() | ( | Before | before,
|  | After | after,
|  | Predicate | pred )

inline

Definition at line 2953 of file IRMatch.h.

References build_replacement(), debug, Halide::Internal::IRMatcher::evaluate_predicate(), Halide::Internal::IRMatcher::fuzz_test_rule(), HALIDE_ALWAYS_INLINE, instance, output_type, result, state, Halide::Internal::IRMatcher::unwrap(), and wildcard_type.

## operator()() [5/6]

template<typename Instance>
template<typename Before, typename Predicate, typename = typename enable_if_pattern<Before>::type, typename = typename enable_if_pattern<Predicate>::type>

HALIDE_ALWAYS_INLINE bool Halide::Internal::IRMatcher::Rewriter< Instance >::operator() | ( | Before | before,
|  | const Expr & | after,
|  | Predicate | pred )

inline

Definition at line 2982 of file IRMatch.h.

References debug, Halide::Internal::IRMatcher::evaluate_predicate(), HALIDE_ALWAYS_INLINE, instance, result, state, and Halide::Internal::IRMatcher::unwrap().

## operator()() [6/6]

template<typename Instance>
template<typename Before, typename Predicate, typename = typename enable_if_pattern<Before>::type, typename = typename enable_if_pattern<Predicate>::type>

HALIDE_ALWAYS_INLINE bool Halide::Internal::IRMatcher::Rewriter< Instance >::operator() | ( | Before | before,
|  | int64_t | after,
|  | Predicate | pred )

inline

Definition at line 3005 of file IRMatch.h.

References debug, Halide::Internal::IRMatcher::evaluate_predicate(), Halide::Internal::IRMatcher::fuzz_test_rule(), HALIDE_ALWAYS_INLINE, instance, Halide::Internal::make_const(), output_type, result, state, Halide::Internal::IRMatcher::unwrap(), and wildcard_type.

## Member Data Documentation

## instance

template<typename Instance>

Instance Halide::Internal::IRMatcher::Rewriter< Instance >::instance

Definition at line 2864 of file IRMatch.h.

Referenced by build_replacement(), operator()(), operator()(), operator()(), operator()(), operator()(), operator()(), and Rewriter().

## result

template<typename Instance>

Expr Halide::Internal::IRMatcher::Rewriter< Instance >::result

Definition at line 2865 of file IRMatch.h.

Referenced by build_replacement(), operator()(), operator()(), operator()(), operator()(), operator()(), and operator()().

## state

template<typename Instance>

MatcherState Halide::Internal::IRMatcher::Rewriter< Instance >::state

Definition at line 2866 of file IRMatch.h.

Referenced by build_replacement(), operator()(), operator()(), operator()(), operator()(), operator()(), and operator()().

## output_type

template<typename Instance>

halide_type_t Halide::Internal::IRMatcher::Rewriter< Instance >::output_type

Definition at line 2867 of file IRMatch.h.

Referenced by build_replacement(), operator()(), operator()(), operator()(), operator()(), and Rewriter().

## wildcard_type

template<typename Instance>

halide_type_t Halide::Internal::IRMatcher::Rewriter< Instance >::wildcard_type

Definition at line 2867 of file IRMatch.h.

Referenced by operator()(), operator()(), operator()(), operator()(), and Rewriter().

## validate

template<typename Instance>

bool Halide::Internal::IRMatcher::Rewriter< Instance >::validate

Definition at line 2868 of file IRMatch.h.

The documentation for this struct was generated from the following file:

- src/IRMatch.h