亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? match.s

?? zlib源碼
?? S
字號:
/* match.s -- Pentium-optimized version of longest_match()
 * Written for zlib 1.1.2
 * Copyright (C) 1998 Brian Raiter <breadbox@muppetlabs.com>
 *
 * This is free software; you can redistribute it and/or modify it
 * under the terms of the GNU General Public License.
 */

#ifndef NO_UNDERLINE
#define	match_init	_match_init
#define	longest_match	_longest_match
#endif

#define	MAX_MATCH	(258)
#define	MIN_MATCH	(3)
#define	MIN_LOOKAHEAD	(MAX_MATCH + MIN_MATCH + 1)
#define	MAX_MATCH_8	((MAX_MATCH + 7) & ~7)

/* stack frame offsets */

#define	wmask			0	/* local copy of s->wmask	*/
#define	window			4	/* local copy of s->window	*/
#define	windowbestlen		8	/* s->window + bestlen		*/
#define	chainlenscanend		12	/* high word: current chain len	*/
					/* low word: last bytes sought	*/
#define	scanstart		16	/* first two bytes of string	*/
#define	scanalign		20	/* dword-misalignment of string	*/
#define	nicematch		24	/* a good enough match size	*/
#define	bestlen			28	/* size of best match so far	*/
#define	scan			32	/* ptr to string wanting match	*/

#define	LocalVarsSize		(36)
/*	saved ebx		36 */
/*	saved edi		40 */
/*	saved esi		44 */
/*	saved ebp		48 */
/*	return address		52 */
#define	deflatestate		56	/* the function arguments	*/
#define	curmatch		60

/* Offsets for fields in the deflate_state structure. These numbers
 * are calculated from the definition of deflate_state, with the
 * assumption that the compiler will dword-align the fields. (Thus,
 * changing the definition of deflate_state could easily cause this
 * program to crash horribly, without so much as a warning at
 * compile time. Sigh.)
 */
#define	dsWSize			36
#define	dsWMask			44
#define	dsWindow		48
#define	dsPrev			56
#define	dsMatchLen		88
#define	dsPrevMatch		92
#define	dsStrStart		100
#define	dsMatchStart		104
#define	dsLookahead		108
#define	dsPrevLen		112
#define	dsMaxChainLen		116
#define	dsGoodMatch		132
#define	dsNiceMatch		136


.file "match.S"

.globl	match_init, longest_match

.text

/* uInt longest_match(deflate_state *deflatestate, IPos curmatch) */

longest_match:

/* Save registers that the compiler may be using, and adjust %esp to	*/
/* make room for our stack frame.					*/

		pushl	%ebp
		pushl	%edi
		pushl	%esi
		pushl	%ebx
		subl	$LocalVarsSize, %esp

/* Retrieve the function arguments. %ecx will hold cur_match		*/
/* throughout the entire function. %edx will hold the pointer to the	*/
/* deflate_state structure during the function's setup (before		*/
/* entering the main loop).						*/

		movl	deflatestate(%esp), %edx
		movl	curmatch(%esp), %ecx

/* if ((uInt)nice_match > s->lookahead) nice_match = s->lookahead;	*/

		movl	dsNiceMatch(%edx), %eax
		movl	dsLookahead(%edx), %ebx
		cmpl	%eax, %ebx
		jl	LookaheadLess
		movl	%eax, %ebx
LookaheadLess:	movl	%ebx, nicematch(%esp)

/* register Bytef *scan = s->window + s->strstart;			*/

		movl	dsWindow(%edx), %esi
		movl	%esi, window(%esp)
		movl	dsStrStart(%edx), %ebp
		lea	(%esi,%ebp), %edi
		movl	%edi, scan(%esp)

/* Determine how many bytes the scan ptr is off from being		*/
/* dword-aligned.							*/

		movl	%edi, %eax
		negl	%eax
		andl	$3, %eax
		movl	%eax, scanalign(%esp)

/* IPos limit = s->strstart > (IPos)MAX_DIST(s) ?			*/
/*     s->strstart - (IPos)MAX_DIST(s) : NIL;				*/

		movl	dsWSize(%edx), %eax
		subl	$MIN_LOOKAHEAD, %eax
		subl	%eax, %ebp
		jg	LimitPositive
		xorl	%ebp, %ebp
LimitPositive:

/* unsigned chain_length = s->max_chain_length;				*/
/* if (s->prev_length >= s->good_match) {				*/
/*     chain_length >>= 2;						*/
/* }									*/

		movl	dsPrevLen(%edx), %eax
		movl	dsGoodMatch(%edx), %ebx
		cmpl	%ebx, %eax
		movl	dsMaxChainLen(%edx), %ebx
		jl	LastMatchGood
		shrl	$2, %ebx
LastMatchGood:

/* chainlen is decremented once beforehand so that the function can	*/
/* use the sign flag instead of the zero flag for the exit test.	*/
/* It is then shifted into the high word, to make room for the scanend	*/
/* scanend value, which it will always accompany.			*/

		decl	%ebx
		shll	$16, %ebx

/* int best_len = s->prev_length;					*/

		movl	dsPrevLen(%edx), %eax
		movl	%eax, bestlen(%esp)

/* Store the sum of s->window + best_len in %esi locally, and in %esi.	*/

		addl	%eax, %esi
		movl	%esi, windowbestlen(%esp)

/* register ush scan_start = *(ushf*)scan;				*/
/* register ush scan_end   = *(ushf*)(scan+best_len-1);			*/

		movw	(%edi), %bx
		movw	%bx, scanstart(%esp)
		movw	-1(%edi,%eax), %bx
		movl	%ebx, chainlenscanend(%esp)

/* Posf *prev = s->prev;						*/
/* uInt wmask = s->w_mask;						*/

		movl	dsPrev(%edx), %edi
		movl	dsWMask(%edx), %edx
		mov	%edx, wmask(%esp)

/* Jump into the main loop.						*/

		jmp	LoopEntry

.balign 16

/* do {
 *     match = s->window + cur_match;
 *     if (*(ushf*)(match+best_len-1) != scan_end ||
 *         *(ushf*)match != scan_start) continue;
 *     [...]
 * } while ((cur_match = prev[cur_match & wmask]) > limit
 *          && --chain_length != 0);
 *
 * Here is the inner loop of the function. The function will spend the
 * majority of its time in this loop, and majority of that time will
 * be spent in the first ten instructions.
 *
 * Within this loop:
 * %ebx = chainlenscanend - i.e., ((chainlen << 16) | scanend)
 * %ecx = curmatch
 * %edx = curmatch & wmask
 * %esi = windowbestlen - i.e., (window + bestlen)
 * %edi = prev
 * %ebp = limit
 *
 * Two optimization notes on the choice of instructions:
 *
 * The first instruction uses a 16-bit address, which costs an extra,
 * unpairable cycle. This is cheaper than doing a 32-bit access and
 * zeroing the high word, due to the 3-cycle misalignment penalty which
 * would occur half the time. This also turns out to be cheaper than
 * doing two separate 8-bit accesses, as the memory is so rarely in the
 * L1 cache.
 *
 * The window buffer, however, apparently spends a lot of time in the
 * cache, and so it is faster to retrieve the word at the end of the
 * match string with two 8-bit loads. The instructions that test the
 * word at the beginning of the match string, however, are executed
 * much less frequently, and there it was cheaper to use 16-bit
 * instructions, which avoided the necessity of saving off and
 * subsequently reloading one of the other registers.
 */
LookupLoop:
							/* 1 U & V  */
		movw	(%edi,%edx,2), %cx		/* 2 U pipe */
		movl	wmask(%esp), %edx		/* 2 V pipe */
		cmpl	%ebp, %ecx			/* 3 U pipe */
		jbe	LeaveNow			/* 3 V pipe */
		subl	$0x00010000, %ebx		/* 4 U pipe */
		js	LeaveNow			/* 4 V pipe */
LoopEntry:	movb	-1(%esi,%ecx), %al		/* 5 U pipe */
		andl	%ecx, %edx			/* 5 V pipe */
		cmpb	%bl, %al			/* 6 U pipe */
		jnz	LookupLoop			/* 6 V pipe */
		movb	(%esi,%ecx), %ah
		cmpb	%bh, %ah
		jnz	LookupLoop
		movl	window(%esp), %eax
		movw	(%eax,%ecx), %ax
		cmpw	scanstart(%esp), %ax
		jnz	LookupLoop

/* Store the current value of chainlen.					*/

		movl	%ebx, chainlenscanend(%esp)

/* Point %edi to the string under scrutiny, and %esi to the string we	*/
/* are hoping to match it up with. In actuality, %esi and %edi are	*/
/* both pointed (MAX_MATCH_8 - scanalign) bytes ahead, and %edx is	*/
/* initialized to -(MAX_MATCH_8 - scanalign).				*/

		movl	window(%esp), %esi
		movl	scan(%esp), %edi
		addl	%ecx, %esi
		movl	scanalign(%esp), %eax
		movl	$(-MAX_MATCH_8), %edx
		lea	MAX_MATCH_8(%edi,%eax), %edi
		lea	MAX_MATCH_8(%esi,%eax), %esi

/* Test the strings for equality, 8 bytes at a time. At the end,
 * adjust %edx so that it is offset to the exact byte that mismatched.
 *
 * We already know at this point that the first three bytes of the
 * strings match each other, and they can be safely passed over before
 * starting the compare loop. So what this code does is skip over 0-3
 * bytes, as much as necessary in order to dword-align the %edi
 * pointer. (%esi will still be misaligned three times out of four.)
 *
 * It should be confessed that this loop usually does not represent
 * much of the total running time. Replacing it with a more
 * straightforward "rep cmpsb" would not drastically degrade
 * performance.
 */
LoopCmps:
		movl	(%esi,%edx), %eax
		movl	(%edi,%edx), %ebx
		xorl	%ebx, %eax
		jnz	LeaveLoopCmps
		movl	4(%esi,%edx), %eax
		movl	4(%edi,%edx), %ebx
		xorl	%ebx, %eax
		jnz	LeaveLoopCmps4
		addl	$8, %edx
		jnz	LoopCmps
		jmp	LenMaximum
LeaveLoopCmps4:	addl	$4, %edx
LeaveLoopCmps:	testl	$0x0000FFFF, %eax
		jnz	LenLower
		addl	$2, %edx
		shrl	$16, %eax
LenLower:	subb	$1, %al
		adcl	$0, %edx

/* Calculate the length of the match. If it is longer than MAX_MATCH,	*/
/* then automatically accept it as the best possible match and leave.	*/

		lea	(%edi,%edx), %eax
		movl	scan(%esp), %edi
		subl	%edi, %eax
		cmpl	$MAX_MATCH, %eax
		jge	LenMaximum

/* If the length of the match is not longer than the best match we	*/
/* have so far, then forget it and return to the lookup loop.		*/

		movl	deflatestate(%esp), %edx
		movl	bestlen(%esp), %ebx
		cmpl	%ebx, %eax
		jg	LongerMatch
		movl	chainlenscanend(%esp), %ebx
		movl	windowbestlen(%esp), %esi
		movl	dsPrev(%edx), %edi
		movl	wmask(%esp), %edx
		andl	%ecx, %edx
		jmp	LookupLoop

/*         s->match_start = cur_match;					*/
/*         best_len = len;						*/
/*         if (len >= nice_match) break;				*/
/*         scan_end = *(ushf*)(scan+best_len-1);			*/

LongerMatch:	movl	nicematch(%esp), %ebx
		movl	%eax, bestlen(%esp)
		movl	%ecx, dsMatchStart(%edx)
		cmpl	%ebx, %eax
		jge	LeaveNow
		movl	window(%esp), %esi
		addl	%eax, %esi
		movl	%esi, windowbestlen(%esp)
		movl	chainlenscanend(%esp), %ebx
		movw	-1(%edi,%eax), %bx
		movl	dsPrev(%edx), %edi
		movl	%ebx, chainlenscanend(%esp)
		movl	wmask(%esp), %edx
		andl	%ecx, %edx
		jmp	LookupLoop

/* Accept the current string, with the maximum possible length.		*/

LenMaximum:	movl	deflatestate(%esp), %edx
		movl	$MAX_MATCH, bestlen(%esp)
		movl	%ecx, dsMatchStart(%edx)

/* if ((uInt)best_len <= s->lookahead) return (uInt)best_len;		*/
/* return s->lookahead;							*/

LeaveNow:
		movl	deflatestate(%esp), %edx
		movl	bestlen(%esp), %ebx
		movl	dsLookahead(%edx), %eax
		cmpl	%eax, %ebx
		jg	LookaheadRet
		movl	%ebx, %eax
LookaheadRet:

/* Restore the stack and return from whence we came.			*/

		addl	$LocalVarsSize, %esp
		popl	%ebx
		popl	%esi
		popl	%edi
		popl	%ebp
match_init:	ret

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
国产高清精品在线| 欧美大肚乱孕交hd孕妇| 国产精品久久久一本精品| 激情五月婷婷综合网| 欧美日韩美少妇| 亚洲色图视频网| av在线免费不卡| 亚洲欧美日韩中文播放| 欧美在线不卡视频| 亚洲成人激情社区| 91精品国产欧美一区二区成人| 天堂久久一区二区三区| 日韩精品一区二| 成人综合在线视频| 一区二区三区高清在线| 精品视频全国免费看| 日韩av高清在线观看| 精品国产免费视频| 国产精品一区二区视频| 亚洲va国产天堂va久久en| 884aa四虎影成人精品一区| 国产综合色在线视频区| 亚洲欧洲日产国产综合网| 欧美亚洲高清一区| 黑人巨大精品欧美一区| 久久免费视频一区| 成人在线视频首页| 亚洲一二三四区| 欧美va亚洲va香蕉在线| av电影在线观看完整版一区二区| 亚洲午夜成aⅴ人片| 亚洲精品一区二区三区在线观看| 波多野结衣在线一区| 天堂午夜影视日韩欧美一区二区| 国产偷国产偷精品高清尤物| 一个色在线综合| 久久综合久久99| 欧美亚洲国产怡红院影院| 久久99精品国产麻豆婷婷| 亚洲欧美日韩人成在线播放| 精品少妇一区二区三区日产乱码| 色呦呦国产精品| 精品无码三级在线观看视频| 一区二区三区在线高清| 久久久影视传媒| 欧美日韩一区二区三区免费看| 国产精品亚洲一区二区三区妖精| 亚洲国产成人porn| 国产精品久久久久7777按摩| 日韩你懂的电影在线观看| 91女神在线视频| 国产乱人伦偷精品视频不卡| 亚洲一区二区av在线| 久久久久国产免费免费| 欧美人动与zoxxxx乱| 91九色02白丝porn| 极品少妇一区二区三区精品视频 | 欧美三级三级三级| 成人激情小说乱人伦| 日本亚洲欧美天堂免费| 亚洲国产视频a| 亚洲欧美影音先锋| 欧美激情中文字幕一区二区| 欧美日韩亚洲另类| 91视频www| 成人h动漫精品| 国产麻豆成人精品| 韩国三级在线一区| 另类小说综合欧美亚洲| 免费久久精品视频| 日本亚洲电影天堂| 蜜臀99久久精品久久久久久软件| 一区二区三区中文字幕电影| 国产精品成人免费精品自在线观看 | 日韩福利视频网| 亚洲成人黄色小说| 亚洲国产欧美在线人成| 亚洲综合图片区| 樱花影视一区二区| 专区另类欧美日韩| 亚洲品质自拍视频| 亚洲欧美电影一区二区| 国产精品天美传媒| 久久精品亚洲精品国产欧美kt∨ | 在线视频欧美区| 91成人在线观看喷潮| 91啦中文在线观看| 91久久精品一区二区二区| 日本韩国精品在线| 欧美色老头old∨ideo| 7777精品久久久大香线蕉| 51久久夜色精品国产麻豆| 欧美一区二区精美| 久久午夜羞羞影院免费观看| 国产三级欧美三级日产三级99 | 日韩av电影天堂| 麻豆精品在线视频| 国产一区二区三区免费看| 国产一区二区视频在线播放| 国产大陆a不卡| 91欧美一区二区| 欧美精品乱码久久久久久按摩| 在线成人av网站| 久久久久久黄色| 自拍偷拍欧美激情| 午夜久久久久久电影| 精品一区二区三区在线视频| 国产不卡在线一区| 在线视频欧美精品| 久久综合狠狠综合久久综合88| 国产无一区二区| 亚洲综合小说图片| 国产精品综合一区二区三区| 99国产精品国产精品久久| 欧美日韩国产精品自在自线| 亚洲人妖av一区二区| 日韩高清不卡一区二区三区| 成人免费av在线| 制服丝袜亚洲精品中文字幕| 国产女主播一区| 亚洲韩国一区二区三区| 久久99精品久久久久久久久久久久 | 亚洲欧洲一区二区在线播放| 亚洲欧洲成人av每日更新| 午夜亚洲福利老司机| 国产在线国偷精品免费看| 99re这里只有精品6| 欧美高清性hdvideosex| 国产欧美久久久精品影院| 亚洲高清不卡在线观看| 懂色av一区二区三区蜜臀| 欧美性生活影院| 久久久91精品国产一区二区精品 | 热久久久久久久| aa级大片欧美| 欧美精品一区二区三区高清aⅴ| 国产精品色婷婷久久58| 日本视频一区二区三区| 99久久亚洲一区二区三区青草| 欧美一区二区在线免费播放| 成人免费小视频| 国产麻豆91精品| 欧美一区二区三区公司| 国产精品免费视频观看| 日韩在线卡一卡二| 色一情一伦一子一伦一区| 久久久噜噜噜久久中文字幕色伊伊| 亚洲va天堂va国产va久| caoporen国产精品视频| 久久色在线观看| 日本视频一区二区三区| 欧美日韩另类国产亚洲欧美一级| **欧美大码日韩| 国产91丝袜在线播放| 久久久亚洲国产美女国产盗摄| av一二三不卡影片| 久久亚洲精品国产精品紫薇| 日韩国产成人精品| 91丨九色丨尤物| 久久久精品天堂| 国产中文字幕精品| 久久中文娱乐网| 国产精品2024| 国产亚洲欧美日韩日本| 国产在线麻豆精品观看| 欧美变态tickling挠脚心| 精品一区二区三区视频| 日韩你懂的电影在线观看| 捆绑调教一区二区三区| 精品国产乱码久久久久久1区2区| 日韩国产一二三区| 91麻豆精品国产| 捆绑调教一区二区三区| 精品美女在线观看| 国产精品综合一区二区| 国产精品入口麻豆原神| 国产成人精品亚洲777人妖| 欧美韩国日本不卡| 91亚洲午夜精品久久久久久| 亚洲欧洲99久久| 欧美性生交片4| 毛片基地黄久久久久久天堂| 欧美精品免费视频| 精品在线一区二区| 欧美国产精品专区| 91亚洲男人天堂| 亚洲国产综合在线| 精品剧情在线观看| 高清国产午夜精品久久久久久| 国产精品欧美一区二区三区| 色吧成人激情小说| 亚洲chinese男男1069| 欧美tk丨vk视频| 国产精品1区二区.| 中国色在线观看另类| 91一区二区在线| 亚洲成人av中文| 日韩免费观看高清完整版| 国产精品自产自拍| 中文字幕中文在线不卡住|