MCPcopy Create free account
hub / github.com/antirez/ds4 / spec_frontier_commit_prefix1

Function spec_frontier_commit_prefix1

ds4.c:24137–24162  ·  view source on GitHub ↗

Commit the prefix-1 state captured by the N=2 speculative verifier. * * The verifier has already advanced every layer through both draft tokens. On * a one-token accept the append-only compressed caches can keep the second * speculative row as invisible garbage, but the compressor frontiers and row * counters must be rewound to the exact state after draft[0]. This is the * cheap partial-ac

Source from the content-addressed store, hash-verified

24135 (void)pre_m5_disable_env;
24136 (void)m5_disable_env;
24137 return false;
24138#endif
24139}
24140
24141/* Deferred HC expand support (see ds4_gpu_graph::hc_expand_pending). */
24142static bool metal_graph_flush_hc_expand(ds4_gpu_graph *g) {
24143 if (!g->hc_expand_pending) return true;
24144 g->hc_expand_pending = false;
24145 return ds4_gpu_hc_expand_add_tensor(g->hc_expand_out,
24146 g->hc_expand_block_out,
24147 g->hc_expand_block_add,
24148 g->hc_expand_residual,
24149 g->hc_expand_post,
24150 g->hc_expand_comb,
24151 DS4_N_EMBD, DS4_N_HC) != 0;
24152}
24153
24154static void metal_graph_defer_hc_expand(
24155 ds4_gpu_graph *g,
24156 ds4_gpu_tensor *out_hc,
24157 const ds4_gpu_tensor *block_out,
24158 const ds4_gpu_tensor *block_add,
24159 const ds4_gpu_tensor *residual_hc,
24160 const ds4_gpu_tensor *post,
24161 const ds4_gpu_tensor *comb) {
24162 g->hc_expand_pending = true;
24163 g->hc_expand_out = out_hc;
24164 g->hc_expand_block_out = block_out;
24165 g->hc_expand_block_add = block_add;

Callers 1

Calls 1

ds4_layer_compress_ratioFunction · 0.85

Tested by

no test coverage detected