Composing compression and packed ranks #
All transfers into the two fixed workspaces are charged. Only the actual loaded header values supply node-dependent constants. The caller's registers and all memory are framed.
Main definitions #
NodeProgram.compressionInputs,NodeProgram.compress: workspace transfers and multiplier compression routine.NodeProgram.rankInputs,NodeProgram.rank,NodeProgram.sketchCut,NodeProgram.sketchQuery: workspace transfers, packed-rank routine, mathematical sketch cut, and combined compression-plus-rank query.
Main results #
NodeProgram.exec_compress: a bounded word is compressed in 102 instructions.NodeProgram.exec_rank: a compressed query is ranked in 17 instructions.
References #
Prepare the compression workspace and run the actual multiplier program.
Instances For
Seven transfers plus the terminal self-copy and 94 arithmetic instructions.
Transfer a compressed query and seven stored constants to a packed-rank workspace. The Boolean selects strict rank (original packed sketches) or inclusive rank (complements).
Instances For
Eight charged transfers followed by the chosen eight-instruction rank program.
Instances For
The rank call includes every transfer and preserves the caller and memory.
Compression followed by the requested sketch-rank convention.
Instances For
A complete sketch query, including all register transfers, takes 119 instructions.