1 /* stats1a.h -- statistics for the the LZO1A algorithm
3 This file is part of the LZO real-time data compression library.
5 Copyright (C) 1996-2014 Markus Franz Xaver Johannes Oberhumer
8 The LZO library is free software; you can redistribute it and/or
9 modify it under the terms of the GNU General Public License as
10 published by the Free Software Foundation; either version 2 of
11 the License, or (at your option) any later version.
13 The LZO library is distributed in the hope that it will be useful,
14 but WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 GNU General Public License for more details.
18 You should have received a copy of the GNU General Public License
19 along with the LZO library; see the file COPYING.
20 If not, write to the Free Software Foundation, Inc.,
21 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
23 Markus F.X.J. Oberhumer
24 <markus@oberhumer.com>
25 http://www.oberhumer.com/opensource/lzo/
29 /* WARNING: this file should *not* be used by applications. It is
30 part of the implementation of the LZO package and is subject
35 #ifndef __LZO_STATS1A_H
36 #define __LZO_STATS1A_H 1
44 /***********************************************************************
45 // collect statistical information when compressing
46 // used for finetuning, view with a debugger
47 ************************************************************************/
49 #if (LZO_COLLECT_STATS)
50 # define LZO_STATS(expr) expr
52 # define LZO_STATS(expr) ((void) 0)
56 /***********************************************************************
58 ************************************************************************/
66 /* internal configuration */
71 unsigned min_match_short
;
72 unsigned max_match_short
;
73 unsigned min_match_long
;
74 unsigned max_match_long
;
86 long lit_runs_after_long_match
;
93 long lit_run_after_long_match
[RSIZE
];
94 long short_match
[MAX_MATCH_SHORT
+ 1];
95 long long_match
[MAX_MATCH_LONG
+ 1];
98 /* these could prove useful for further optimizations */
99 long short_match_offset_osize
[MAX_MATCH_SHORT
+ 1];
100 long short_match_offset_256
[MAX_MATCH_SHORT
+ 1];
101 long short_match_offset_1024
[MAX_MATCH_SHORT
+ 1];
102 long matches_out_of_range
;
103 long matches_out_of_range_2
;
104 long matches_out_of_range_4
;
105 long match_out_of_range
[MAX_MATCH_SHORT
+ 1];
113 extern lzo1a_stats_t
*lzo1a_stats
;
121 #endif /* already included */