* details.
*
* You should have received a copy of the GNU Lesser General Public License
- * along with this file; if not, see http://www.gnu.org/licenses/.
+ * along with this file; if not, see https://www.gnu.org/licenses/.
*/
#include "wimlib/compress_common.h"
#include "wimlib/compressor_ops.h"
#include "wimlib/error.h"
-#include "wimlib/lz_extend.h"
#include "wimlib/lzx_common.h"
#include "wimlib/unaligned.h"
#include "wimlib/util.h"
u32 adjusted_offset_and_mainsym;
#define SEQ_MAINSYM_BITS 10
#define SEQ_MAINSYM_MASK (((u32)1 << SEQ_MAINSYM_BITS) - 1)
-} _aligned_attribute(8);
+} __attribute__((aligned(8)));
/*
* This structure represents a byte position in the input buffer and a node in
# define OPTIMUM_GAP_MATCH 0x80000000
#endif
-} _aligned_attribute(8);
+} __attribute__((aligned(8)));
/* The cost model for near-optimal parsing */
struct lzx_costs {
* but rather we combine many symbols into a single "observation type". For
* literals we only look at the high bits and low bits, and for matches we only
* look at whether the match is long or not. The assumption is that for typical
- * "real" data, places that are good block boundaries will tend to be noticable
+ * "real" data, places that are good block boundaries will tend to be noticeable
* based only on changes in these aggregate frequencies, without looking for
* subtle differences in individual symbols. For example, a change from ASCII
* bytes to non-ASCII bytes, or from few matches (generally less compressible)
*/
struct lzx_lru_queue {
u64 R;
-} _aligned_attribute(8);
+} __attribute__((aligned(8)));
#define LZX_QUEUE_OFFSET_SHIFT 21
#define LZX_QUEUE_OFFSET_MASK (((u64)1 << LZX_QUEUE_OFFSET_SHIFT) - 1)
} else {
/* Don't search for matches at this position. */
CALL_BT_MF(is_16_bit, c,
- bt_matchfinder_skip_position,
+ bt_matchfinder_skip_byte,
in_begin,
in_next - in_begin,
nice_len,
cur_len = CALL_HC_MF(is_16_bit, c,
hc_matchfinder_longest_match,
in_begin,
- in_next - in_begin,
+ in_next,
2,
max_len,
nice_len,
next_len = CALL_HC_MF(is_16_bit, c,
hc_matchfinder_longest_match,
in_begin,
- in_next - in_begin,
+ in_next,
cur_len - 2,
max_len,
nice_len,
lzx_choose_match(c, cur_len, cur_adjusted_offset,
recent_offsets, is_16_bit,
&litrunlen, &next_seq);
- in_next = CALL_HC_MF(is_16_bit, c,
- hc_matchfinder_skip_positions,
- in_begin,
- in_next - in_begin,
- in_end - in_begin,
- skip_len,
- next_hashes);
+ CALL_HC_MF(is_16_bit, c,
+ hc_matchfinder_skip_bytes,
+ in_begin,
+ in_next,
+ in_end,
+ skip_len,
+ next_hashes);
+ in_next += skip_len;
/* Keep going until it's time to end the block. */
} while (in_next < in_max_block_end &&