Module anchors::singlethread[][src]

Singlethread is Anchors’ default execution engine. It’s a single threaded engine capable of both Adapton-style pull updates and — if mark_observed and mark_unobserved are used, Incremental-style push updates.

As of Semptember 2020, execution overhead per-node sits at around 100ns on this author’s Macbook Air, likely somewhat more if single node has a significant number of parents or children. Hopefully this will significantly improve over the coming months.

Structs

AnchorHandle

Singlethread’s implementation of Anchors’ AnchorHandle, the engine-specific handle that sits inside an Anchor.

AnchorToken
DirtyHandle

Singlethread’s implementation of Anchors’ DirtyHandle, which allows a node with non-Anchors inputs to manually mark itself as dirty.

Engine

The main execution engine of Singlethread.

Enums

ObservedState

Indicates whether the node is a part of some observed calculation.

Traits

AnchorExt

A trait automatically implemented for all Anchors. You’ll likely want to use this trait in most of your programs, since it can create many useful Anchors that derive their output incrementally from some other Anchors.

AnchorSplit

Type Definitions

Anchor

The main struct of the Anchors library. Represents a single value on the singlthread recomputation graph.

Constant

An Anchor for immutable values.

Var

An Anchor type for values that are mutated by calling a setter function from outside of the Anchors recomputation graph.

VarSetter

A setter that can update values inside an associated Var.