Halide 22.0.0 Halide compiler and libraries

Loading...
Searching...
No Matches
Static Public Member Functions | Public Attributes | Static Public Attributes | List of all members
Halide::Internal::Select Struct Reference

A ternary operator. More...

`#include <IR.h>`

Inheritance diagram for Halide::Internal::Select:

## Static Public Member Functions
static Expr | make (Expr condition, Expr true_value, Expr false_value)

## Public Attributes
Expr | condition
Expr | true_value
Expr | false_value
Public Attributes inherited from Halide::Internal::BaseExprNode
Type | type
Public Attributes inherited from Halide::Internal::IRNode
RefCount | ref_count
| These classes are all managed with intrusive reference counting, so we also track a reference count.
IRNodeType | node_type
| Each IR node subclass has a unique identifier.

## Static Public Attributes
static const IRNodeType | _node_type = IRNodeType::Select

## Additional Inherited Members
Public Member Functions inherited from Halide::Internal::ExprNode< Select >
void | accept (IRVisitor *v) const override
| We use the visitor pattern to traverse IR nodes throughout the compiler, so we have a virtual accept method which accepts visitors.
Expr | mutate_expr (IRMutator *v) const override
| ExprNode ()
| ~ExprNode () override=default
Public Member Functions inherited from Halide::Internal::BaseExprNode
| BaseExprNode (IRNodeType t)
Public Member Functions inherited from Halide::Internal::IRNode
| IRNode (IRNodeType t)
virtual | ~IRNode ()=default

## Detailed Description

A ternary operator.

Evalutes 'true_value' and 'false_value', then selects between them based on 'condition'. Equivalent to the ternary operator in C.

Definition at line 214 of file IR.h.

## Member Function Documentation

## ◆ make()

static Expr Halide::Internal::Select::make | ( | Expr | condition,
|  | Expr | true_value,
|  | Expr | false_value
| ) |  |
| static

Referenced by Halide::Internal::IRMatcher::SelectOp< C, T, F >::make().

## Member Data Documentation

## ◆ condition

Expr Halide::Internal::Select::condition

Definition at line 215 of file IR.h.

Referenced by Halide::Internal::IRMatcher::SelectOp< C, T, F >::match().

## ◆ true_value

Expr Halide::Internal::Select::true_value

Definition at line 215 of file IR.h.

Referenced by Halide::Internal::IRMatcher::SelectOp< C, T, F >::match().

## ◆ false_value

Expr Halide::Internal::Select::false_value

Definition at line 215 of file IR.h.

Referenced by Halide::Internal::IRMatcher::SelectOp< C, T, F >::match().

## ◆ _node_type

const IRNodeType Halide::Internal::Select::_node_type = IRNodeType::Select
| static

Definition at line 219 of file IR.h.

Referenced by Halide::Internal::IRMatcher::SelectOp< C, T, F >::match().

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

- src/IR.h