IMPORTANT: To view this page as Markdown, append `.md` to the URL (e.g. /docs/manual/basics.md). For the complete Mojo documentation index, see llms.txt.
Skip to main content
Version: Nightly
For the complete Mojo documentation index, see llms.txt. Markdown versions of all pages are available by appending .md to any URL (e.g. /docs/manual/basics.md).

DeviceGraphNode

struct DeviceGraphNode

A handle to a node in an under-construction device graph.

Returned by node-adding methods on DeviceGraphBuilder such as add_function, add_copy, and add_memset. The handle can be used to refer to the node from later API calls (for example, when expressing explicit dependency edges).

Fields

  • id (Int32): Opaque integer identifier of the node within its graph builder.

Implemented traits

AnyType, Copyable, ImplicitlyCopyable, ImplicitlyDestructible, Movable, RegisterPassable, TrivialRegisterPassable, Writable

Methods

write_to

def write_to(self, mut writer: T)

Writes a human-readable representation of this node handle.

Args:

  • writer (T): The writer to output to.