MimIR 0.1
MimIR is my Intermediate Representation
Loading...
Searching...
No Matches
autodiff_zero_cleanup.h
Go to the documentation of this file.
1#pragma once
2
3#include <mim/def.h>
4#include <mim/pass/pass.h>
5
6namespace mim::plug::autodiff {
7
8/// Replaces remaining zeros (not resolvable) with ⊥.
9class AutoDiffZeroCleanup : public RWPass<AutoDiffZeroCleanup, Lam> {
10public:
12 : RWPass(man, "autodiff_zero_cleanup") {}
13
14 Ref rewrite(Ref) override;
15};
16
17} // namespace mim::plug::autodiff
An optimizer that combines several optimizations in an optimal way.
Definition pass.h:107
PassMan & man()
Definition pass.h:30
Inherit from this class using CRTP, if your Pass does not need state and a fixed-point iteration.
Definition pass.h:220
Helper class to retrieve Infer::arg if present.
Definition def.h:86
Replaces remaining zeros (not resolvable) with ⊥.
The automatic differentiation Plugin
Definition autodiff.h:6