summaryrefslogtreecommitdiff
path: root/CryptoPkg/Library/BaseCryptLib/SysCall
diff options
context:
space:
mode:
Diffstat (limited to 'CryptoPkg/Library/BaseCryptLib/SysCall')
-rw-r--r--CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathDivU64x64.S83
-rw-r--r--CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathDivU64x64.c88
-rw-r--r--CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathLShiftS64.S62
-rw-r--r--CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathLShiftS64.c54
-rw-r--r--CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathMultS64x64.S77
-rw-r--r--CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathMultS64x64.c79
-rw-r--r--CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathRShiftU64.S66
-rw-r--r--CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathRShiftU64.c57
-rw-r--r--CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathReminderU64x64.S89
-rw-r--r--CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathReminderU64x64.c93
10 files changed, 0 insertions, 748 deletions
diff --git a/CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathDivU64x64.S b/CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathDivU64x64.S
deleted file mode 100644
index f46d5b8..0000000
--- a/CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathDivU64x64.S
+++ /dev/null
@@ -1,83 +0,0 @@
-#------------------------------------------------------------------------------
-#
-# Copyright (c) 2009 - 2010, Intel Corporation. All rights reserved.<BR>
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php.
-#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
-# Module Name:
-#
-# MathDivU64x64.S
-#
-# Abstract:
-#
-# 64-bit Math Worker Function.
-# Divides a 64-bit unsigned value with a 64-bit unsigned value and returns
-# a 64-bit unsigned result.
-#
-#------------------------------------------------------------------------------
-
- .686:
- .code:
-
-ASM_GLOBAL ASM_PFX(__udivdi3), ASM_PFX(DivU64x64Remainder)
-
-#------------------------------------------------------------------------------
-#
-# void __cdecl __udivdi3 (void)
-#
-#------------------------------------------------------------------------------
-ASM_PFX(__udivdi3):
- # Original local stack when calling __udivdi3
- # -----------------
- # | |
- # |---------------|
- # | |
- # |-- Divisor --|
- # | |
- # |---------------|
- # | |
- # |-- Dividend --|
- # | |
- # |---------------|
- # | ReturnAddr** |
- # ESP---->|---------------|
- #
-
- #
- # Set up the local stack for NULL Reminder pointer
- #
- xorl %eax, %eax
- push %eax
-
- #
- # Set up the local stack for Divisor parameter
- #
- movl 20(%esp), %eax
- push %eax
- movl 20(%esp), %eax
- push %eax
-
- #
- # Set up the local stack for Dividend parameter
- #
- movl 20(%esp), %eax
- push %eax
- movl 20(%esp), %eax
- push %eax
-
- #
- # Call native DivU64x64Remainder of BaseLib
- #
- jmp ASM_PFX(DivU64x64Remainder)
-
- #
- # Adjust stack
- #
- addl $20, %esp
-
- ret $16
diff --git a/CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathDivU64x64.c b/CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathDivU64x64.c
deleted file mode 100644
index 4011653..0000000
--- a/CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathDivU64x64.c
+++ /dev/null
@@ -1,88 +0,0 @@
-/** @file
- 64-bit Math Worker Function.
- The 32-bit versions of C compiler generate calls to library routines
- to handle 64-bit math. These functions use non-standard calling conventions.
-
-Copyright (c) 2009 - 2010, Intel Corporation. All rights reserved.<BR>
-This program and the accompanying materials
-are licensed and made available under the terms and conditions of the BSD License
-which accompanies this distribution. The full text of the license may be found at
-http://opensource.org/licenses/bsd-license.php
-
-THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-
-**/
-
-#include <Library/BaseLib.h>
-
-
-/*
- * Divides a 64-bit unsigned value with a 64-bit unsigned value and returns
- * a 64-bit unsigned result.
- */
-__declspec(naked) void __cdecl _aulldiv (void)
-{
- //
- // Wrapper Implementation over EDKII DivU64x64Reminder() routine
- // UINT64
- // EFIAPI
- // DivU64x64Remainder (
- // IN UINT64 Dividend,
- // IN UINT64 Divisor,
- // OUT UINT64 *Remainder OPTIONAL
- // )
- //
- _asm {
-
- ; Original local stack when calling _aulldiv
- ; -----------------
- ; | |
- ; |---------------|
- ; | |
- ; |-- Divisor --|
- ; | |
- ; |---------------|
- ; | |
- ; |-- Dividend --|
- ; | |
- ; |---------------|
- ; | ReturnAddr** |
- ; ESP---->|---------------|
- ;
-
- ;
- ; Set up the local stack for NULL Reminder pointer
- ;
- xor eax, eax
- push eax
-
- ;
- ; Set up the local stack for Divisor parameter
- ;
- mov eax, [esp + 20]
- push eax
- mov eax, [esp + 20]
- push eax
-
- ;
- ; Set up the local stack for Dividend parameter
- ;
- mov eax, [esp + 20]
- push eax
- mov eax, [esp + 20]
- push eax
-
- ;
- ; Call native DivU64x64Remainder of BaseLib
- ;
- call DivU64x64Remainder
-
- ;
- ; Adjust stack
- ;
- add esp, 20
-
- ret 16
- }
-}
diff --git a/CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathLShiftS64.S b/CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathLShiftS64.S
deleted file mode 100644
index e89f553..0000000
--- a/CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathLShiftS64.S
+++ /dev/null
@@ -1,62 +0,0 @@
-#------------------------------------------------------------------------------
-#
-# Copyright (c) 2009 - 2010, Intel Corporation. All rights reserved.<BR>
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php.
-#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
-# Module Name:
-#
-# MathLShiftS64.S
-#
-# Abstract:
-#
-# 64-bit Math Worker Function.
-# Shifts a 64-bit signed value left by a certain number of bits.
-#
-#------------------------------------------------------------------------------
-
- .686:
- .code:
-
-ASM_GLOBAL ASM_PFX(__ashldi3)
-
-#------------------------------------------------------------------------------
-#
-# void __cdecl __ashldi3 (void)
-#
-#------------------------------------------------------------------------------
-ASM_PFX(__ashldi3):
- #
- # Handle shifting of 64 or more bits (return 0)
- #
- cmpb $64, %cl
- jae ReturnZero
-
- #
- # Handle shifting of between 0 and 31 bits
- #
- cmpb $32, %cl
- jae More32
- shld %cl, %eax, %edx
- shl %cl, %eax
- ret
-
- #
- # Handle shifting of between 32 and 63 bits
- #
-More32:
- movl %eax, %edx
- xor %eax, %eax
- and $31, %cl
- shl %cl, %edx
- ret
-
-ReturnZero:
- xor %eax, %eax
- xor %edx, %edx
- ret
diff --git a/CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathLShiftS64.c b/CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathLShiftS64.c
deleted file mode 100644
index 2ea628a..0000000
--- a/CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathLShiftS64.c
+++ /dev/null
@@ -1,54 +0,0 @@
-/** @file
- 64-bit Math Worker Function.
- The 32-bit versions of C compiler generate calls to library routines
- to handle 64-bit math. These functions use non-standard calling conventions.
-
-Copyright (c) 2009 - 2010, Intel Corporation. All rights reserved.<BR>
-This program and the accompanying materials
-are licensed and made available under the terms and conditions of the BSD License
-which accompanies this distribution. The full text of the license may be found at
-http://opensource.org/licenses/bsd-license.php
-
-THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-
-**/
-
-
-/*
- * Shifts a 64-bit signed value left by a particular number of bits.
- */
-__declspec(naked) void __cdecl _allshl (void)
-{
- _asm {
- ;
- ; Handle shifting of 64 or more bits (return 0)
- ;
- cmp cl, 64
- jae short ReturnZero
-
- ;
- ; Handle shifting of between 0 and 31 bits
- ;
- cmp cl, 32
- jae short More32
- shld edx, eax, cl
- shl eax, cl
- ret
-
- ;
- ; Handle shifting of between 32 and 63 bits
- ;
-More32:
- mov edx, eax
- xor eax, eax
- and cl, 31
- shl edx, cl
- ret
-
-ReturnZero:
- xor eax,eax
- xor edx,edx
- ret
- }
-}
diff --git a/CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathMultS64x64.S b/CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathMultS64x64.S
deleted file mode 100644
index 8a5f330..0000000
--- a/CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathMultS64x64.S
+++ /dev/null
@@ -1,77 +0,0 @@
-#------------------------------------------------------------------------------
-#
-# Copyright (c) 2009 - 2010, Intel Corporation. All rights reserved.<BR>
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php.
-#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
-# Module Name:
-#
-# MathMultS64x64.S
-#
-# Abstract:
-#
-# 64-bit Math Worker Function.
-# Multiplies a 64-bit signed or unsigned value by a 64-bit signed or unsigned value
-# and returns a 64-bit result
-#
-#------------------------------------------------------------------------------
-
- .686:
- .code:
-
-ASM_GLOBAL ASM_PFX(_mulll), ASM_PFX(MultS64x64)
-
-#------------------------------------------------------------------------------
-#
-# void __cdecl __mulll (void)
-#
-#------------------------------------------------------------------------------
-ASM_PFX(__mulll):
- # Original local stack when calling __mulll
- # -----------------
- # | |
- # |---------------|
- # | |
- # |--Multiplier --|
- # | |
- # |---------------|
- # | |
- # |--Multiplicand-|
- # | |
- # |---------------|
- # | ReturnAddr** |
- # ESP---->|---------------|
- #
-
- #
- # Set up the local stack for Multiplicand parameter
- #
- movl 16(%esp), %eax
- push %eax
- movl 16(%esp), %eax
- push %eax
-
- #
- # Set up the local stack for Multiplier parameter
- #
- movl 16(%esp), %eax
- push %eax
- movl 16(%esp), %eax
- push %eax
-
- #
- # Call native MulS64x64 of BaseLib
- #
- jmp ASM_PFX(MultS64x64)
-
- #
- # Adjust stack
- #
- add $16, %esp
-
- ret $16
diff --git a/CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathMultS64x64.c b/CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathMultS64x64.c
deleted file mode 100644
index 17a20bf..0000000
--- a/CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathMultS64x64.c
+++ /dev/null
@@ -1,79 +0,0 @@
-/** @file
- 64-bit Math Worker Function.
- The 32-bit versions of C compiler generate calls to library routines
- to handle 64-bit math. These functions use non-standard calling conventions.
-
-Copyright (c) 2009 - 2010, Intel Corporation. All rights reserved.<BR>
-This program and the accompanying materials
-are licensed and made available under the terms and conditions of the BSD License
-which accompanies this distribution. The full text of the license may be found at
-http://opensource.org/licenses/bsd-license.php
-
-THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-
-**/
-
-#include <Library/BaseLib.h>
-
-/*
- * Multiplies a 64-bit signed or unsigned value by a 64-bit signed or unsigned value
- * and returns a 64-bit result.
- */
-__declspec(naked) void __cdecl _allmul (void)
-{
- //
- // Wrapper Implementation over EDKII MultS64x64() routine
- // INT64
- // EFIAPI
- // MultS64x64 (
- // IN INT64 Multiplicand,
- // IN INT64 Multiplier
- // )
- //
- _asm {
- ; Original local stack when calling _allmul
- ; -----------------
- ; | |
- ; |---------------|
- ; | |
- ; |--Multiplier --|
- ; | |
- ; |---------------|
- ; | |
- ; |--Multiplicand-|
- ; | |
- ; |---------------|
- ; | ReturnAddr** |
- ; ESP---->|---------------|
- ;
-
- ;
- ; Set up the local stack for Multiplicand parameter
- ;
- mov eax, [esp + 16]
- push eax
- mov eax, [esp + 16]
- push eax
-
- ;
- ; Set up the local stack for Multiplier parameter
- ;
- mov eax, [esp + 16]
- push eax
- mov eax, [esp + 16]
- push eax
-
- ;
- ; Call native MulS64x64 of BaseLib
- ;
- call MultS64x64
-
- ;
- ; Adjust stack
- ;
- add esp, 16
-
- ret 16
- }
-}
diff --git a/CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathRShiftU64.S b/CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathRShiftU64.S
deleted file mode 100644
index bf05875..0000000
--- a/CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathRShiftU64.S
+++ /dev/null
@@ -1,66 +0,0 @@
-#------------------------------------------------------------------------------
-#
-# Copyright (c) 2009 - 2013, Intel Corporation. All rights reserved.<BR>
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php.
-#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
-# Module Name:
-#
-# MathRShiftU64.S
-#
-# Abstract:
-#
-# 64-bit Math Worker Function.
-# Shifts a 64-bit unsigned value right by a certain number of bits.
-#
-#------------------------------------------------------------------------------
-
-
- .686:
- .code:
-
-ASM_GLOBAL ASM_PFX(__ashrdi3)
-
-#------------------------------------------------------------------------------
-#
-# void __cdecl __ashrdi3 (void)
-#
-#------------------------------------------------------------------------------
-ASM_PFX(__ashrdi3):
- #
- # Checking: Only handle 64bit shifting or more
- #
- cmpb $64, %cl
- jae _Exit
-
- #
- # Handle shifting between 0 and 31 bits
- #
- cmpb $32, %cl
- jae More32
- shrd %cl, %edx, %eax
- shr %cl, %edx
- ret
-
- #
- # Handle shifting of 32-63 bits
- #
-More32:
- movl %edx, %eax
- xor %edx, %edx
- and $31, %cl
- shr %cl, %eax
- ret
-
- #
- # Invalid number (less then 32bits), return 0
- #
-_Exit:
- xor %eax, %eax
- xor %edx, %edx
- ret
diff --git a/CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathRShiftU64.c b/CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathRShiftU64.c
deleted file mode 100644
index b7224d6..0000000
--- a/CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathRShiftU64.c
+++ /dev/null
@@ -1,57 +0,0 @@
-/** @file
- 64-bit Math Worker Function.
- The 32-bit versions of C compiler generate calls to library routines
- to handle 64-bit math. These functions use non-standard calling conventions.
-
-Copyright (c) 2009 - 2010, Intel Corporation. All rights reserved.<BR>
-This program and the accompanying materials
-are licensed and made available under the terms and conditions of the BSD License
-which accompanies this distribution. The full text of the license may be found at
-http://opensource.org/licenses/bsd-license.php
-
-THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-
-**/
-
-
-/*
- * Shifts a 64-bit unsigned value right by a certain number of bits.
- */
-__declspec(naked) void __cdecl _aullshr (void)
-{
- _asm {
- ;
- ; Checking: Only handle 64bit shifting or more
- ;
- cmp cl, 64
- jae _Exit
-
- ;
- ; Handle shifting between 0 and 31 bits
- ;
- cmp cl, 32
- jae More32
- shrd eax, edx, cl
- shr edx, cl
- ret
-
- ;
- ; Handle shifting of 32-63 bits
- ;
-More32:
- mov eax, edx
- xor edx, edx
- and cl, 31
- shr eax, cl
- ret
-
- ;
- ; Invalid number (less then 32bits), return 0
- ;
-_Exit:
- xor eax, eax
- xor edx, edx
- ret
- }
-}
diff --git a/CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathReminderU64x64.S b/CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathReminderU64x64.S
deleted file mode 100644
index 7c1f971..0000000
--- a/CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathReminderU64x64.S
+++ /dev/null
@@ -1,89 +0,0 @@
-#------------------------------------------------------------------------------
-#
-# Copyright (c) 2009 - 2010, Intel Corporation. All rights reserved.<BR>
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php.
-#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
-# Module Name:
-#
-# MathReminderU64x64.S
-#
-# Abstract:
-#
-# 64-bit Math Worker Function.
-# Divides a 64-bit unsigned value by another 64-bit unsigned value and returns
-# the 64-bit unsigned remainder
-#
-#------------------------------------------------------------------------------
-
- .686:
- .code:
-
-ASM_GLOBAL ASM_PFX(__umoddi3), ASM_PFX(DivU64x64Remainder)
-
-#------------------------------------------------------------------------------
-#
-# void __cdecl __umoddi3 (void)
-#
-#------------------------------------------------------------------------------
-ASM_PFX(__umoddi3):
- # Original local stack when calling __umoddi3
- # -----------------
- # | |
- # |---------------|
- # | |
- # |-- Divisor --|
- # | |
- # |---------------|
- # | |
- # |-- Dividend --|
- # | |
- # |---------------|
- # | ReturnAddr** |
- # ESP---->|---------------|
- #
-
- #
- # Set up the local stack for Reminder pointer
- #
- sub $8, %esp
- push %esp
-
- #
- # Set up the local stack for Divisor parameter
- #
- movl 28(%esp), %eax
- push %eax
- movl 28(%esp), %eax
- push %eax
-
- #
- # Set up the local stack for Dividend parameter
- #
- movl 28(%esp), %eax
- push %eax
- movl 28(%esp), %eax
- push %eax
-
- #
- # Call native DivU64x64Remainder of BaseLib
- #
- jmp ASM_PFX(DivU64x64Remainder)
-
- #
- # Put the Reminder in EDX:EAX as return value
- #
- movl 20(%esp), %eax
- movl 24(%esp), %edx
-
- #
- # Adjust stack
- #
- add $28, %esp
-
- ret $16
diff --git a/CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathReminderU64x64.c b/CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathReminderU64x64.c
deleted file mode 100644
index be70770..0000000
--- a/CryptoPkg/Library/BaseCryptLib/SysCall/Ia32/MathReminderU64x64.c
+++ /dev/null
@@ -1,93 +0,0 @@
-/** @file
- 64-bit Math Worker Function.
- The 32-bit versions of C compiler generate calls to library routines
- to handle 64-bit math. These functions use non-standard calling conventions.
-
-Copyright (c) 2009 - 2010, Intel Corporation. All rights reserved.<BR>
-This program and the accompanying materials
-are licensed and made available under the terms and conditions of the BSD License
-which accompanies this distribution. The full text of the license may be found at
-http://opensource.org/licenses/bsd-license.php
-
-THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-
-**/
-
-#include <Library/BaseLib.h>
-
-
-/*
- * Divides a 64-bit unsigned value by another 64-bit unsigned value and returns
- * the 64-bit unsigned remainder.
- */
-__declspec(naked) void __cdecl _aullrem(void)
-{
- //
- // Wrapper Implementation over EDKII DivU64x64Remainder() routine
- // UINT64
- // EFIAPI
- // DivU64x64Remainder (
- // IN UINT64 Dividend,
- // IN UINT64 Divisor,
- // OUT UINT64 *Remainder OPTIONAL
- // )
- //
- _asm {
- ; Original local stack when calling _aullrem
- ; -----------------
- ; | |
- ; |---------------|
- ; | |
- ; |-- Divisor --|
- ; | |
- ; |---------------|
- ; | |
- ; |-- Dividend --|
- ; | |
- ; |---------------|
- ; | ReturnAddr** |
- ; ESP---->|---------------|
- ;
-
- ;
- ; Set up the local stack for Reminder pointer
- ;
- sub esp, 8
- push esp
-
- ;
- ; Set up the local stack for Divisor parameter
- ;
- mov eax, [esp + 28]
- push eax
- mov eax, [esp + 28]
- push eax
-
- ;
- ; Set up the local stack for Dividend parameter
- ;
- mov eax, [esp + 28]
- push eax
- mov eax, [esp + 28]
- push eax
-
- ;
- ; Call native DivU64x64Remainder of BaseLib
- ;
- call DivU64x64Remainder
-
- ;
- ; Put the Reminder in EDX:EAX as return value
- ;
- mov eax, [esp + 20]
- mov edx, [esp + 24]
-
- ;
- ; Adjust stack
- ;
- add esp, 28
-
- ret 16
- }
-}