source: nikanabo/current/xdelta/diy/xdelta3-cfgs.h@ 407

Last change on this file since 407 was 185, checked in by geyser, 18 years ago
File size: 3.9 KB
RevLine 
[185]1/* xdelta 3 - delta compression tools and library
2 * Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007. Joshua P. MacDonald
3 *
4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License as published by
6 * the Free Software Foundation; either version 2 of the License, or
7 * (at your option) any later version.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program; if not, write to the Free Software
16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17 */
18
19/******************************************************************************************
20 SOFT string matcher
21 ******************************************************************************************/
22
23#if XD3_BUILD_SOFT
24
25#define TEMPLATE soft
26#define LLOOK stream->smatcher.large_look
27#define LSTEP stream->smatcher.large_step
28#define SLOOK stream->smatcher.small_look
29#define SCHAIN stream->smatcher.small_chain
30#define SLCHAIN stream->smatcher.small_lchain
31#define MAXLAZY stream->smatcher.max_lazy
32#define LONGENOUGH stream->smatcher.long_enough
33
34#define SOFTCFG 1
35#include "xdelta3.c"
36#undef SOFTCFG
37
38#undef TEMPLATE
39#undef LLOOK
40#undef SLOOK
41#undef LSTEP
42#undef SCHAIN
43#undef SLCHAIN
44#undef MAXLAZY
45#undef LONGENOUGH
46#endif
47
48#define SOFTCFG 0
49
50/******************************************************************************************
51 FASTEST string matcher
52 ******************************************************************************************/
53#if XD3_BUILD_FASTEST
54#define TEMPLATE fastest
55#define LLOOK 9
56#define LSTEP 15
57#define SLOOK 4
58#define SCHAIN 1
59#define SLCHAIN 1
60#define MAXLAZY 18
61#define LONGENOUGH 18
62
63#include "xdelta3.c"
64
65#undef TEMPLATE
66#undef LLOOK
67#undef SLOOK
68#undef LSTEP
69#undef SCHAIN
70#undef SLCHAIN
71#undef MAXLAZY
72#undef LONGENOUGH
73#endif
74
75/******************************************************************************************
76 FAST string matcher
77 ******************************************************************************************/
78#if XD3_BUILD_FAST
79#define TEMPLATE fast
80#define LLOOK 9
81#define LSTEP 8
82#define SLOOK 4
83#define SCHAIN 4
84#define SLCHAIN 1
85#define MAXLAZY 18
86#define LONGENOUGH 35
87
88#include "xdelta3.c"
89
90#undef TEMPLATE
91#undef LLOOK
92#undef SLOOK
93#undef LSTEP
94#undef SCHAIN
95#undef SLCHAIN
96#undef MAXLAZY
97#undef LONGENOUGH
98#endif
99
100/******************************************************************************************
101 SLOW string matcher
102 ******************************************************************************************/
103#if XD3_BUILD_SLOW
104#define TEMPLATE slow
105#define LLOOK 9
106#define LSTEP 2
107#define SLOOK 4
108#define SCHAIN 44
109#define SLCHAIN 13
110#define MAXLAZY 90
111#define LONGENOUGH 70
112
113#include "xdelta3.c"
114
115#undef TEMPLATE
116#undef LLOOK
117#undef SLOOK
118#undef LSTEP
119#undef SCHAIN
120#undef SLCHAIN
121#undef MAXLAZY
122#undef LONGENOUGH
123#endif
124
125/******************************************************************************************
126 DEFAULT string matcher
127 ******************************************************************************************/
128#if XD3_BUILD_DEFAULT
129#define TEMPLATE default
130#define LLOOK 9
131#define LSTEP 3
132#define SLOOK 4
133#define SCHAIN 8
134#define SLCHAIN 2
135#define MAXLAZY 36
136#define LONGENOUGH 70
137
138#include "xdelta3.c"
139
140#undef TEMPLATE
141#undef LLOOK
142#undef SLOOK
143#undef LSTEP
144#undef SCHAIN
145#undef SLCHAIN
146#undef MAXLAZY
147#undef LONGENOUGH
148#endif
Note: See TracBrowser for help on using the repository browser.