1 ; Listing generated by Microsoft (R) Optimizing Compiler Version 16.00.30319.01
\r
3 TITLE C:\Workspaces\Sysdyn\org.simantics.fmu\FMUSolution\zlib-1.2.6\crc32.c
\r
2060 ; Function compile flags: /Ogtp
\r
2061 ; File c:\workspaces\sysdyn\org.simantics.fmu\fmusolution\zlib-1.2.6\crc32.c
\r
2062 ; COMDAT _gf2_matrix_times
\r
2064 _gf2_matrix_times PROC ; COMDAT
\r
2068 ; 353 : unsigned long sum;
\r
2072 00000 33 c0 xor eax, eax
\r
2074 ; 356 : while (vec) {
\r
2076 00002 85 c9 test ecx, ecx
\r
2077 00004 74 0e je SHORT $LN2@gf2_matrix
\r
2080 ; 357 : if (vec & 1)
\r
2082 00006 f6 c1 01 test cl, 1
\r
2083 00009 74 02 je SHORT $LN1@gf2_matrix
\r
2085 ; 358 : sum ^= *mat;
\r
2087 0000b 33 02 xor eax, DWORD PTR [edx]
\r
2090 ; 359 : vec >>= 1;
\r
2093 0000d 83 c2 04 add edx, 4
\r
2094 00010 d1 e9 shr ecx, 1
\r
2095 00012 75 f2 jne SHORT $LL3@gf2_matrix
\r
2099 ; 362 : return sum;
\r
2103 _gf2_matrix_times ENDP
\r
2104 ; Function compile flags: /Ogtp
\r
2106 ; COMDAT _crc32_big
\r
2108 _crc32_big PROC ; COMDAT
\r
2116 00001 8b f2 mov esi, edx
\r
2119 ; 314 : register u4 c;
\r
2120 ; 315 : register const u4 FAR *buf4;
\r
2122 ; 317 : c = REV((u4)crc);
\r
2124 00004 8b d0 mov edx, eax
\r
2125 00006 81 e2 00 ff 00
\r
2126 00 and edx, 65280 ; 0000ff00H
\r
2130 0000c 8b f8 mov edi, eax
\r
2131 0000e c1 e7 10 shl edi, 16 ; 00000010H
\r
2132 00011 03 d7 add edx, edi
\r
2133 00013 8b f8 mov edi, eax
\r
2134 00015 c1 e2 08 shl edx, 8
\r
2135 00018 c1 ef 08 shr edi, 8
\r
2136 0001b 81 e7 00 ff 00
\r
2137 00 and edi, 65280 ; 0000ff00H
\r
2138 00021 03 d7 add edx, edi
\r
2139 00023 c1 e8 18 shr eax, 24 ; 00000018H
\r
2140 00026 03 d0 add edx, eax
\r
2141 00028 f7 d2 not edx
\r
2143 ; 319 : while (len && ((ptrdiff_t)buf & 3)) {
\r
2145 0002a 85 f6 test esi, esi
\r
2146 0002c 74 1f je SHORT $LN9@crc32_big
\r
2147 0002e 8b ff npad 2
\r
2149 00030 f6 c1 03 test cl, 3
\r
2150 00033 74 18 je SHORT $LN9@crc32_big
\r
2152 ; 320 : c = crc_table[4][(c >> 24) ^ *buf++] ^ (c << 8);
\r
2154 00035 0f b6 39 movzx edi, BYTE PTR [ecx]
\r
2155 00038 8b c2 mov eax, edx
\r
2156 0003a c1 e8 18 shr eax, 24 ; 00000018H
\r
2157 0003d 33 c7 xor eax, edi
\r
2158 0003f c1 e2 08 shl edx, 8
\r
2159 00042 33 14 85 00 10
\r
2160 00 00 xor edx, DWORD PTR _crc_table[eax*4+4096]
\r
2166 0004b 75 e3 jne SHORT $LL10@crc32_big
\r
2172 ; 324 : buf4 = (const u4 FAR *)(const void FAR *)buf;
\r
2175 0004e 8d 41 fc lea eax, DWORD PTR [ecx-4]
\r
2177 ; 326 : while (len >= 32) {
\r
2179 00051 83 fe 20 cmp esi, 32 ; 00000020H
\r
2180 00054 0f 82 12 02 00
\r
2181 00 jb $LN15@crc32_big
\r
2185 ; 324 : buf4 = (const u4 FAR *)(const void FAR *)buf;
\r
2188 0005a 8b fe mov edi, esi
\r
2189 0005c c1 ef 05 shr edi, 5
\r
2195 00060 33 50 04 xor edx, DWORD PTR [eax+4]
\r
2196 00063 8b ca mov ecx, edx
\r
2197 00065 c1 e9 10 shr ecx, 16 ; 00000010H
\r
2198 00068 8b da mov ebx, edx
\r
2199 0006a c1 eb 08 shr ebx, 8
\r
2200 0006d 81 e3 ff 00 00
\r
2201 00 and ebx, 255 ; 000000ffH
\r
2202 00073 81 e1 ff 00 00
\r
2203 00 and ecx, 255 ; 000000ffH
\r
2204 00079 8b 0c 8d 00 18
\r
2205 00 00 mov ecx, DWORD PTR _crc_table[ecx*4+6144]
\r
2206 00080 33 0c 9d 00 14
\r
2207 00 00 xor ecx, DWORD PTR _crc_table[ebx*4+5120]
\r
2208 00087 8b da mov ebx, edx
\r
2209 00089 c1 eb 18 shr ebx, 24 ; 00000018H
\r
2210 0008c 33 0c 9d 00 1c
\r
2211 00 00 xor ecx, DWORD PTR _crc_table[ebx*4+7168]
\r
2212 00093 81 e2 ff 00 00
\r
2213 00 and edx, 255 ; 000000ffH
\r
2214 00099 33 0c 95 00 10
\r
2215 00 00 xor ecx, DWORD PTR _crc_table[edx*4+4096]
\r
2216 000a0 33 48 08 xor ecx, DWORD PTR [eax+8]
\r
2217 000a3 8b d1 mov edx, ecx
\r
2218 000a5 c1 ea 10 shr edx, 16 ; 00000010H
\r
2219 000a8 81 e2 ff 00 00
\r
2220 00 and edx, 255 ; 000000ffH
\r
2221 000ae 8b 14 95 00 18
\r
2222 00 00 mov edx, DWORD PTR _crc_table[edx*4+6144]
\r
2223 000b5 8b d9 mov ebx, ecx
\r
2224 000b7 c1 eb 08 shr ebx, 8
\r
2225 000ba 81 e3 ff 00 00
\r
2226 00 and ebx, 255 ; 000000ffH
\r
2227 000c0 33 14 9d 00 14
\r
2228 00 00 xor edx, DWORD PTR _crc_table[ebx*4+5120]
\r
2229 000c7 8b d9 mov ebx, ecx
\r
2230 000c9 c1 eb 18 shr ebx, 24 ; 00000018H
\r
2231 000cc 33 14 9d 00 1c
\r
2232 00 00 xor edx, DWORD PTR _crc_table[ebx*4+7168]
\r
2233 000d3 81 e1 ff 00 00
\r
2234 00 and ecx, 255 ; 000000ffH
\r
2235 000d9 33 14 8d 00 10
\r
2236 00 00 xor edx, DWORD PTR _crc_table[ecx*4+4096]
\r
2237 000e0 33 50 0c xor edx, DWORD PTR [eax+12]
\r
2238 000e3 8b ca mov ecx, edx
\r
2239 000e5 c1 e9 10 shr ecx, 16 ; 00000010H
\r
2240 000e8 8b da mov ebx, edx
\r
2241 000ea c1 eb 08 shr ebx, 8
\r
2242 000ed 81 e3 ff 00 00
\r
2243 00 and ebx, 255 ; 000000ffH
\r
2244 000f3 81 e1 ff 00 00
\r
2245 00 and ecx, 255 ; 000000ffH
\r
2246 000f9 8b 0c 8d 00 18
\r
2247 00 00 mov ecx, DWORD PTR _crc_table[ecx*4+6144]
\r
2248 00100 33 0c 9d 00 14
\r
2249 00 00 xor ecx, DWORD PTR _crc_table[ebx*4+5120]
\r
2250 00107 8b da mov ebx, edx
\r
2251 00109 c1 eb 18 shr ebx, 24 ; 00000018H
\r
2252 0010c 33 0c 9d 00 1c
\r
2253 00 00 xor ecx, DWORD PTR _crc_table[ebx*4+7168]
\r
2254 00113 81 e2 ff 00 00
\r
2255 00 and edx, 255 ; 000000ffH
\r
2256 00119 33 0c 95 00 10
\r
2257 00 00 xor ecx, DWORD PTR _crc_table[edx*4+4096]
\r
2258 00120 33 48 10 xor ecx, DWORD PTR [eax+16]
\r
2259 00123 8b d1 mov edx, ecx
\r
2260 00125 c1 ea 10 shr edx, 16 ; 00000010H
\r
2261 00128 81 e2 ff 00 00
\r
2262 00 and edx, 255 ; 000000ffH
\r
2263 0012e 8b 14 95 00 18
\r
2264 00 00 mov edx, DWORD PTR _crc_table[edx*4+6144]
\r
2265 00135 8b d9 mov ebx, ecx
\r
2266 00137 c1 eb 08 shr ebx, 8
\r
2267 0013a 81 e3 ff 00 00
\r
2268 00 and ebx, 255 ; 000000ffH
\r
2269 00140 33 14 9d 00 14
\r
2270 00 00 xor edx, DWORD PTR _crc_table[ebx*4+5120]
\r
2271 00147 8b d9 mov ebx, ecx
\r
2272 00149 c1 eb 18 shr ebx, 24 ; 00000018H
\r
2273 0014c 33 14 9d 00 1c
\r
2274 00 00 xor edx, DWORD PTR _crc_table[ebx*4+7168]
\r
2275 00153 81 e1 ff 00 00
\r
2276 00 and ecx, 255 ; 000000ffH
\r
2277 00159 33 14 8d 00 10
\r
2278 00 00 xor edx, DWORD PTR _crc_table[ecx*4+4096]
\r
2279 00160 33 50 14 xor edx, DWORD PTR [eax+20]
\r
2280 00163 8b ca mov ecx, edx
\r
2281 00165 c1 e9 10 shr ecx, 16 ; 00000010H
\r
2282 00168 8b da mov ebx, edx
\r
2283 0016a c1 eb 08 shr ebx, 8
\r
2284 0016d 81 e1 ff 00 00
\r
2285 00 and ecx, 255 ; 000000ffH
\r
2286 00173 8b 0c 8d 00 18
\r
2287 00 00 mov ecx, DWORD PTR _crc_table[ecx*4+6144]
\r
2288 0017a 81 e3 ff 00 00
\r
2289 00 and ebx, 255 ; 000000ffH
\r
2290 00180 33 0c 9d 00 14
\r
2291 00 00 xor ecx, DWORD PTR _crc_table[ebx*4+5120]
\r
2292 00187 8b da mov ebx, edx
\r
2293 00189 c1 eb 18 shr ebx, 24 ; 00000018H
\r
2294 0018c 33 0c 9d 00 1c
\r
2295 00 00 xor ecx, DWORD PTR _crc_table[ebx*4+7168]
\r
2296 00193 81 e2 ff 00 00
\r
2297 00 and edx, 255 ; 000000ffH
\r
2298 00199 33 0c 95 00 10
\r
2299 00 00 xor ecx, DWORD PTR _crc_table[edx*4+4096]
\r
2300 001a0 33 48 18 xor ecx, DWORD PTR [eax+24]
\r
2301 001a3 8b d1 mov edx, ecx
\r
2302 001a5 c1 ea 10 shr edx, 16 ; 00000010H
\r
2303 001a8 81 e2 ff 00 00
\r
2304 00 and edx, 255 ; 000000ffH
\r
2305 001ae 8b 14 95 00 18
\r
2306 00 00 mov edx, DWORD PTR _crc_table[edx*4+6144]
\r
2307 001b5 8b d9 mov ebx, ecx
\r
2308 001b7 c1 eb 08 shr ebx, 8
\r
2309 001ba 81 e3 ff 00 00
\r
2310 00 and ebx, 255 ; 000000ffH
\r
2311 001c0 33 14 9d 00 14
\r
2312 00 00 xor edx, DWORD PTR _crc_table[ebx*4+5120]
\r
2313 001c7 8b d9 mov ebx, ecx
\r
2314 001c9 c1 eb 18 shr ebx, 24 ; 00000018H
\r
2315 001cc 33 14 9d 00 1c
\r
2316 00 00 xor edx, DWORD PTR _crc_table[ebx*4+7168]
\r
2317 001d3 81 e1 ff 00 00
\r
2318 00 and ecx, 255 ; 000000ffH
\r
2319 001d9 33 14 8d 00 10
\r
2320 00 00 xor edx, DWORD PTR _crc_table[ecx*4+4096]
\r
2321 001e0 83 c0 20 add eax, 32 ; 00000020H
\r
2322 001e3 33 50 fc xor edx, DWORD PTR [eax-4]
\r
2324 ; 328 : len -= 32;
\r
2326 001e6 83 ee 20 sub esi, 32 ; 00000020H
\r
2327 001e9 8b ca mov ecx, edx
\r
2328 001eb 8b da mov ebx, edx
\r
2329 001ed c1 e9 10 shr ecx, 16 ; 00000010H
\r
2330 001f0 c1 eb 08 shr ebx, 8
\r
2331 001f3 81 e1 ff 00 00
\r
2332 00 and ecx, 255 ; 000000ffH
\r
2333 001f9 8b 0c 8d 00 18
\r
2334 00 00 mov ecx, DWORD PTR _crc_table[ecx*4+6144]
\r
2335 00200 81 e3 ff 00 00
\r
2336 00 and ebx, 255 ; 000000ffH
\r
2337 00206 33 0c 9d 00 14
\r
2338 00 00 xor ecx, DWORD PTR _crc_table[ebx*4+5120]
\r
2339 0020d 8b da mov ebx, edx
\r
2340 0020f c1 eb 18 shr ebx, 24 ; 00000018H
\r
2341 00212 33 0c 9d 00 1c
\r
2342 00 00 xor ecx, DWORD PTR _crc_table[ebx*4+7168]
\r
2343 00219 81 e2 ff 00 00
\r
2344 00 and edx, 255 ; 000000ffH
\r
2345 0021f 33 0c 95 00 10
\r
2346 00 00 xor ecx, DWORD PTR _crc_table[edx*4+4096]
\r
2347 00226 33 08 xor ecx, DWORD PTR [eax]
\r
2348 00228 8b d1 mov edx, ecx
\r
2349 0022a c1 ea 10 shr edx, 16 ; 00000010H
\r
2350 0022d 81 e2 ff 00 00
\r
2351 00 and edx, 255 ; 000000ffH
\r
2352 00233 8b 14 95 00 18
\r
2353 00 00 mov edx, DWORD PTR _crc_table[edx*4+6144]
\r
2354 0023a 8b d9 mov ebx, ecx
\r
2355 0023c c1 eb 08 shr ebx, 8
\r
2356 0023f 81 e3 ff 00 00
\r
2357 00 and ebx, 255 ; 000000ffH
\r
2358 00245 33 14 9d 00 14
\r
2359 00 00 xor edx, DWORD PTR _crc_table[ebx*4+5120]
\r
2360 0024c 8b d9 mov ebx, ecx
\r
2361 0024e c1 eb 18 shr ebx, 24 ; 00000018H
\r
2362 00251 33 14 9d 00 1c
\r
2363 00 00 xor edx, DWORD PTR _crc_table[ebx*4+7168]
\r
2364 00258 81 e1 ff 00 00
\r
2365 00 and ecx, 255 ; 000000ffH
\r
2366 0025e 33 14 8d 00 10
\r
2367 00 00 xor edx, DWORD PTR _crc_table[ecx*4+4096]
\r
2369 00266 0f 85 f4 fd ff
\r
2370 ff jne $LL8@crc32_big
\r
2374 ; 330 : while (len >= 4) {
\r
2376 0026c 83 fe 04 cmp esi, 4
\r
2377 0026f 72 50 jb SHORT $LN5@crc32_big
\r
2378 00271 8b ce mov ecx, esi
\r
2379 00273 c1 e9 02 shr ecx, 2
\r
2384 00276 33 50 04 xor edx, DWORD PTR [eax+4]
\r
2385 00279 83 c0 04 add eax, 4
\r
2386 0027c 8b fa mov edi, edx
\r
2387 0027e c1 ef 10 shr edi, 16 ; 00000010H
\r
2388 00281 81 e7 ff 00 00
\r
2389 00 and edi, 255 ; 000000ffH
\r
2390 00287 8b 3c bd 00 18
\r
2391 00 00 mov edi, DWORD PTR _crc_table[edi*4+6144]
\r
2392 0028e 8b da mov ebx, edx
\r
2393 00290 c1 eb 08 shr ebx, 8
\r
2394 00293 81 e3 ff 00 00
\r
2395 00 and ebx, 255 ; 000000ffH
\r
2396 00299 33 3c 9d 00 14
\r
2397 00 00 xor edi, DWORD PTR _crc_table[ebx*4+5120]
\r
2398 002a0 8b da mov ebx, edx
\r
2399 002a2 c1 eb 18 shr ebx, 24 ; 00000018H
\r
2400 002a5 33 3c 9d 00 1c
\r
2401 00 00 xor edi, DWORD PTR _crc_table[ebx*4+7168]
\r
2402 002ac 81 e2 ff 00 00
\r
2403 00 and edx, 255 ; 000000ffH
\r
2404 002b2 33 3c 95 00 10
\r
2405 00 00 xor edi, DWORD PTR _crc_table[edx*4+4096]
\r
2409 002b9 83 ee 04 sub esi, 4
\r
2411 002bd 8b d7 mov edx, edi
\r
2412 002bf 75 b5 jne SHORT $LL6@crc32_big
\r
2418 002c1 83 c0 04 add eax, 4
\r
2421 ; 335 : buf = (const unsigned char FAR *)buf4;
\r
2423 ; 337 : if (len) do {
\r
2425 002c5 85 f6 test esi, esi
\r
2426 002c7 74 1f je SHORT $LN1@crc32_big
\r
2427 002c9 8d a4 24 00 00
\r
2431 ; 338 : c = crc_table[4][(c >> 24) ^ *buf++] ^ (c << 8);
\r
2433 002d0 0f b6 38 movzx edi, BYTE PTR [eax]
\r
2434 002d3 8b ca mov ecx, edx
\r
2435 002d5 c1 e9 18 shr ecx, 24 ; 00000018H
\r
2436 002d8 33 cf xor ecx, edi
\r
2437 002da c1 e2 08 shl edx, 8
\r
2438 002dd 33 14 8d 00 10
\r
2439 00 00 xor edx, DWORD PTR _crc_table[ecx*4+4096]
\r
2442 ; 339 : } while (--len);
\r
2445 002e6 75 e8 jne SHORT $LL3@crc32_big
\r
2450 002e8 f7 d2 not edx
\r
2452 ; 341 : return (unsigned long)(REV(c));
\r
2454 002ea 8b c2 mov eax, edx
\r
2455 002ec 25 00 ff 00 00 and eax, 65280 ; 0000ff00H
\r
2456 002f1 8b ca mov ecx, edx
\r
2457 002f3 c1 e1 10 shl ecx, 16 ; 00000010H
\r
2458 002f6 03 c1 add eax, ecx
\r
2459 002f8 8b ca mov ecx, edx
\r
2460 002fa c1 e9 08 shr ecx, 8
\r
2461 002fd c1 e0 08 shl eax, 8
\r
2462 00300 81 e1 00 ff 00
\r
2463 00 and ecx, 65280 ; 0000ff00H
\r
2464 00306 03 c1 add eax, ecx
\r
2465 00308 c1 ea 18 shr edx, 24 ; 00000018H
\r
2467 0030c 03 c2 add eax, edx
\r
2474 ; Function compile flags: /Ogtp
\r
2476 ; COMDAT _crc32_little
\r
2478 _crc32_little PROC ; COMDAT
\r
2486 00001 8b f2 mov esi, edx
\r
2488 ; 274 : register u4 c;
\r
2489 ; 275 : register const u4 FAR *buf4;
\r
2491 ; 277 : c = (u4)crc;
\r
2494 00003 f7 d0 not eax
\r
2496 ; 279 : while (len && ((ptrdiff_t)buf & 3)) {
\r
2498 00005 85 f6 test esi, esi
\r
2499 00007 74 25 je SHORT $LN9@crc32_litt
\r
2500 00009 8d a4 24 00 00
\r
2503 00010 f6 c1 03 test cl, 3
\r
2504 00013 74 19 je SHORT $LN9@crc32_litt
\r
2506 ; 280 : c = crc_table[0][(c ^ *buf++) & 0xff] ^ (c >> 8);
\r
2508 00015 0f b6 11 movzx edx, BYTE PTR [ecx]
\r
2509 00018 33 d0 xor edx, eax
\r
2510 0001a 81 e2 ff 00 00
\r
2511 00 and edx, 255 ; 000000ffH
\r
2512 00020 c1 e8 08 shr eax, 8
\r
2513 00023 33 04 95 00 00
\r
2514 00 00 xor eax, DWORD PTR _crc_table[edx*4]
\r
2520 0002c 75 e2 jne SHORT $LL10@crc32_litt
\r
2525 ; 285 : while (len >= 32) {
\r
2527 00030 83 fe 20 cmp esi, 32 ; 00000020H
\r
2528 00033 0f 82 0b 02 00
\r
2529 00 jb $LN15@crc32_litt
\r
2533 ; 284 : buf4 = (const u4 FAR *)(const void FAR *)buf;
\r
2535 00039 8b fe mov edi, esi
\r
2536 0003b c1 ef 05 shr edi, 5
\r
2537 0003e 8b ff npad 2
\r
2542 00040 33 01 xor eax, DWORD PTR [ecx]
\r
2543 00042 8b d0 mov edx, eax
\r
2544 00044 c1 ea 10 shr edx, 16 ; 00000010H
\r
2545 00047 8b d8 mov ebx, eax
\r
2546 00049 c1 eb 08 shr ebx, 8
\r
2547 0004c 81 e3 ff 00 00
\r
2548 00 and ebx, 255 ; 000000ffH
\r
2549 00052 81 e2 ff 00 00
\r
2550 00 and edx, 255 ; 000000ffH
\r
2551 00058 8b 14 95 00 04
\r
2552 00 00 mov edx, DWORD PTR _crc_table[edx*4+1024]
\r
2553 0005f 33 14 9d 00 08
\r
2554 00 00 xor edx, DWORD PTR _crc_table[ebx*4+2048]
\r
2555 00066 8b d8 mov ebx, eax
\r
2556 00068 c1 eb 18 shr ebx, 24 ; 00000018H
\r
2557 0006b 33 14 9d 00 00
\r
2558 00 00 xor edx, DWORD PTR _crc_table[ebx*4]
\r
2559 00072 25 ff 00 00 00 and eax, 255 ; 000000ffH
\r
2560 00077 33 14 85 00 0c
\r
2561 00 00 xor edx, DWORD PTR _crc_table[eax*4+3072]
\r
2562 0007e 33 51 04 xor edx, DWORD PTR [ecx+4]
\r
2563 00081 8b c2 mov eax, edx
\r
2564 00083 c1 e8 10 shr eax, 16 ; 00000010H
\r
2565 00086 25 ff 00 00 00 and eax, 255 ; 000000ffH
\r
2566 0008b 8b 04 85 00 04
\r
2567 00 00 mov eax, DWORD PTR _crc_table[eax*4+1024]
\r
2568 00092 8b da mov ebx, edx
\r
2569 00094 c1 eb 08 shr ebx, 8
\r
2570 00097 81 e3 ff 00 00
\r
2571 00 and ebx, 255 ; 000000ffH
\r
2572 0009d 33 04 9d 00 08
\r
2573 00 00 xor eax, DWORD PTR _crc_table[ebx*4+2048]
\r
2574 000a4 8b da mov ebx, edx
\r
2575 000a6 c1 eb 18 shr ebx, 24 ; 00000018H
\r
2576 000a9 33 04 9d 00 00
\r
2577 00 00 xor eax, DWORD PTR _crc_table[ebx*4]
\r
2578 000b0 81 e2 ff 00 00
\r
2579 00 and edx, 255 ; 000000ffH
\r
2580 000b6 33 04 95 00 0c
\r
2581 00 00 xor eax, DWORD PTR _crc_table[edx*4+3072]
\r
2582 000bd 33 41 08 xor eax, DWORD PTR [ecx+8]
\r
2583 000c0 8b d0 mov edx, eax
\r
2584 000c2 c1 ea 10 shr edx, 16 ; 00000010H
\r
2585 000c5 8b d8 mov ebx, eax
\r
2586 000c7 c1 eb 08 shr ebx, 8
\r
2587 000ca 81 e3 ff 00 00
\r
2588 00 and ebx, 255 ; 000000ffH
\r
2589 000d0 81 e2 ff 00 00
\r
2590 00 and edx, 255 ; 000000ffH
\r
2591 000d6 8b 14 95 00 04
\r
2592 00 00 mov edx, DWORD PTR _crc_table[edx*4+1024]
\r
2593 000dd 33 14 9d 00 08
\r
2594 00 00 xor edx, DWORD PTR _crc_table[ebx*4+2048]
\r
2595 000e4 8b d8 mov ebx, eax
\r
2596 000e6 c1 eb 18 shr ebx, 24 ; 00000018H
\r
2597 000e9 33 14 9d 00 00
\r
2598 00 00 xor edx, DWORD PTR _crc_table[ebx*4]
\r
2599 000f0 25 ff 00 00 00 and eax, 255 ; 000000ffH
\r
2600 000f5 33 14 85 00 0c
\r
2601 00 00 xor edx, DWORD PTR _crc_table[eax*4+3072]
\r
2602 000fc 33 51 0c xor edx, DWORD PTR [ecx+12]
\r
2603 000ff 8b c2 mov eax, edx
\r
2604 00101 c1 e8 10 shr eax, 16 ; 00000010H
\r
2605 00104 25 ff 00 00 00 and eax, 255 ; 000000ffH
\r
2606 00109 8b 04 85 00 04
\r
2607 00 00 mov eax, DWORD PTR _crc_table[eax*4+1024]
\r
2608 00110 8b da mov ebx, edx
\r
2609 00112 c1 eb 08 shr ebx, 8
\r
2610 00115 81 e3 ff 00 00
\r
2611 00 and ebx, 255 ; 000000ffH
\r
2612 0011b 33 04 9d 00 08
\r
2613 00 00 xor eax, DWORD PTR _crc_table[ebx*4+2048]
\r
2614 00122 8b da mov ebx, edx
\r
2615 00124 c1 eb 18 shr ebx, 24 ; 00000018H
\r
2616 00127 33 04 9d 00 00
\r
2617 00 00 xor eax, DWORD PTR _crc_table[ebx*4]
\r
2618 0012e 81 e2 ff 00 00
\r
2619 00 and edx, 255 ; 000000ffH
\r
2620 00134 33 04 95 00 0c
\r
2621 00 00 xor eax, DWORD PTR _crc_table[edx*4+3072]
\r
2622 0013b 33 41 10 xor eax, DWORD PTR [ecx+16]
\r
2623 0013e 8b d0 mov edx, eax
\r
2624 00140 c1 ea 10 shr edx, 16 ; 00000010H
\r
2625 00143 8b d8 mov ebx, eax
\r
2626 00145 c1 eb 08 shr ebx, 8
\r
2627 00148 81 e2 ff 00 00
\r
2628 00 and edx, 255 ; 000000ffH
\r
2629 0014e 8b 14 95 00 04
\r
2630 00 00 mov edx, DWORD PTR _crc_table[edx*4+1024]
\r
2631 00155 81 e3 ff 00 00
\r
2632 00 and ebx, 255 ; 000000ffH
\r
2633 0015b 33 14 9d 00 08
\r
2634 00 00 xor edx, DWORD PTR _crc_table[ebx*4+2048]
\r
2635 00162 8b d8 mov ebx, eax
\r
2636 00164 c1 eb 18 shr ebx, 24 ; 00000018H
\r
2637 00167 33 14 9d 00 00
\r
2638 00 00 xor edx, DWORD PTR _crc_table[ebx*4]
\r
2639 0016e 25 ff 00 00 00 and eax, 255 ; 000000ffH
\r
2640 00173 33 14 85 00 0c
\r
2641 00 00 xor edx, DWORD PTR _crc_table[eax*4+3072]
\r
2642 0017a 33 51 14 xor edx, DWORD PTR [ecx+20]
\r
2643 0017d 8b c2 mov eax, edx
\r
2644 0017f c1 e8 10 shr eax, 16 ; 00000010H
\r
2645 00182 25 ff 00 00 00 and eax, 255 ; 000000ffH
\r
2646 00187 8b 04 85 00 04
\r
2647 00 00 mov eax, DWORD PTR _crc_table[eax*4+1024]
\r
2648 0018e 8b da mov ebx, edx
\r
2649 00190 c1 eb 08 shr ebx, 8
\r
2650 00193 81 e3 ff 00 00
\r
2651 00 and ebx, 255 ; 000000ffH
\r
2652 00199 33 04 9d 00 08
\r
2653 00 00 xor eax, DWORD PTR _crc_table[ebx*4+2048]
\r
2654 001a0 8b da mov ebx, edx
\r
2655 001a2 c1 eb 18 shr ebx, 24 ; 00000018H
\r
2656 001a5 33 04 9d 00 00
\r
2657 00 00 xor eax, DWORD PTR _crc_table[ebx*4]
\r
2658 001ac 81 e2 ff 00 00
\r
2659 00 and edx, 255 ; 000000ffH
\r
2660 001b2 33 04 95 00 0c
\r
2661 00 00 xor eax, DWORD PTR _crc_table[edx*4+3072]
\r
2662 001b9 83 c1 20 add ecx, 32 ; 00000020H
\r
2663 001bc 33 41 f8 xor eax, DWORD PTR [ecx-8]
\r
2665 ; 287 : len -= 32;
\r
2667 001bf 83 ee 20 sub esi, 32 ; 00000020H
\r
2668 001c2 8b d0 mov edx, eax
\r
2669 001c4 8b d8 mov ebx, eax
\r
2670 001c6 c1 ea 10 shr edx, 16 ; 00000010H
\r
2671 001c9 c1 eb 08 shr ebx, 8
\r
2672 001cc 81 e2 ff 00 00
\r
2673 00 and edx, 255 ; 000000ffH
\r
2674 001d2 8b 14 95 00 04
\r
2675 00 00 mov edx, DWORD PTR _crc_table[edx*4+1024]
\r
2676 001d9 81 e3 ff 00 00
\r
2677 00 and ebx, 255 ; 000000ffH
\r
2678 001df 33 14 9d 00 08
\r
2679 00 00 xor edx, DWORD PTR _crc_table[ebx*4+2048]
\r
2680 001e6 8b d8 mov ebx, eax
\r
2681 001e8 c1 eb 18 shr ebx, 24 ; 00000018H
\r
2682 001eb 33 14 9d 00 00
\r
2683 00 00 xor edx, DWORD PTR _crc_table[ebx*4]
\r
2684 001f2 25 ff 00 00 00 and eax, 255 ; 000000ffH
\r
2685 001f7 33 14 85 00 0c
\r
2686 00 00 xor edx, DWORD PTR _crc_table[eax*4+3072]
\r
2687 001fe 33 51 fc xor edx, DWORD PTR [ecx-4]
\r
2688 00201 8b c2 mov eax, edx
\r
2689 00203 c1 e8 10 shr eax, 16 ; 00000010H
\r
2690 00206 25 ff 00 00 00 and eax, 255 ; 000000ffH
\r
2691 0020b 8b 04 85 00 04
\r
2692 00 00 mov eax, DWORD PTR _crc_table[eax*4+1024]
\r
2693 00212 8b da mov ebx, edx
\r
2694 00214 c1 eb 08 shr ebx, 8
\r
2695 00217 81 e3 ff 00 00
\r
2696 00 and ebx, 255 ; 000000ffH
\r
2697 0021d 33 04 9d 00 08
\r
2698 00 00 xor eax, DWORD PTR _crc_table[ebx*4+2048]
\r
2699 00224 8b da mov ebx, edx
\r
2700 00226 c1 eb 18 shr ebx, 24 ; 00000018H
\r
2701 00229 33 04 9d 00 00
\r
2702 00 00 xor eax, DWORD PTR _crc_table[ebx*4]
\r
2703 00230 81 e2 ff 00 00
\r
2704 00 and edx, 255 ; 000000ffH
\r
2705 00236 33 04 95 00 0c
\r
2706 00 00 xor eax, DWORD PTR _crc_table[edx*4+3072]
\r
2708 0023e 0f 85 fc fd ff
\r
2709 ff jne $LL8@crc32_litt
\r
2713 ; 289 : while (len >= 4) {
\r
2715 00244 83 fe 04 cmp esi, 4
\r
2716 00247 72 50 jb SHORT $LN5@crc32_litt
\r
2717 00249 8b d6 mov edx, esi
\r
2718 0024b c1 ea 02 shr edx, 2
\r
2719 0024e 8b ff npad 2
\r
2724 00250 33 01 xor eax, DWORD PTR [ecx]
\r
2725 00252 83 c1 04 add ecx, 4
\r
2726 00255 8b f8 mov edi, eax
\r
2727 00257 c1 ef 10 shr edi, 16 ; 00000010H
\r
2728 0025a 81 e7 ff 00 00
\r
2729 00 and edi, 255 ; 000000ffH
\r
2730 00260 8b 3c bd 00 04
\r
2731 00 00 mov edi, DWORD PTR _crc_table[edi*4+1024]
\r
2732 00267 8b d8 mov ebx, eax
\r
2733 00269 c1 eb 08 shr ebx, 8
\r
2734 0026c 81 e3 ff 00 00
\r
2735 00 and ebx, 255 ; 000000ffH
\r
2736 00272 33 3c 9d 00 08
\r
2737 00 00 xor edi, DWORD PTR _crc_table[ebx*4+2048]
\r
2738 00279 8b d8 mov ebx, eax
\r
2739 0027b c1 eb 18 shr ebx, 24 ; 00000018H
\r
2740 0027e 33 3c 9d 00 00
\r
2741 00 00 xor edi, DWORD PTR _crc_table[ebx*4]
\r
2742 00285 25 ff 00 00 00 and eax, 255 ; 000000ffH
\r
2743 0028a 33 3c 85 00 0c
\r
2744 00 00 xor edi, DWORD PTR _crc_table[eax*4+3072]
\r
2748 00291 83 ee 04 sub esi, 4
\r
2750 00295 8b c7 mov eax, edi
\r
2751 00297 75 b7 jne SHORT $LL6@crc32_litt
\r
2757 ; 293 : buf = (const unsigned char FAR *)buf4;
\r
2759 ; 295 : if (len) do {
\r
2761 0029b 85 f6 test esi, esi
\r
2762 0029d 74 1a je SHORT $LN1@crc32_litt
\r
2766 ; 296 : c = crc_table[0][(c ^ *buf++) & 0xff] ^ (c >> 8);
\r
2768 002a0 0f b6 11 movzx edx, BYTE PTR [ecx]
\r
2769 002a3 33 d0 xor edx, eax
\r
2770 002a5 81 e2 ff 00 00
\r
2771 00 and edx, 255 ; 000000ffH
\r
2772 002ab c1 e8 08 shr eax, 8
\r
2773 002ae 33 04 95 00 00
\r
2774 00 00 xor eax, DWORD PTR _crc_table[edx*4]
\r
2777 ; 297 : } while (--len);
\r
2780 002b7 75 e7 jne SHORT $LL3@crc32_litt
\r
2785 002b9 f7 d0 not eax
\r
2788 ; 299 : return (unsigned long)c;
\r
2792 _crc32_little ENDP
\r
2795 ; Function compile flags: /Ogtp
\r
2796 ; COMDAT _crc32@12
\r
2798 _crc$ = 8 ; size = 4
\r
2799 _buf$ = 12 ; size = 4
\r
2800 _len$ = 16 ; size = 4
\r
2801 _crc32@12 PROC ; COMDAT
\r
2806 00001 8b ec mov ebp, esp
\r
2808 ; 231 : if (buf == Z_NULL) return 0UL;
\r
2810 00003 8b 4d 0c mov ecx, DWORD PTR _buf$[ebp]
\r
2811 00006 85 c9 test ecx, ecx
\r
2812 00008 75 06 jne SHORT $LN10@crc32
\r
2813 0000a 33 c0 xor eax, eax
\r
2816 ; 246 : return crc32_big(crc, buf, len);
\r
2818 ; 248 : #endif /* BYFOUR */
\r
2819 ; 249 : crc = crc ^ 0xffffffffUL;
\r
2820 ; 250 : while (len >= 8) {
\r
2824 ; 254 : if (len) do {
\r
2826 ; 256 : } while (--len);
\r
2827 ; 257 : return crc ^ 0xffffffffUL;
\r
2831 0000d c2 0c 00 ret 12 ; 0000000cH
\r
2835 ; 233 : #ifdef DYNAMIC_CRC_TABLE
\r
2836 ; 234 : if (crc_table_empty)
\r
2837 ; 235 : make_crc_table();
\r
2838 ; 236 : #endif /* DYNAMIC_CRC_TABLE */
\r
2840 ; 238 : #ifdef BYFOUR
\r
2841 ; 239 : if (sizeof(void *) == sizeof(ptrdiff_t)) {
\r
2842 ; 240 : u4 endian;
\r
2844 ; 242 : endian = 1;
\r
2845 ; 243 : if (*((unsigned char *)(&endian)))
\r
2846 ; 244 : return crc32_little(crc, buf, len);
\r
2848 00010 8b 55 10 mov edx, DWORD PTR _len$[ebp]
\r
2849 00013 8b 45 08 mov eax, DWORD PTR _crc$[ebp]
\r
2850 00016 e8 00 00 00 00 call _crc32_little
\r
2853 ; 246 : return crc32_big(crc, buf, len);
\r
2855 ; 248 : #endif /* BYFOUR */
\r
2856 ; 249 : crc = crc ^ 0xffffffffUL;
\r
2857 ; 250 : while (len >= 8) {
\r
2861 ; 254 : if (len) do {
\r
2863 ; 256 : } while (--len);
\r
2864 ; 257 : return crc ^ 0xffffffffUL;
\r
2868 0001c c2 0c 00 ret 12 ; 0000000cH
\r
2871 PUBLIC _get_crc_table@0
\r
2872 ; Function compile flags: /Ogtp
\r
2873 ; COMDAT _get_crc_table@0
\r
2875 _get_crc_table@0 PROC ; COMDAT
\r
2877 ; 214 : #ifdef DYNAMIC_CRC_TABLE
\r
2878 ; 215 : if (crc_table_empty)
\r
2879 ; 216 : make_crc_table();
\r
2880 ; 217 : #endif /* DYNAMIC_CRC_TABLE */
\r
2881 ; 218 : return (const unsigned long FAR *)crc_table;
\r
2883 00000 b8 00 00 00 00 mov eax, OFFSET _crc_table
\r
2888 _get_crc_table@0 ENDP
\r
2889 ; Function compile flags: /Ogtp
\r
2890 ; COMDAT _gf2_matrix_square
\r
2892 _mat$ = 8 ; size = 4
\r
2893 _gf2_matrix_square PROC ; COMDAT
\r
2899 00001 8b ec mov ebp, esp
\r
2906 ; 372 : for (n = 0; n < GF2_DIM; n++)
\r
2908 00006 8b 7d 08 mov edi, DWORD PTR _mat$[ebp]
\r
2909 00009 8b f0 mov esi, eax
\r
2910 0000b 2b fe sub edi, esi
\r
2911 0000d bb 20 00 00 00 mov ebx, 32 ; 00000020H
\r
2912 $LL8@gf2_matrix@2:
\r
2914 ; 373 : square[n] = gf2_matrix_times(mat, mat[n]);
\r
2916 00012 8b 0c 37 mov ecx, DWORD PTR [edi+esi]
\r
2917 00015 8b 55 08 mov edx, DWORD PTR _mat$[ebp]
\r
2918 00018 e8 00 00 00 00 call _gf2_matrix_times
\r
2919 0001d 89 06 mov DWORD PTR [esi], eax
\r
2920 0001f 83 c6 04 add esi, 4
\r
2922 00023 75 ed jne SHORT $LL8@gf2_matrix@2
\r
2931 _gf2_matrix_square ENDP
\r
2932 ; Function compile flags: /Ogtp
\r
2933 ; COMDAT _crc32_combine_
\r
2935 _even$ = -256 ; size = 128
\r
2936 _odd$ = -128 ; size = 128
\r
2937 _crc2$ = 8 ; size = 4
\r
2938 _len2$ = 12 ; size = 8
\r
2939 _crc32_combine_ PROC ; COMDAT
\r
2945 00001 8b ec mov ebp, esp
\r
2946 00003 81 ec 00 01 00
\r
2947 00 sub esp, 256 ; 00000100H
\r
2952 ; 383 : unsigned long row;
\r
2953 ; 384 : unsigned long even[GF2_DIM]; /* even-power-of-two zeros operator */
\r
2954 ; 385 : unsigned long odd[GF2_DIM]; /* odd-power-of-two zeros operator */
\r
2956 ; 387 : /* degenerate case (also disallow negative lengths) */
\r
2957 ; 388 : if (len2 <= 0)
\r
2959 0000b 8b 75 10 mov esi, DWORD PTR _len2$[ebp+4]
\r
2961 0000f 8b 7d 0c mov edi, DWORD PTR _len2$[ebp]
\r
2962 00012 8b d8 mov ebx, eax
\r
2963 00014 85 f6 test esi, esi
\r
2964 00016 7f 0e jg SHORT $LN10@crc32_comb
\r
2965 00018 0f 8c b5 00 00
\r
2966 00 jl $LN11@crc32_comb
\r
2967 0001e 85 ff test edi, edi
\r
2969 ; 389 : return crc1;
\r
2971 00020 0f 84 ad 00 00
\r
2972 00 je $LN11@crc32_comb
\r
2976 ; 391 : /* put operator for one zero bit in odd */
\r
2977 ; 392 : odd[0] = 0xedb88320UL; /* CRC-32 polynomial */
\r
2980 00026 b9 01 00 00 00 mov ecx, 1
\r
2981 0002b c7 45 80 20 83
\r
2982 b8 ed mov DWORD PTR _odd$[ebp], -306674912 ; edb88320H
\r
2984 ; 394 : for (n = 1; n < GF2_DIM; n++) {
\r
2986 00032 8b c1 mov eax, ecx
\r
2989 ; 395 : odd[n] = row;
\r
2991 00034 89 4c 85 80 mov DWORD PTR _odd$[ebp+eax*4], ecx
\r
2994 ; 396 : row <<= 1;
\r
2996 00039 03 c9 add ecx, ecx
\r
2997 0003b 83 f8 20 cmp eax, 32 ; 00000020H
\r
2998 0003e 7c f4 jl SHORT $LL9@crc32_comb
\r
3002 ; 399 : /* put operator for two zero bits in even */
\r
3003 ; 400 : gf2_matrix_square(even, odd);
\r
3005 00040 8d 45 80 lea eax, DWORD PTR _odd$[ebp]
\r
3007 00044 8d 85 00 ff ff
\r
3008 ff lea eax, DWORD PTR _even$[ebp]
\r
3009 0004a e8 00 00 00 00 call _gf2_matrix_square
\r
3012 ; 402 : /* put operator for four zero bits in odd */
\r
3013 ; 403 : gf2_matrix_square(odd, even);
\r
3015 0004f 8d 8d 00 ff ff
\r
3016 ff lea ecx, DWORD PTR _even$[ebp]
\r
3018 00056 8d 45 80 lea eax, DWORD PTR _odd$[ebp]
\r
3019 00059 e8 00 00 00 00 call _gf2_matrix_square
\r
3020 0005e 83 c4 08 add esp, 8
\r
3024 ; 405 : /* apply len2 zeros to crc1 (first square will put the operator for one
\r
3025 ; 406 : zero byte, eight zero bits, in even) */
\r
3027 ; 408 : /* apply zeros operator for this bit of len2 */
\r
3028 ; 409 : gf2_matrix_square(even, odd);
\r
3030 00061 8d 55 80 lea edx, DWORD PTR _odd$[ebp]
\r
3032 00065 8d 85 00 ff ff
\r
3033 ff lea eax, DWORD PTR _even$[ebp]
\r
3034 0006b e8 00 00 00 00 call _gf2_matrix_square
\r
3036 ; 410 : if (len2 & 1)
\r
3038 00070 8b c7 mov eax, edi
\r
3039 00072 83 e0 01 and eax, 1
\r
3040 00075 33 c9 xor ecx, ecx
\r
3041 00077 83 c4 04 add esp, 4
\r
3042 0007a 0b c1 or eax, ecx
\r
3043 0007c 74 0f je SHORT $LN3@crc32_comb
\r
3045 ; 411 : crc1 = gf2_matrix_times(even, crc1);
\r
3047 0007e 8b cb mov ecx, ebx
\r
3048 00080 8d 95 00 ff ff
\r
3049 ff lea edx, DWORD PTR _even$[ebp]
\r
3050 00086 e8 00 00 00 00 call _gf2_matrix_times
\r
3051 0008b 8b d8 mov ebx, eax
\r
3054 ; 412 : len2 >>= 1;
\r
3056 0008d 0f ac f7 01 shrd edi, esi, 1
\r
3057 00091 d1 fe sar esi, 1
\r
3060 ; 414 : /* if no more bits set, then done */
\r
3061 ; 415 : if (len2 == 0)
\r
3063 00093 8b c7 mov eax, edi
\r
3064 00095 0b c6 or eax, esi
\r
3065 00097 74 35 je SHORT $LN4@crc32_comb
\r
3069 ; 418 : /* another iteration of the loop with odd and even swapped */
\r
3070 ; 419 : gf2_matrix_square(odd, even);
\r
3072 00099 8d 8d 00 ff ff
\r
3073 ff lea ecx, DWORD PTR _even$[ebp]
\r
3075 000a0 8d 45 80 lea eax, DWORD PTR _odd$[ebp]
\r
3076 000a3 e8 00 00 00 00 call _gf2_matrix_square
\r
3078 ; 420 : if (len2 & 1)
\r
3080 000a8 8b c7 mov eax, edi
\r
3081 000aa 83 e0 01 and eax, 1
\r
3082 000ad 33 c9 xor ecx, ecx
\r
3083 000af 83 c4 04 add esp, 4
\r
3084 000b2 0b c1 or eax, ecx
\r
3085 000b4 74 0c je SHORT $LN1@crc32_comb
\r
3087 ; 421 : crc1 = gf2_matrix_times(odd, crc1);
\r
3089 000b6 8b cb mov ecx, ebx
\r
3090 000b8 8d 55 80 lea edx, DWORD PTR _odd$[ebp]
\r
3091 000bb e8 00 00 00 00 call _gf2_matrix_times
\r
3092 000c0 8b d8 mov ebx, eax
\r
3095 ; 422 : len2 >>= 1;
\r
3097 000c2 0f ac f7 01 shrd edi, esi, 1
\r
3098 000c6 d1 fe sar esi, 1
\r
3101 ; 424 : /* if no more bits set, then done */
\r
3102 ; 425 : } while (len2 != 0);
\r
3104 000c8 8b d7 mov edx, edi
\r
3105 000ca 0b d6 or edx, esi
\r
3106 000cc 75 93 jne SHORT $LL6@crc32_comb
\r
3110 ; 427 : /* return combined crc */
\r
3111 ; 428 : crc1 ^= crc2;
\r
3113 000ce 8b c3 mov eax, ebx
\r
3114 000d0 33 45 08 xor eax, DWORD PTR _crc2$[ebp]
\r
3120 ; 429 : return crc1;
\r
3123 000d6 8b e5 mov esp, ebp
\r
3126 _crc32_combine_ ENDP
\r
3127 PUBLIC _crc32_combine@12
\r
3128 ; Function compile flags: /Ogtp
\r
3129 ; COMDAT _crc32_combine@12
\r
3131 _crc1$ = 8 ; size = 4
\r
3132 _crc2$ = 12 ; size = 4
\r
3133 _len2$ = 16 ; size = 4
\r
3134 _crc32_combine@12 PROC ; COMDAT
\r
3139 00001 8b ec mov ebp, esp
\r
3141 ; 438 : return crc32_combine_(crc1, crc2, len2);
\r
3143 00003 8b 45 10 mov eax, DWORD PTR _len2$[ebp]
\r
3147 00009 8b 45 0c mov eax, DWORD PTR _crc2$[ebp]
\r
3149 0000d 8b 45 08 mov eax, DWORD PTR _crc1$[ebp]
\r
3150 00010 e8 00 00 00 00 call _crc32_combine_
\r
3151 00015 83 c4 0c add esp, 12 ; 0000000cH
\r
3156 00019 c2 0c 00 ret 12 ; 0000000cH
\r
3157 _crc32_combine@12 ENDP
\r