+++ /dev/null
-/** @file\r
- 64-bit Math Worker Function.\r
- The 32-bit versions of C compiler generate calls to library routines\r
- to handle 64-bit math. These functions use non-standard calling conventions.\r
-\r
- Copyright (c) 2009 - 2011, Intel Corporation. All rights reserved.<BR>\r
- This program and the accompanying materials are licensed and made available\r
- under the terms and conditions of the BSD License which accompanies this\r
- distribution. The full text of the license may be found at\r
- http://opensource.org/licenses/bsd-license.php.\r
-\r
- THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
- WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
-\r
-**/\r
-\r
-\r
-/*\r
- * Shifts a 64-bit signed value left by a particular number of bits.\r
- */\r
-__declspec(naked) void __cdecl _allshl (void)\r
-{\r
- _asm {\r
- ;\r
- ; Handle shifting of 64 or more bits (return 0)\r
- ;\r
- cmp cl, 64\r
- jae short ReturnZero\r
-\r
- ;\r
- ; Handle shifting of between 0 and 31 bits\r
- ;\r
- cmp cl, 32\r
- jae short More32\r
- shld edx, eax, cl\r
- shl eax, cl\r
- ret\r
-\r
- ;\r
- ; Handle shifting of between 32 and 63 bits\r
- ;\r
-More32:\r
- mov edx, eax\r
- xor eax, eax\r
- and cl, 31\r
- shl edx, cl\r
- ret\r
-\r
-ReturnZero:\r
- xor eax,eax\r
- xor edx,edx\r
- ret\r
- }\r
-}\r