Skip to content

[IR] Evaluate at #2017

Open
Open
@justinchuby

Description

@justinchuby

Given an ir.Value, it would be nice to have a method to evaluate the constant value for it.

tensors: Sequence[ir.TensorProtocol] = some_evaluator.evaluate_at([value1, value2, ...])

We can build the constant folder based on this, where we

  1. Analyze which value should be constant folded (taking into account tensor sizes etc.
  2. Replace the values with initializers after calling the function above

cc @gramalingam

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions