Thorin 1.9.0
The Higher ORder INtermediate representation
|
Recurseivly rewrites part of a program into the provided World. More...
#include <thorin/rewrite.h>
Public Member Functions | |
Rewriter (World &world) | |
World & | world () |
Ref | map (Ref old_def, Ref new_def) |
Map old_def to new_def and returns new_def ;. | |
rewrite | |
Recursively rewrite old Defs. | |
virtual Ref | rewrite (Ref) |
virtual Ref | rewrite_imm (Ref) |
virtual Ref | rewrite_mut (Def *) |
Recurseivly rewrites part of a program into the provided World.
Map old_def
to new_def
and returns new_def
;.
Definition at line 16 of file rewrite.h.
Referenced by rewrite(), rewrite_mut(), thorin::VarRewriter::rewrite_mut(), and thorin::VarRewriter::VarRewriter().
Definition at line 9 of file rewrite.cpp.
References thorin::Def::isa_mut(), map(), rewrite_imm(), rewrite_mut(), thorin::World::univ(), and world().
Referenced by thorin::World::app(), thorin::World::extract(), thorin::rewrite(), thorin::rewrite(), rewrite_imm(), thorin::plug::matrix::LowerMatrixLowLevel::rewrite_imm(), rewrite_mut(), thorin::RWPhase::start(), and thorin::Cleanup::start().
Reimplemented in thorin::VarRewriter, and thorin::plug::matrix::LowerMatrixLowLevel.
Definition at line 16 of file rewrite.cpp.
References thorin::Lit::isa(), thorin::Def::num_ops(), thorin::Def::op(), thorin::Def::rebuild(), rewrite(), thorin::Def::type(), and world().
Referenced by rewrite(), thorin::VarRewriter::rewrite_imm(), and thorin::plug::matrix::LowerMatrixLowLevel::rewrite_imm().
Reimplemented in thorin::VarRewriter.
Definition at line 32 of file rewrite.cpp.
References thorin::Def::is_set(), map(), thorin::Def::num_ops(), thorin::Def::op(), rewrite(), thorin::Def::stub(), thorin::Def::type(), and world().
Referenced by rewrite(), and thorin::VarRewriter::rewrite_mut().
|
inline |
Definition at line 14 of file rewrite.h.
Referenced by rewrite(), rewrite_imm(), rewrite_mut(), thorin::VarRewriter::rewrite_mut(), and thorin::VarRewriter::VarRewriter().