pub enum Rvsdg {
Simple {
outputs: Vec<Expr>,
},
StateFul {
outputs: Vec<StateExpr>,
side_effect: Option<StateExpr>,
},
Linear(Vec<Rvsdg>),
BranchIf {
cond_index: usize,
branches: [Box<Rvsdg>; 2],
},
BranchSwitch {
cond_index: usize,
branches: Vec<Rvsdg>,
},
Loop {
body: Box<Rvsdg>,
cond_index: usize,
outputs: Vec<usize>,
},
}Variants§
Simple
StateFul
Fields
Original RVSDG has state edges but I’ve chosen to introduce a new node type that has single stateful operation and its order is preserved by the linear node to (hopefully) make the representation egglog friendly.
Linear(Vec<Rvsdg>)
BranchIf
Gamma node cond_var is a bool
BranchSwitch
cond_var is an int
Loop
Theta node
Implementations§
Trait Implementations§
Auto Trait Implementations§
impl RefUnwindSafe for Rvsdg
impl Send for Rvsdg
impl Sync for Rvsdg
impl Unpin for Rvsdg
impl UnwindSafe for Rvsdg
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more