MLIR  20.0.0git
Public Types | Public Member Functions | Static Public Member Functions | List of all members
mlir::WalkContinuation Class Reference

A class to signal how to proceed with the walk of the backward slice: More...

#include "mlir/Analysis/SliceWalk.h"

Public Types

enum class  WalkAction { Interrupt , AdvanceTo , Skip }
 

Public Member Functions

 WalkContinuation (WalkAction action, mlir::ValueRange nextValues)
 
 WalkContinuation (mlir::Diagnostic &&)
 Allows diagnostics to interrupt the walk. More...
 
 WalkContinuation (mlir::InFlightDiagnostic &&)
 Allows diagnostics to interrupt the walk. More...
 
bool wasInterrupted () const
 Returns true if the walk was interrupted. More...
 
bool wasSkipped () const
 Returns true if the walk was skipped. More...
 
bool wasAdvancedTo () const
 Returns true if the walk was advanced to user-specified values. More...
 
mlir::ArrayRef< mlir::ValuegetNextValues () const
 Returns the next values to continue the walk with. More...
 

Static Public Member Functions

static WalkContinuation interrupt ()
 Creates a continuation that interrupts the walk. More...
 
static WalkContinuation advanceTo (mlir::ValueRange nextValues)
 Creates a continuation that adds the user-specified nextValues to the work list and advances the walk. More...
 
static WalkContinuation skip ()
 Creates a continuation that advances the walk without adding any predecessor values to the work list. More...
 

Detailed Description

A class to signal how to proceed with the walk of the backward slice:

Definition at line 20 of file SliceWalk.h.

Member Enumeration Documentation

◆ WalkAction

Enumerator
Interrupt 

Stops the walk.

AdvanceTo 

Continues the walk to user-specified values.

Skip 

Continues the walk, but skips the predecessors of the current value.

Definition at line 22 of file SliceWalk.h.

Constructor & Destructor Documentation

◆ WalkContinuation() [1/3]

mlir::WalkContinuation::WalkContinuation ( WalkAction  action,
mlir::ValueRange  nextValues 
)
inline

Definition at line 31 of file SliceWalk.h.

Referenced by advanceTo(), interrupt(), and skip().

◆ WalkContinuation() [2/3]

mlir::WalkContinuation::WalkContinuation ( mlir::Diagnostic &&  )
inlineexplicit

Allows diagnostics to interrupt the walk.

Definition at line 35 of file SliceWalk.h.

◆ WalkContinuation() [3/3]

mlir::WalkContinuation::WalkContinuation ( mlir::InFlightDiagnostic &&  )
inlineexplicit

Allows diagnostics to interrupt the walk.

Definition at line 39 of file SliceWalk.h.

Member Function Documentation

◆ advanceTo()

static WalkContinuation mlir::WalkContinuation::advanceTo ( mlir::ValueRange  nextValues)
inlinestatic

Creates a continuation that adds the user-specified nextValues to the work list and advances the walk.

Definition at line 49 of file SliceWalk.h.

References AdvanceTo, and WalkContinuation().

Referenced by getUnderlyingObjectSet().

◆ getNextValues()

mlir::ArrayRef<mlir::Value> mlir::WalkContinuation::getNextValues ( ) const
inline

Returns the next values to continue the walk with.

Definition at line 69 of file SliceWalk.h.

Referenced by mlir::walkSlice().

◆ interrupt()

static WalkContinuation mlir::WalkContinuation::interrupt ( )
inlinestatic

Creates a continuation that interrupts the walk.

Definition at line 43 of file SliceWalk.h.

References Interrupt, and WalkContinuation().

Referenced by getUnderlyingObjectSet().

◆ skip()

static WalkContinuation mlir::WalkContinuation::skip ( )
inlinestatic

Creates a continuation that advances the walk without adding any predecessor values to the work list.

Definition at line 55 of file SliceWalk.h.

References Skip, and WalkContinuation().

Referenced by getUnderlyingObjectSet(), and mlir::walkSlice().

◆ wasAdvancedTo()

bool mlir::WalkContinuation::wasAdvancedTo ( ) const
inline

Returns true if the walk was advanced to user-specified values.

Definition at line 66 of file SliceWalk.h.

References AdvanceTo.

Referenced by mlir::walkSlice().

◆ wasInterrupted()

bool mlir::WalkContinuation::wasInterrupted ( ) const
inline

Returns true if the walk was interrupted.

Definition at line 60 of file SliceWalk.h.

References Interrupt.

Referenced by getUnderlyingObjectSet(), and mlir::walkSlice().

◆ wasSkipped()

bool mlir::WalkContinuation::wasSkipped ( ) const
inline

Returns true if the walk was skipped.

Definition at line 63 of file SliceWalk.h.

References Skip.

Referenced by mlir::walkSlice().


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