mirror of
https://github.com/intel/isa-l.git
synced 2024-12-12 17:33:50 +01:00
igzip: Fix update_histogram_base buffer finish
Change-Id: Ib74988a79baca7f5095447458d7374f834d1c138 Signed-off-by: Roy Oursler <roy.j.oursler@intel.com>
This commit is contained in:
parent
31204ae96e
commit
e8ca21baf4
@ -714,23 +714,10 @@ void isal_update_histogram_base(uint8_t * start_stream, int length,
|
||||
}
|
||||
lit_len_histogram[literal & 0xFF] += 1;
|
||||
}
|
||||
literal = literal >> 8;
|
||||
hash = compute_hash(literal) & LVL0_HASH_MASK;
|
||||
seen = last_seen[hash];
|
||||
last_seen[hash] = (current - start_stream) & 0xFFFF;
|
||||
dist = (current - start_stream - seen) & 0xFFFF;
|
||||
if (dist < D) {
|
||||
match_length = compare258(current - dist, current, end_stream - current);
|
||||
if (match_length >= SHORTEST_MATCH) {
|
||||
dist_histogram[convert_dist_to_dist_sym(dist)] += 1;
|
||||
lit_len_histogram[convert_length_to_len_sym(match_length)] += 1;
|
||||
lit_len_histogram[256] += 1;
|
||||
return;
|
||||
}
|
||||
} else
|
||||
lit_len_histogram[literal & 0xFF] += 1;
|
||||
lit_len_histogram[(literal >> 8) & 0xFF] += 1;
|
||||
lit_len_histogram[(literal >> 16) & 0xFF] += 1;
|
||||
|
||||
for (; current < end_stream; current++)
|
||||
lit_len_histogram[*current] += 1;
|
||||
|
||||
lit_len_histogram[256] += 1;
|
||||
return;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user