Lines Matching defs:cost
71 double* cost,
97 memset(cost, 0, sizeof(cost[0]) * num_histograms);
99 /* After each iteration of this loop, cost[k] will contain the difference
100 between the minimum cost of arriving at the current byte position using
101 entropy code k, and the minimum cost of arriving at the current byte
102 position. This difference is capped at the block switch cost, and if it
103 reaches block switch cost, it means that when we trace back from the last
114 cost[k] += insert_cost[insert_cost_ix + k];
115 if (cost[k] < min_cost) {
116 min_cost = cost[k];
125 cost[k] -= min_cost;
126 if (cost[k] >= block_switch_cost) {
128 cost[k] = block_switch_cost;
408 double* cost = BROTLI_ALLOC(m, double, num_histograms);
414 BROTLI_IS_NULL(insert_cost) || BROTLI_IS_NULL(cost) ||
422 insert_cost, cost, switch_signal,
430 BROTLI_FREE(m, cost);