⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 compress.cod

📁 microsoft visual c++ 2005、windows mobile 5 远程控制PC.通过阅读项目源码能让你熟悉Active Sync RAPI
💻 COD
字号:
; Listing generated by Microsoft (R) Optimizing Compiler Version 14.00.50727.762 

	TITLE	d:\src\VS2005\cpp\CeRemoteClient\zlib123\compress.c
	.686P
	.XMM
	include listing.inc
	.model	flat

INCLUDELIB OLDNAMES

PUBLIC	??_C@_05GDHACFMB@1?42?43?$AA@			; `string'
;	COMDAT ??_C@_05GDHACFMB@1?42?43?$AA@
CONST	SEGMENT
??_C@_05GDHACFMB@1?42?43?$AA@ DB '1.2.3', 00H		; `string'
PUBLIC	_compressBound@4
; Function compile flags: /Ogtpy
; File d:\src\vs2005\cpp\ceremoteclient\zlib123\compress.c
;	COMDAT _compressBound@4
_TEXT	SEGMENT
_sourceLen$ = 8						; size = 4
_compressBound@4 PROC					; COMDAT

; 78   :     return sourceLen + (sourceLen >> 12) + (sourceLen >> 14) + 11;

  00000	8b 44 24 04	 mov	 eax, DWORD PTR _sourceLen$[esp-4]
  00004	8b c8		 mov	 ecx, eax
  00006	8b d0		 mov	 edx, eax
  00008	c1 e9 0e	 shr	 ecx, 14			; 0000000eH
  0000b	c1 ea 0c	 shr	 edx, 12			; 0000000cH
  0000e	03 c8		 add	 ecx, eax
  00010	8d 44 0a 0b	 lea	 eax, DWORD PTR [edx+ecx+11]

; 79   : }

  00014	c2 04 00	 ret	 4
_compressBound@4 ENDP
PUBLIC	_compress2@20
; Function compile flags: /Ogtpy
;	COMDAT _compress2@20
_TEXT	SEGMENT
_stream$ = -56						; size = 56
_dest$ = 8						; size = 4
_destLen$ = 12						; size = 4
_source$ = 16						; size = 4
_sourceLen$ = 20					; size = 4
_level$ = 24						; size = 4
_compress2@20 PROC					; COMDAT

; 28   : {

  00000	55		 push	 ebp
  00001	8b ec		 mov	 ebp, esp
  00003	83 e4 f8	 and	 esp, -8			; fffffff8H
  00006	83 ec 38	 sub	 esp, 56			; 00000038H

; 29   :     z_stream stream;
; 30   :     int err;
; 31   : 
; 32   :     stream.next_in = (Bytef*)source;
; 33   :     stream.avail_in = (uInt)sourceLen;

  00009	8b 4d 14	 mov	 ecx, DWORD PTR _sourceLen$[ebp]

; 34   : #ifdef MAXSEG_64K
; 35   :     /* Check for source > 64K on 16-bit machine: */
; 36   :     if ((uLong)stream.avail_in != sourceLen) return Z_BUF_ERROR;
; 37   : #endif
; 38   :     stream.next_out = dest;

  0000c	8b 55 08	 mov	 edx, DWORD PTR _dest$[ebp]
  0000f	8b 45 10	 mov	 eax, DWORD PTR _source$[ebp]
  00012	53		 push	 ebx

; 39   :     stream.avail_out = (uInt)*destLen;

  00013	8b 5d 0c	 mov	 ebx, DWORD PTR _destLen$[ebp]
  00016	56		 push	 esi

; 40   :     if ((uLong)stream.avail_out != *destLen) return Z_BUF_ERROR;
; 41   : 
; 42   :     stream.zalloc = (alloc_func)0;
; 43   :     stream.zfree = (free_func)0;
; 44   :     stream.opaque = (voidpf)0;
; 45   : 
; 46   :     err = deflateInit(&stream, level);

  00017	6a 38		 push	 56			; 00000038H
  00019	89 4c 24 10	 mov	 DWORD PTR _stream$[esp+72], ecx
  0001d	8b 4d 18	 mov	 ecx, DWORD PTR _level$[ebp]
  00020	68 00 00 00 00	 push	 OFFSET ??_C@_05GDHACFMB@1?42?43?$AA@
  00025	89 54 24 1c	 mov	 DWORD PTR _stream$[esp+84], edx
  00029	89 44 24 10	 mov	 DWORD PTR _stream$[esp+72], eax
  0002d	8b 03		 mov	 eax, DWORD PTR [ebx]
  0002f	51		 push	 ecx
  00030	8d 54 24 14	 lea	 edx, DWORD PTR _stream$[esp+76]
  00034	52		 push	 edx
  00035	89 44 24 28	 mov	 DWORD PTR _stream$[esp+96], eax
  00039	c7 44 24 38 00
	00 00 00	 mov	 DWORD PTR _stream$[esp+112], 0
  00041	c7 44 24 3c 00
	00 00 00	 mov	 DWORD PTR _stream$[esp+116], 0
  00049	c7 44 24 40 00
	00 00 00	 mov	 DWORD PTR _stream$[esp+120], 0
  00051	e8 00 00 00 00	 call	 _deflateInit_@16

; 47   :     if (err != Z_OK) return err;

  00056	85 c0		 test	 eax, eax
  00058	75 40		 jne	 SHORT $LN4@compress2

; 48   : 
; 49   :     err = deflate(&stream, Z_FINISH);

  0005a	6a 04		 push	 4
  0005c	8d 44 24 0c	 lea	 eax, DWORD PTR _stream$[esp+68]
  00060	50		 push	 eax
  00061	e8 00 00 00 00	 call	 _deflate@8
  00066	8b f0		 mov	 esi, eax

; 50   :     if (err != Z_STREAM_END) {

  00068	83 fe 01	 cmp	 esi, 1
  0006b	74 1d		 je	 SHORT $LN1@compress2

; 51   :         deflateEnd(&stream);

  0006d	8d 4c 24 08	 lea	 ecx, DWORD PTR _stream$[esp+64]
  00071	51		 push	 ecx
  00072	e8 00 00 00 00	 call	 _deflateEnd@4

; 52   :         return err == Z_OK ? Z_BUF_ERROR : err;

  00077	85 f6		 test	 esi, esi
  00079	b8 fb ff ff ff	 mov	 eax, -5			; fffffffbH
  0007e	74 1a		 je	 SHORT $LN4@compress2
  00080	8b c6		 mov	 eax, esi

; 57   :     return err;
; 58   : }

  00082	5e		 pop	 esi
  00083	5b		 pop	 ebx
  00084	8b e5		 mov	 esp, ebp
  00086	5d		 pop	 ebp
  00087	c2 14 00	 ret	 20			; 00000014H
$LN1@compress2:

; 53   :     }
; 54   :     *destLen = stream.total_out;

  0008a	8b 54 24 1c	 mov	 edx, DWORD PTR _stream$[esp+84]

; 55   : 
; 56   :     err = deflateEnd(&stream);

  0008e	8d 44 24 08	 lea	 eax, DWORD PTR _stream$[esp+64]
  00092	50		 push	 eax
  00093	89 13		 mov	 DWORD PTR [ebx], edx
  00095	e8 00 00 00 00	 call	 _deflateEnd@4
$LN4@compress2:

; 57   :     return err;
; 58   : }

  0009a	5e		 pop	 esi
  0009b	5b		 pop	 ebx
  0009c	8b e5		 mov	 esp, ebp
  0009e	5d		 pop	 ebp
  0009f	c2 14 00	 ret	 20			; 00000014H
_compress2@20 ENDP
PUBLIC	_compress@16
; Function compile flags: /Ogtpy
;	COMDAT _compress@16
_TEXT	SEGMENT
_dest$ = 8						; size = 4
_destLen$ = 12						; size = 4
_source$ = 16						; size = 4
_sourceLen$ = 20					; size = 4
_compress@16 PROC					; COMDAT

; 68   :     return compress2(dest, destLen, source, sourceLen, Z_DEFAULT_COMPRESSION);

  00000	8b 44 24 10	 mov	 eax, DWORD PTR _sourceLen$[esp-4]
  00004	8b 4c 24 0c	 mov	 ecx, DWORD PTR _source$[esp-4]
  00008	8b 54 24 08	 mov	 edx, DWORD PTR _destLen$[esp-4]
  0000c	6a ff		 push	 -1
  0000e	50		 push	 eax
  0000f	8b 44 24 0c	 mov	 eax, DWORD PTR _dest$[esp+4]
  00013	51		 push	 ecx
  00014	52		 push	 edx
  00015	50		 push	 eax
  00016	e8 00 00 00 00	 call	 _compress2@20

; 69   : }

  0001b	c2 10 00	 ret	 16			; 00000010H
_compress@16 ENDP
END

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -