Beaver.MLIR.Pattern (beaver v0.2.19)

Although this module is MLIR.Pattern, at this point it is a synonym of PDL patterns. Pattern-matching is done by MLIR which works in a different way from Erlang pattern-matching. The major difference is that MLIR pattern-matching will greedily match the patterns and maximize the benefit. Compiled patterns will be saved as module attributes in MLIR assembly format.

Link to this section Summary

Functions

Apply patterns on a container (region, operation, module). It returns the container if it succeeds otherwise it raises.

Apply patterns on a container (region, operation, module). It is named apply_ with a underscore to avoid name collision with Kernel.apply/2

Link to this section Functions

Link to this function

apply!(op, patterns, opts \\ [debug: false])

Apply patterns on a container (region, operation, module). It returns the container if it succeeds otherwise it raises.

Link to this function

apply_(op, patterns, opts \\ [debug: false])

Apply patterns on a container (region, operation, module). It is named apply_ with a underscore to avoid name collision with Kernel.apply/2

Link to this function

from_string(pdl_pattern_str, opts \\ [])