Skip to main content

Module tag

Module tag 

Source
Expand description

Opaque SHA-lane tag encoding for fused WOTS tasks.

The compression lane must preserve all 32 bits without interpreting them. This module is the sole authority for their layout:

BitsWidthMeaning
0..=34scheduler context
4..=63TaskKind
7..=137WOTS segment or mask index
14..=174chain step
18..=236SHA/public-key block index
24..=318context generation/sequence

Structs§

DecodedTaskTag
Host-side decoded representation of an opaque task tag.
TagFields
Unpacked fields consumed and produced by RHDL tag kernels.

Enums§

TaskKind
Compression task classes in their fixed three-bit wire encoding.
TaskTagError
Error returned while decoding or constructing an opaque task tag.

Constants§

BLOCK_INDEX_SHIFT
Shift of the block-index field in a task tag.
CHAIN_STEP_SHIFT
Shift of the chain-step field in a task tag.
CONTEXT_SHIFT
Shift of the context field in a task tag.
GENERATION_SHIFT
Shift of the generation field in a task tag.
KIND_SHIFT
Shift of the task-kind field in a task tag.
SEGMENT_SHIFT
Shift of the segment field in a task tag.
TASK_TAG_BITS
Number of bits in the opaque compression-lane tag.

Functions§

decode_tag_kernel
Unpack an opaque SHA-lane tag without changing any bit.
decode_task_tag
Decode and validate a host-side opaque task tag.
encode_tag_kernel
Pack all tag fields into the fixed 32-bit SHA-lane representation.
hardware_fields
Convert host-side decoded fields to the RHDL representation.
software_fields
Convert RHDL tag fields to their host-side numeric representation.
tag_is_well_formed_kernel
Return whether a tag uses the canonical bounds for its task class.