]> git.proxmox.com Git - mirror_edk2.git/commitdiff
Rename
authorvanjeff <vanjeff@6f19259b-4bc3-4df7-8a09-765794883524>
Thu, 25 Sep 2008 03:15:26 +0000 (03:15 +0000)
committervanjeff <vanjeff@6f19259b-4bc3-4df7-8a09-765794883524>
Thu, 25 Sep 2008 03:15:26 +0000 (03:15 +0000)
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@5983 6f19259b-4bc3-4df7-8a09-765794883524

44 files changed:
MdePkg/Library/BaseMemoryLibRepStr/X64/CompareMem.S [new file with mode: 0644]
MdePkg/Library/BaseMemoryLibRepStr/X64/CompareMem.asm [new file with mode: 0644]
MdePkg/Library/BaseMemoryLibRepStr/X64/CopyMem.S [new file with mode: 0644]
MdePkg/Library/BaseMemoryLibRepStr/X64/CopyMem.asm [new file with mode: 0644]
MdePkg/Library/BaseMemoryLibRepStr/X64/ScanMem16.S [new file with mode: 0644]
MdePkg/Library/BaseMemoryLibRepStr/X64/ScanMem16.asm [new file with mode: 0644]
MdePkg/Library/BaseMemoryLibRepStr/X64/ScanMem32.S [new file with mode: 0644]
MdePkg/Library/BaseMemoryLibRepStr/X64/ScanMem32.asm [new file with mode: 0644]
MdePkg/Library/BaseMemoryLibRepStr/X64/ScanMem64.S [new file with mode: 0644]
MdePkg/Library/BaseMemoryLibRepStr/X64/ScanMem64.asm [new file with mode: 0644]
MdePkg/Library/BaseMemoryLibRepStr/X64/ScanMem8.S [new file with mode: 0644]
MdePkg/Library/BaseMemoryLibRepStr/X64/ScanMem8.asm [new file with mode: 0644]
MdePkg/Library/BaseMemoryLibRepStr/X64/SetMem.S [new file with mode: 0644]
MdePkg/Library/BaseMemoryLibRepStr/X64/SetMem.asm [new file with mode: 0644]
MdePkg/Library/BaseMemoryLibRepStr/X64/SetMem16.S [new file with mode: 0644]
MdePkg/Library/BaseMemoryLibRepStr/X64/SetMem16.asm [new file with mode: 0644]
MdePkg/Library/BaseMemoryLibRepStr/X64/SetMem32.S [new file with mode: 0644]
MdePkg/Library/BaseMemoryLibRepStr/X64/SetMem32.asm [new file with mode: 0644]
MdePkg/Library/BaseMemoryLibRepStr/X64/SetMem64.S [new file with mode: 0644]
MdePkg/Library/BaseMemoryLibRepStr/X64/SetMem64.asm [new file with mode: 0644]
MdePkg/Library/BaseMemoryLibRepStr/X64/ZeroMem.S [new file with mode: 0644]
MdePkg/Library/BaseMemoryLibRepStr/X64/ZeroMem.asm [new file with mode: 0644]
MdePkg/Library/BaseMemoryLibRepStr/x64/CompareMem.S [deleted file]
MdePkg/Library/BaseMemoryLibRepStr/x64/CompareMem.asm [deleted file]
MdePkg/Library/BaseMemoryLibRepStr/x64/CopyMem.S [deleted file]
MdePkg/Library/BaseMemoryLibRepStr/x64/CopyMem.asm [deleted file]
MdePkg/Library/BaseMemoryLibRepStr/x64/ScanMem16.S [deleted file]
MdePkg/Library/BaseMemoryLibRepStr/x64/ScanMem16.asm [deleted file]
MdePkg/Library/BaseMemoryLibRepStr/x64/ScanMem32.S [deleted file]
MdePkg/Library/BaseMemoryLibRepStr/x64/ScanMem32.asm [deleted file]
MdePkg/Library/BaseMemoryLibRepStr/x64/ScanMem64.S [deleted file]
MdePkg/Library/BaseMemoryLibRepStr/x64/ScanMem64.asm [deleted file]
MdePkg/Library/BaseMemoryLibRepStr/x64/ScanMem8.S [deleted file]
MdePkg/Library/BaseMemoryLibRepStr/x64/ScanMem8.asm [deleted file]
MdePkg/Library/BaseMemoryLibRepStr/x64/SetMem.S [deleted file]
MdePkg/Library/BaseMemoryLibRepStr/x64/SetMem.asm [deleted file]
MdePkg/Library/BaseMemoryLibRepStr/x64/SetMem16.S [deleted file]
MdePkg/Library/BaseMemoryLibRepStr/x64/SetMem16.asm [deleted file]
MdePkg/Library/BaseMemoryLibRepStr/x64/SetMem32.S [deleted file]
MdePkg/Library/BaseMemoryLibRepStr/x64/SetMem32.asm [deleted file]
MdePkg/Library/BaseMemoryLibRepStr/x64/SetMem64.S [deleted file]
MdePkg/Library/BaseMemoryLibRepStr/x64/SetMem64.asm [deleted file]
MdePkg/Library/BaseMemoryLibRepStr/x64/ZeroMem.S [deleted file]
MdePkg/Library/BaseMemoryLibRepStr/x64/ZeroMem.asm [deleted file]

diff --git a/MdePkg/Library/BaseMemoryLibRepStr/X64/CompareMem.S b/MdePkg/Library/BaseMemoryLibRepStr/X64/CompareMem.S
new file mode 100644 (file)
index 0000000..46dfe0a
--- /dev/null
@@ -0,0 +1,60 @@
+#
+# ConvertAsm.py: Automatically generated from CompareMem.asm
+#
+#------------------------------------------------------------------------------
+#
+# Copyright (c) 2006, Intel Corporation
+# All rights reserved. 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:
+#
+#   CompareMem.S
+#
+# Abstract:
+#
+#   CompareMem function
+#
+# Notes:
+#
+#   The following BaseMemoryLib instances contain the same copy of this file:
+#
+#       BaseMemoryLibRepStr
+#       BaseMemoryLibMmx
+#       BaseMemoryLibSse2
+#       BaseMemoryLibOptDxe
+#       BaseMemoryLibOptPei
+#
+#------------------------------------------------------------------------------
+
+
+#------------------------------------------------------------------------------
+# INTN
+# EFIAPI
+# InternalMemCompareMem (
+#   IN      CONST VOID                *DestinationBuffer,
+#   IN      CONST VOID                *SourceBuffer,
+#   IN      UINTN                     Length
+#   );
+#------------------------------------------------------------------------------
+.intel_syntax
+.globl _InternalMemCompareMem
+_InternalMemCompareMem:
+    push    rsi
+    push    rdi
+    mov     rsi, rcx
+    mov     rdi, rdx
+    mov     rcx, r8
+    repe    cmpsb
+    movzx   rax, byte ptr [rsi - 1]
+    movzx   rdx, byte ptr [rdi - 1]
+    sub     rax, rdx
+    pop     rdi
+    pop     rsi
+    ret
+
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/X64/CompareMem.asm b/MdePkg/Library/BaseMemoryLibRepStr/X64/CompareMem.asm
new file mode 100644 (file)
index 0000000..7446a05
--- /dev/null
@@ -0,0 +1,54 @@
+;------------------------------------------------------------------------------\r
+;\r
+; Copyright (c) 2006, Intel Corporation\r
+; All rights reserved. This program and the accompanying materials\r
+; are licensed and made available under the terms and conditions of the BSD License\r
+; which accompanies this 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
+; Module Name:\r
+;\r
+;   CompareMem.Asm\r
+;\r
+; Abstract:\r
+;\r
+;   CompareMem function\r
+;\r
+; Notes:\r
+;\r
+;   The following BaseMemoryLib instances contain the same copy of this file:\r
+;\r
+;       BaseMemoryLibRepStr\r
+;       BaseMemoryLibMmx\r
+;       BaseMemoryLibSse2\r
+;       BaseMemoryLibOptDxe\r
+;       BaseMemoryLibOptPei\r
+;\r
+;------------------------------------------------------------------------------\r
+\r
+    .code\r
+\r
+;------------------------------------------------------------------------------\r
+; INTN\r
+; EFIAPI\r
+; InternalMemCompareMem (\r
+;   IN      CONST VOID                *DestinationBuffer,\r
+;   IN      CONST VOID                *SourceBuffer,\r
+;   IN      UINTN                     Length\r
+;   );\r
+;------------------------------------------------------------------------------\r
+InternalMemCompareMem   PROC    USES    rsi rdi\r
+    mov     rsi, rcx\r
+    mov     rdi, rdx\r
+    mov     rcx, r8\r
+    repe    cmpsb\r
+    movzx   rax, byte ptr [rsi - 1]\r
+    movzx   rdx, byte ptr [rdi - 1]\r
+    sub     rax, rdx\r
+    ret\r
+InternalMemCompareMem   ENDP\r
+\r
+    END\r
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/X64/CopyMem.S b/MdePkg/Library/BaseMemoryLibRepStr/X64/CopyMem.S
new file mode 100644 (file)
index 0000000..fe67040
--- /dev/null
@@ -0,0 +1,67 @@
+#
+# ConvertAsm.py: Automatically generated from CopyMem.asm
+#
+#------------------------------------------------------------------------------
+#
+# Copyright (c) 2006, Intel Corporation
+# All rights reserved. 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:
+#
+#   CopyMem.S
+#
+# Abstract:
+#
+#   CopyMem function
+#
+# Notes:
+#
+#------------------------------------------------------------------------------
+
+
+#------------------------------------------------------------------------------
+#  VOID *
+#  EFIAPI
+#  InternalMemCopyMem (
+#    IN VOID   *Destination,
+#    IN VOID   *Source,
+#    IN UINTN  Count
+#    )
+#------------------------------------------------------------------------------
+.intel_syntax
+.globl _InternalMemCopyMem
+_InternalMemCopyMem:
+    push    rsi
+    push    rdi
+    mov     rsi, rdx                    # rsi <- Source
+    mov     rdi, rcx                    # rdi <- Destination
+    lea     r9, [rsi + r8 - 1]          # r9 <- End of Source
+    cmp     rsi, rdi
+    mov     rax, rdi                    # rax <- Destination as return value
+    jae     _InternalMemCopyMem_al_0000
+    cmp     r9, rdi
+    jae     _atSym_CopyBackward               # Copy backward if overlapped
+_InternalMemCopyMem_al_0000:
+    mov     rcx, r8
+    and     r8, 7
+    shr     rcx, 3
+    rep     movsq                       # Copy as many Qwords as possible
+    jmp     _atSym_CopyBytes
+_atSym_CopyBackward:
+    mov     rsi, r9                     # rsi <- End of Source
+    lea     rdi, [rdi + r8 - 1]         # esi <- End of Destination
+    std                                 # set direction flag
+_atSym_CopyBytes:
+    mov     rcx, r8
+    rep     movsb                       # Copy bytes backward
+    cld
+    pop     rdi
+    pop     rsi
+    ret
+
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/X64/CopyMem.asm b/MdePkg/Library/BaseMemoryLibRepStr/X64/CopyMem.asm
new file mode 100644 (file)
index 0000000..c2b5d6f
--- /dev/null
@@ -0,0 +1,61 @@
+;------------------------------------------------------------------------------\r
+;\r
+; Copyright (c) 2006, Intel Corporation\r
+; All rights reserved. This program and the accompanying materials\r
+; are licensed and made available under the terms and conditions of the BSD License\r
+; which accompanies this 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
+; Module Name:\r
+;\r
+;   CopyMem.Asm\r
+;\r
+; Abstract:\r
+;\r
+;   CopyMem function\r
+;\r
+; Notes:\r
+;\r
+;------------------------------------------------------------------------------\r
+\r
+    .code\r
+\r
+;------------------------------------------------------------------------------\r
+;  VOID *\r
+;  EFIAPI\r
+;  InternalMemCopyMem (\r
+;    IN VOID   *Destination,\r
+;    IN VOID   *Source,\r
+;    IN UINTN  Count\r
+;    )\r
+;------------------------------------------------------------------------------\r
+InternalMemCopyMem  PROC    USES    rsi rdi\r
+    mov     rsi, rdx                    ; rsi <- Source\r
+    mov     rdi, rcx                    ; rdi <- Destination\r
+    lea     r9, [rsi + r8 - 1]          ; r9 <- End of Source\r
+    cmp     rsi, rdi\r
+    mov     rax, rdi                    ; rax <- Destination as return value\r
+    jae     @F\r
+    cmp     r9, rdi\r
+    jae     @CopyBackward               ; Copy backward if overlapped\r
+@@:\r
+    mov     rcx, r8\r
+    and     r8, 7\r
+    shr     rcx, 3\r
+    rep     movsq                       ; Copy as many Qwords as possible\r
+    jmp     @CopyBytes\r
+@CopyBackward:\r
+    mov     rsi, r9                     ; rsi <- End of Source\r
+    lea     rdi, [rdi + r8 - 1]         ; esi <- End of Destination\r
+    std                                 ; set direction flag\r
+@CopyBytes:\r
+    mov     rcx, r8\r
+    rep     movsb                       ; Copy bytes backward\r
+    cld\r
+    ret\r
+InternalMemCopyMem  ENDP\r
+\r
+    END\r
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/X64/ScanMem16.S b/MdePkg/Library/BaseMemoryLibRepStr/X64/ScanMem16.S
new file mode 100644 (file)
index 0000000..f56b9e9
--- /dev/null
@@ -0,0 +1,57 @@
+#
+# ConvertAsm.py: Automatically generated from ScanMem16.asm
+#
+#------------------------------------------------------------------------------
+#
+# Copyright (c) 2006, Intel Corporation
+# All rights reserved. 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:
+#
+#   ScanMem16.S
+#
+# Abstract:
+#
+#   ScanMem16 function
+#
+# Notes:
+#
+#   The following BaseMemoryLib instances contain the same copy of this file:
+#
+#       BaseMemoryLibRepStr
+#       BaseMemoryLibMmx
+#       BaseMemoryLibSse2
+#       BaseMemoryLibOptDxe
+#       BaseMemoryLibOptPei
+#
+#------------------------------------------------------------------------------
+
+
+#------------------------------------------------------------------------------
+# CONST VOID *
+# EFIAPI
+# InternalMemScanMem16 (
+#   IN      CONST VOID                *Buffer,
+#   IN      UINTN                     Length,
+#   IN      UINT16                    Value
+#   );
+#------------------------------------------------------------------------------
+.intel_syntax
+.globl _InternalMemScanMem16
+_InternalMemScanMem16:
+    push    rdi
+    mov     rdi, rcx
+    mov     rax, r8
+    mov     rcx, rdx
+    repne   scasw
+    lea     rax, [rdi - 2]
+    cmovnz  rax, rcx
+    pop     rdi
+    ret
+
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/X64/ScanMem16.asm b/MdePkg/Library/BaseMemoryLibRepStr/X64/ScanMem16.asm
new file mode 100644 (file)
index 0000000..0871a4b
--- /dev/null
@@ -0,0 +1,53 @@
+;------------------------------------------------------------------------------\r
+;\r
+; Copyright (c) 2006, Intel Corporation\r
+; All rights reserved. This program and the accompanying materials\r
+; are licensed and made available under the terms and conditions of the BSD License\r
+; which accompanies this 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
+; Module Name:\r
+;\r
+;   ScanMem16.Asm\r
+;\r
+; Abstract:\r
+;\r
+;   ScanMem16 function\r
+;\r
+; Notes:\r
+;\r
+;   The following BaseMemoryLib instances contain the same copy of this file:\r
+;\r
+;       BaseMemoryLibRepStr\r
+;       BaseMemoryLibMmx\r
+;       BaseMemoryLibSse2\r
+;       BaseMemoryLibOptDxe\r
+;       BaseMemoryLibOptPei\r
+;\r
+;------------------------------------------------------------------------------\r
+\r
+    .code\r
+\r
+;------------------------------------------------------------------------------\r
+; CONST VOID *\r
+; EFIAPI\r
+; InternalMemScanMem16 (\r
+;   IN      CONST VOID                *Buffer,\r
+;   IN      UINTN                     Length,\r
+;   IN      UINT16                    Value\r
+;   );\r
+;------------------------------------------------------------------------------\r
+InternalMemScanMem16    PROC    USES    rdi\r
+    mov     rdi, rcx\r
+    mov     rax, r8\r
+    mov     rcx, rdx\r
+    repne   scasw\r
+    lea     rax, [rdi - 2]\r
+    cmovnz  rax, rcx\r
+    ret\r
+InternalMemScanMem16    ENDP\r
+\r
+    END\r
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/X64/ScanMem32.S b/MdePkg/Library/BaseMemoryLibRepStr/X64/ScanMem32.S
new file mode 100644 (file)
index 0000000..ef9cd75
--- /dev/null
@@ -0,0 +1,57 @@
+#
+# ConvertAsm.py: Automatically generated from ScanMem32.asm
+#
+#------------------------------------------------------------------------------
+#
+# Copyright (c) 2006, Intel Corporation
+# All rights reserved. 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:
+#
+#   ScanMem32.S
+#
+# Abstract:
+#
+#   ScanMem32 function
+#
+# Notes:
+#
+#   The following BaseMemoryLib instances contain the same copy of this file:
+#
+#       BaseMemoryLibRepStr
+#       BaseMemoryLibMmx
+#       BaseMemoryLibSse2
+#       BaseMemoryLibOptDxe
+#       BaseMemoryLibOptPei
+#
+#------------------------------------------------------------------------------
+
+
+#------------------------------------------------------------------------------
+# CONST VOID *
+# EFIAPI
+# InternalMemScanMem32 (
+#   IN      CONST VOID                *Buffer,
+#   IN      UINTN                     Length,
+#   IN      UINT32                    Value
+#   );
+#------------------------------------------------------------------------------
+.intel_syntax
+.globl _InternalMemScanMem32
+_InternalMemScanMem32:
+    push    rdi
+    mov     rdi, rcx
+    mov     rax, r8
+    mov     rcx, rdx
+    repne   scasd
+    lea     rax, [rdi - 4]
+    cmovnz  rax, rcx
+    pop     rdi
+    ret
+
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/X64/ScanMem32.asm b/MdePkg/Library/BaseMemoryLibRepStr/X64/ScanMem32.asm
new file mode 100644 (file)
index 0000000..53a33ba
--- /dev/null
@@ -0,0 +1,53 @@
+;------------------------------------------------------------------------------\r
+;\r
+; Copyright (c) 2006, Intel Corporation\r
+; All rights reserved. This program and the accompanying materials\r
+; are licensed and made available under the terms and conditions of the BSD License\r
+; which accompanies this 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
+; Module Name:\r
+;\r
+;   ScanMem32.Asm\r
+;\r
+; Abstract:\r
+;\r
+;   ScanMem32 function\r
+;\r
+; Notes:\r
+;\r
+;   The following BaseMemoryLib instances contain the same copy of this file:\r
+;\r
+;       BaseMemoryLibRepStr\r
+;       BaseMemoryLibMmx\r
+;       BaseMemoryLibSse2\r
+;       BaseMemoryLibOptDxe\r
+;       BaseMemoryLibOptPei\r
+;\r
+;------------------------------------------------------------------------------\r
+\r
+    .code\r
+\r
+;------------------------------------------------------------------------------\r
+; CONST VOID *\r
+; EFIAPI\r
+; InternalMemScanMem32 (\r
+;   IN      CONST VOID                *Buffer,\r
+;   IN      UINTN                     Length,\r
+;   IN      UINT32                    Value\r
+;   );\r
+;------------------------------------------------------------------------------\r
+InternalMemScanMem32    PROC    USES    rdi\r
+    mov     rdi, rcx\r
+    mov     rax, r8\r
+    mov     rcx, rdx\r
+    repne   scasd\r
+    lea     rax, [rdi - 4]\r
+    cmovnz  rax, rcx\r
+    ret\r
+InternalMemScanMem32    ENDP\r
+\r
+    END\r
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/X64/ScanMem64.S b/MdePkg/Library/BaseMemoryLibRepStr/X64/ScanMem64.S
new file mode 100644 (file)
index 0000000..ee2ce39
--- /dev/null
@@ -0,0 +1,57 @@
+#
+# ConvertAsm.py: Automatically generated from ScanMem64.asm
+#
+#------------------------------------------------------------------------------
+#
+# Copyright (c) 2006, Intel Corporation
+# All rights reserved. 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:
+#
+#   ScanMem64.S
+#
+# Abstract:
+#
+#   ScanMem64 function
+#
+# Notes:
+#
+#   The following BaseMemoryLib instances contain the same copy of this file:
+#
+#       BaseMemoryLibRepStr
+#       BaseMemoryLibMmx
+#       BaseMemoryLibSse2
+#       BaseMemoryLibOptDxe
+#       BaseMemoryLibOptPei
+#
+#------------------------------------------------------------------------------
+
+
+#------------------------------------------------------------------------------
+# CONST VOID *
+# EFIAPI
+# InternalMemScanMem64 (
+#   IN      CONST VOID                *Buffer,
+#   IN      UINTN                     Length,
+#   IN      UINT64                    Value
+#   );
+#------------------------------------------------------------------------------
+.intel_syntax
+.globl _InternalMemScanMem64
+_InternalMemScanMem64:
+    push    rdi
+    mov     rdi, rcx
+    mov     rax, r8
+    mov     rcx, rdx
+    repne   scasq
+    lea     rax, [rdi - 8]
+    cmovnz  rax, rcx
+    pop     rdi
+    ret
+
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/X64/ScanMem64.asm b/MdePkg/Library/BaseMemoryLibRepStr/X64/ScanMem64.asm
new file mode 100644 (file)
index 0000000..71f85a1
--- /dev/null
@@ -0,0 +1,53 @@
+;------------------------------------------------------------------------------\r
+;\r
+; Copyright (c) 2006, Intel Corporation\r
+; All rights reserved. This program and the accompanying materials\r
+; are licensed and made available under the terms and conditions of the BSD License\r
+; which accompanies this 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
+; Module Name:\r
+;\r
+;   ScanMem64.Asm\r
+;\r
+; Abstract:\r
+;\r
+;   ScanMem64 function\r
+;\r
+; Notes:\r
+;\r
+;   The following BaseMemoryLib instances contain the same copy of this file:\r
+;\r
+;       BaseMemoryLibRepStr\r
+;       BaseMemoryLibMmx\r
+;       BaseMemoryLibSse2\r
+;       BaseMemoryLibOptDxe\r
+;       BaseMemoryLibOptPei\r
+;\r
+;------------------------------------------------------------------------------\r
+\r
+    .code\r
+\r
+;------------------------------------------------------------------------------\r
+; CONST VOID *\r
+; EFIAPI\r
+; InternalMemScanMem64 (\r
+;   IN      CONST VOID                *Buffer,\r
+;   IN      UINTN                     Length,\r
+;   IN      UINT64                    Value\r
+;   );\r
+;------------------------------------------------------------------------------\r
+InternalMemScanMem64    PROC    USES    rdi\r
+    mov     rdi, rcx\r
+    mov     rax, r8\r
+    mov     rcx, rdx\r
+    repne   scasq\r
+    lea     rax, [rdi - 8]\r
+    cmovnz  rax, rcx\r
+    ret\r
+InternalMemScanMem64    ENDP\r
+\r
+    END\r
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/X64/ScanMem8.S b/MdePkg/Library/BaseMemoryLibRepStr/X64/ScanMem8.S
new file mode 100644 (file)
index 0000000..4ff3a95
--- /dev/null
@@ -0,0 +1,57 @@
+#
+# ConvertAsm.py: Automatically generated from ScanMem8.asm
+#
+#------------------------------------------------------------------------------
+#
+# Copyright (c) 2006, Intel Corporation
+# All rights reserved. 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:
+#
+#   ScanMem8.S
+#
+# Abstract:
+#
+#   ScanMem8 function
+#
+# Notes:
+#
+#   The following BaseMemoryLib instances contain the same copy of this file:
+#
+#       BaseMemoryLibRepStr
+#       BaseMemoryLibMmx
+#       BaseMemoryLibSse2
+#       BaseMemoryLibOptDxe
+#       BaseMemoryLibOptPei
+#
+#------------------------------------------------------------------------------
+
+
+#------------------------------------------------------------------------------
+# CONST VOID *
+# EFIAPI
+# InternalMemScanMem8 (
+#   IN      CONST VOID                *Buffer,
+#   IN      UINTN                     Length,
+#   IN      UINT8                     Value
+#   );
+#------------------------------------------------------------------------------
+.intel_syntax
+.globl _InternalMemScanMem8
+_InternalMemScanMem8:
+    push    rdi
+    mov     rdi, rcx
+    mov     rcx, rdx
+    mov     rax, r8
+    repne   scasb
+    lea     rax, [rdi - 1]
+    cmovnz  rax, rcx                    # set rax to 0 if not found
+    pop     rdi
+    ret
+
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/X64/ScanMem8.asm b/MdePkg/Library/BaseMemoryLibRepStr/X64/ScanMem8.asm
new file mode 100644 (file)
index 0000000..39adb01
--- /dev/null
@@ -0,0 +1,53 @@
+;------------------------------------------------------------------------------\r
+;\r
+; Copyright (c) 2006, Intel Corporation\r
+; All rights reserved. This program and the accompanying materials\r
+; are licensed and made available under the terms and conditions of the BSD License\r
+; which accompanies this 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
+; Module Name:\r
+;\r
+;   ScanMem8.Asm\r
+;\r
+; Abstract:\r
+;\r
+;   ScanMem8 function\r
+;\r
+; Notes:\r
+;\r
+;   The following BaseMemoryLib instances contain the same copy of this file:\r
+;\r
+;       BaseMemoryLibRepStr\r
+;       BaseMemoryLibMmx\r
+;       BaseMemoryLibSse2\r
+;       BaseMemoryLibOptDxe\r
+;       BaseMemoryLibOptPei\r
+;\r
+;------------------------------------------------------------------------------\r
+\r
+    .code\r
+\r
+;------------------------------------------------------------------------------\r
+; CONST VOID *\r
+; EFIAPI\r
+; InternalMemScanMem8 (\r
+;   IN      CONST VOID                *Buffer,\r
+;   IN      UINTN                     Length,\r
+;   IN      UINT8                     Value\r
+;   );\r
+;------------------------------------------------------------------------------\r
+InternalMemScanMem8 PROC    USES    rdi\r
+    mov     rdi, rcx\r
+    mov     rcx, rdx\r
+    mov     rax, r8\r
+    repne   scasb\r
+    lea     rax, [rdi - 1]\r
+    cmovnz  rax, rcx                    ; set rax to 0 if not found\r
+    ret\r
+InternalMemScanMem8 ENDP\r
+\r
+    END\r
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/X64/SetMem.S b/MdePkg/Library/BaseMemoryLibRepStr/X64/SetMem.S
new file mode 100644 (file)
index 0000000..d9f8b06
--- /dev/null
@@ -0,0 +1,48 @@
+#
+# ConvertAsm.py: Automatically generated from SetMem.asm
+#
+#------------------------------------------------------------------------------
+#
+# Copyright (c) 2006, Intel Corporation
+# All rights reserved. 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:
+#
+#   SetMem.S
+#
+# Abstract:
+#
+#   SetMem function
+#
+# Notes:
+#
+#------------------------------------------------------------------------------
+
+
+#------------------------------------------------------------------------------
+#  VOID *
+#  EFIAPI
+#  InternalMemSetMem (
+#    IN VOID   *Buffer,
+#    IN UINTN  Count,
+#    IN UINT8  Value
+#    )
+#------------------------------------------------------------------------------
+.intel_syntax
+.globl _InternalMemSetMem
+_InternalMemSetMem:
+    push    rdi
+    mov     rax, r8    # rax = Value
+    mov     rdi, rcx   # rdi = Buffer
+    xchg    rcx, rdx   # rcx = Count, rdx = Buffer
+    rep     stosb
+    mov     rax, rdx   # rax = Buffer
+    pop     rdi
+    ret
+
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/X64/SetMem.asm b/MdePkg/Library/BaseMemoryLibRepStr/X64/SetMem.asm
new file mode 100644 (file)
index 0000000..fe1bc70
--- /dev/null
@@ -0,0 +1,44 @@
+;------------------------------------------------------------------------------\r
+;\r
+; Copyright (c) 2006, Intel Corporation\r
+; All rights reserved. This program and the accompanying materials\r
+; are licensed and made available under the terms and conditions of the BSD License\r
+; which accompanies this 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
+; Module Name:\r
+;\r
+;   SetMem.Asm\r
+;\r
+; Abstract:\r
+;\r
+;   SetMem function\r
+;\r
+; Notes:\r
+;\r
+;------------------------------------------------------------------------------\r
+\r
+    .code\r
+\r
+;------------------------------------------------------------------------------\r
+;  VOID *\r
+;  EFIAPI\r
+;  InternalMemSetMem (\r
+;    IN VOID   *Buffer,\r
+;    IN UINTN  Count,\r
+;    IN UINT8  Value\r
+;    )\r
+;------------------------------------------------------------------------------\r
+InternalMemSetMem   PROC    USES    rdi\r
+    mov     rax, r8    ; rax = Value\r
+    mov     rdi, rcx   ; rdi = Buffer\r
+    xchg    rcx, rdx   ; rcx = Count, rdx = Buffer\r
+    rep     stosb\r
+    mov     rax, rdx   ; rax = Buffer\r
+    ret\r
+InternalMemSetMem   ENDP\r
+\r
+    END\r
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/X64/SetMem16.S b/MdePkg/Library/BaseMemoryLibRepStr/X64/SetMem16.S
new file mode 100644 (file)
index 0000000..5f19646
--- /dev/null
@@ -0,0 +1,48 @@
+#
+# ConvertAsm.py: Automatically generated from SetMem16.asm
+#
+#------------------------------------------------------------------------------
+#
+# Copyright (c) 2006, Intel Corporation
+# All rights reserved. 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:
+#
+#   SetMem16.S
+#
+# Abstract:
+#
+#   SetMem16 function
+#
+# Notes:
+#
+#------------------------------------------------------------------------------
+
+
+#------------------------------------------------------------------------------
+#  VOID *
+#  EFIAPI
+#  InternalMemSetMem16 (
+#    IN VOID   *Buffer,
+#    IN UINTN  Count,
+#    IN UINT16 Value
+#    )
+#------------------------------------------------------------------------------
+.intel_syntax
+.globl _InternalMemSetMem16
+_InternalMemSetMem16:
+    push    rdi
+    mov     rdi, rcx
+    mov     rax, r8
+    xchg    rcx, rdx
+    rep     stosw
+    mov     rax, rdx
+    pop     rdi
+    ret
+
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/X64/SetMem16.asm b/MdePkg/Library/BaseMemoryLibRepStr/X64/SetMem16.asm
new file mode 100644 (file)
index 0000000..fce9ed7
--- /dev/null
@@ -0,0 +1,44 @@
+;------------------------------------------------------------------------------\r
+;\r
+; Copyright (c) 2006, Intel Corporation\r
+; All rights reserved. This program and the accompanying materials\r
+; are licensed and made available under the terms and conditions of the BSD License\r
+; which accompanies this 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
+; Module Name:\r
+;\r
+;   SetMem16.Asm\r
+;\r
+; Abstract:\r
+;\r
+;   SetMem16 function\r
+;\r
+; Notes:\r
+;\r
+;------------------------------------------------------------------------------\r
+\r
+    .code\r
+\r
+;------------------------------------------------------------------------------\r
+;  VOID *\r
+;  EFIAPI\r
+;  InternalMemSetMem16 (\r
+;    IN VOID   *Buffer,\r
+;    IN UINTN  Count,\r
+;    IN UINT16 Value\r
+;    )\r
+;------------------------------------------------------------------------------\r
+InternalMemSetMem16 PROC    USES    rdi\r
+    mov     rdi, rcx\r
+    mov     rax, r8\r
+    xchg    rcx, rdx\r
+    rep     stosw\r
+    mov     rax, rdx\r
+    ret\r
+InternalMemSetMem16 ENDP\r
+\r
+    END\r
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/X64/SetMem32.S b/MdePkg/Library/BaseMemoryLibRepStr/X64/SetMem32.S
new file mode 100644 (file)
index 0000000..72243ae
--- /dev/null
@@ -0,0 +1,48 @@
+#
+# ConvertAsm.py: Automatically generated from SetMem32.asm
+#
+#------------------------------------------------------------------------------
+#
+# Copyright (c) 2006, Intel Corporation
+# All rights reserved. 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:
+#
+#   SetMem32.S
+#
+# Abstract:
+#
+#   SetMem32 function
+#
+# Notes:
+#
+#------------------------------------------------------------------------------
+
+
+#------------------------------------------------------------------------------
+#  VOID *
+#  EFIAPI
+#  InternalMemSetMem32 (
+#    IN VOID   *Buffer,
+#    IN UINTN  Count,
+#    IN UINT32 Value
+#    );
+#------------------------------------------------------------------------------
+.intel_syntax
+.globl _InternalMemSetMem32
+_InternalMemSetMem32:
+    push    rdi
+    mov     rdi, rcx
+    mov     rax, r8
+    xchg    rcx, rdx
+    rep     stosd
+    mov     rax, rdx
+    pop     rdi
+    ret
+
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/X64/SetMem32.asm b/MdePkg/Library/BaseMemoryLibRepStr/X64/SetMem32.asm
new file mode 100644 (file)
index 0000000..ce9e54d
--- /dev/null
@@ -0,0 +1,44 @@
+;------------------------------------------------------------------------------\r
+;\r
+; Copyright (c) 2006, Intel Corporation\r
+; All rights reserved. This program and the accompanying materials\r
+; are licensed and made available under the terms and conditions of the BSD License\r
+; which accompanies this 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
+; Module Name:\r
+;\r
+;   SetMem32.Asm\r
+;\r
+; Abstract:\r
+;\r
+;   SetMem32 function\r
+;\r
+; Notes:\r
+;\r
+;------------------------------------------------------------------------------\r
+\r
+    .code\r
+\r
+;------------------------------------------------------------------------------\r
+;  VOID *\r
+;  EFIAPI\r
+;  InternalMemSetMem32 (\r
+;    IN VOID   *Buffer,\r
+;    IN UINTN  Count,\r
+;    IN UINT32 Value\r
+;    );\r
+;------------------------------------------------------------------------------\r
+InternalMemSetMem32 PROC    USES    rdi\r
+    mov     rdi, rcx\r
+    mov     rax, r8\r
+    xchg    rcx, rdx\r
+    rep     stosd\r
+    mov     rax, rdx\r
+    ret\r
+InternalMemSetMem32 ENDP\r
+\r
+    END\r
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/X64/SetMem64.S b/MdePkg/Library/BaseMemoryLibRepStr/X64/SetMem64.S
new file mode 100644 (file)
index 0000000..a8a4a0b
--- /dev/null
@@ -0,0 +1,47 @@
+#
+# ConvertAsm.py: Automatically generated from SetMem64.asm
+#
+#------------------------------------------------------------------------------
+#
+# Copyright (c) 2006, Intel Corporation
+# All rights reserved. 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:
+#
+#   SetMem64.S
+#
+# Abstract:
+#
+#   SetMem64 function
+#
+# Notes:
+#
+#------------------------------------------------------------------------------
+
+
+#------------------------------------------------------------------------------
+#  VOID *
+#  InternalMemSetMem64 (
+#    IN VOID   *Buffer,
+#    IN UINTN  Count,
+#    IN UINT64 Value
+#    )
+#------------------------------------------------------------------------------
+.intel_syntax
+.globl _InternalMemSetMem64
+_InternalMemSetMem64:
+    push    rdi
+    mov     rdi, rcx
+    mov     rax, r8
+    xchg    rcx, rdx
+    rep     stosq
+    mov     rax, rdx
+    pop     rdi
+    ret
+
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/X64/SetMem64.asm b/MdePkg/Library/BaseMemoryLibRepStr/X64/SetMem64.asm
new file mode 100644 (file)
index 0000000..97884a3
--- /dev/null
@@ -0,0 +1,43 @@
+;------------------------------------------------------------------------------\r
+;\r
+; Copyright (c) 2006, Intel Corporation\r
+; All rights reserved. This program and the accompanying materials\r
+; are licensed and made available under the terms and conditions of the BSD License\r
+; which accompanies this 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
+; Module Name:\r
+;\r
+;   SetMem64.Asm\r
+;\r
+; Abstract:\r
+;\r
+;   SetMem64 function\r
+;\r
+; Notes:\r
+;\r
+;------------------------------------------------------------------------------\r
+\r
+    .code\r
+\r
+;------------------------------------------------------------------------------\r
+;  VOID *\r
+;  InternalMemSetMem64 (\r
+;    IN VOID   *Buffer,\r
+;    IN UINTN  Count,\r
+;    IN UINT64 Value\r
+;    )\r
+;------------------------------------------------------------------------------\r
+InternalMemSetMem64 PROC    USES    rdi\r
+    mov     rdi, rcx\r
+    mov     rax, r8\r
+    xchg    rcx, rdx\r
+    rep     stosq\r
+    mov     rax, rdx\r
+    ret\r
+InternalMemSetMem64 ENDP\r
+\r
+    END\r
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/X64/ZeroMem.S b/MdePkg/Library/BaseMemoryLibRepStr/X64/ZeroMem.S
new file mode 100644 (file)
index 0000000..6233b06
--- /dev/null
@@ -0,0 +1,51 @@
+#
+# ConvertAsm.py: Automatically generated from ZeroMem.asm
+#
+#------------------------------------------------------------------------------
+#
+# Copyright (c) 2006, Intel Corporation
+# All rights reserved. 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:
+#
+#   ZeroMem.S
+#
+# Abstract:
+#
+#   ZeroMem function
+#
+# Notes:
+#
+#------------------------------------------------------------------------------
+
+
+#------------------------------------------------------------------------------
+#  VOID *
+#  InternalMemZeroMem (
+#    IN VOID   *Buffer,
+#    IN UINTN  Count
+#    );
+#------------------------------------------------------------------------------
+.intel_syntax
+.globl _InternalMemZeroMem
+_InternalMemZeroMem:
+    push    rdi
+    push    rcx
+    xor     rax, rax
+    mov     rdi, rcx
+    mov     rcx, rdx
+    shr     rcx, 3
+    and     rdx, 7
+    rep     stosq
+    mov     ecx, edx
+    rep     stosb
+    pop     rax
+    pop     rdi
+    ret
+
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/X64/ZeroMem.asm b/MdePkg/Library/BaseMemoryLibRepStr/X64/ZeroMem.asm
new file mode 100644 (file)
index 0000000..c01af8e
--- /dev/null
@@ -0,0 +1,47 @@
+;------------------------------------------------------------------------------\r
+;\r
+; Copyright (c) 2006, Intel Corporation\r
+; All rights reserved. This program and the accompanying materials\r
+; are licensed and made available under the terms and conditions of the BSD License\r
+; which accompanies this 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
+; Module Name:\r
+;\r
+;   ZeroMem.Asm\r
+;\r
+; Abstract:\r
+;\r
+;   ZeroMem function\r
+;\r
+; Notes:\r
+;\r
+;------------------------------------------------------------------------------\r
+\r
+    .code\r
+\r
+;------------------------------------------------------------------------------\r
+;  VOID *\r
+;  InternalMemZeroMem (\r
+;    IN VOID   *Buffer,\r
+;    IN UINTN  Count\r
+;    );\r
+;------------------------------------------------------------------------------\r
+InternalMemZeroMem  PROC    USES    rdi\r
+    push    rcx\r
+    xor     rax, rax\r
+    mov     rdi, rcx\r
+    mov     rcx, rdx\r
+    shr     rcx, 3\r
+    and     rdx, 7\r
+    rep     stosq\r
+    mov     ecx, edx\r
+    rep     stosb\r
+    pop     rax\r
+    ret\r
+InternalMemZeroMem  ENDP\r
+\r
+    END\r
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/x64/CompareMem.S b/MdePkg/Library/BaseMemoryLibRepStr/x64/CompareMem.S
deleted file mode 100644 (file)
index 46dfe0a..0000000
+++ /dev/null
@@ -1,60 +0,0 @@
-#
-# ConvertAsm.py: Automatically generated from CompareMem.asm
-#
-#------------------------------------------------------------------------------
-#
-# Copyright (c) 2006, Intel Corporation
-# All rights reserved. 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:
-#
-#   CompareMem.S
-#
-# Abstract:
-#
-#   CompareMem function
-#
-# Notes:
-#
-#   The following BaseMemoryLib instances contain the same copy of this file:
-#
-#       BaseMemoryLibRepStr
-#       BaseMemoryLibMmx
-#       BaseMemoryLibSse2
-#       BaseMemoryLibOptDxe
-#       BaseMemoryLibOptPei
-#
-#------------------------------------------------------------------------------
-
-
-#------------------------------------------------------------------------------
-# INTN
-# EFIAPI
-# InternalMemCompareMem (
-#   IN      CONST VOID                *DestinationBuffer,
-#   IN      CONST VOID                *SourceBuffer,
-#   IN      UINTN                     Length
-#   );
-#------------------------------------------------------------------------------
-.intel_syntax
-.globl _InternalMemCompareMem
-_InternalMemCompareMem:
-    push    rsi
-    push    rdi
-    mov     rsi, rcx
-    mov     rdi, rdx
-    mov     rcx, r8
-    repe    cmpsb
-    movzx   rax, byte ptr [rsi - 1]
-    movzx   rdx, byte ptr [rdi - 1]
-    sub     rax, rdx
-    pop     rdi
-    pop     rsi
-    ret
-
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/x64/CompareMem.asm b/MdePkg/Library/BaseMemoryLibRepStr/x64/CompareMem.asm
deleted file mode 100644 (file)
index 7446a05..0000000
+++ /dev/null
@@ -1,54 +0,0 @@
-;------------------------------------------------------------------------------\r
-;\r
-; Copyright (c) 2006, Intel Corporation\r
-; All rights reserved. This program and the accompanying materials\r
-; are licensed and made available under the terms and conditions of the BSD License\r
-; which accompanies this 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
-; Module Name:\r
-;\r
-;   CompareMem.Asm\r
-;\r
-; Abstract:\r
-;\r
-;   CompareMem function\r
-;\r
-; Notes:\r
-;\r
-;   The following BaseMemoryLib instances contain the same copy of this file:\r
-;\r
-;       BaseMemoryLibRepStr\r
-;       BaseMemoryLibMmx\r
-;       BaseMemoryLibSse2\r
-;       BaseMemoryLibOptDxe\r
-;       BaseMemoryLibOptPei\r
-;\r
-;------------------------------------------------------------------------------\r
-\r
-    .code\r
-\r
-;------------------------------------------------------------------------------\r
-; INTN\r
-; EFIAPI\r
-; InternalMemCompareMem (\r
-;   IN      CONST VOID                *DestinationBuffer,\r
-;   IN      CONST VOID                *SourceBuffer,\r
-;   IN      UINTN                     Length\r
-;   );\r
-;------------------------------------------------------------------------------\r
-InternalMemCompareMem   PROC    USES    rsi rdi\r
-    mov     rsi, rcx\r
-    mov     rdi, rdx\r
-    mov     rcx, r8\r
-    repe    cmpsb\r
-    movzx   rax, byte ptr [rsi - 1]\r
-    movzx   rdx, byte ptr [rdi - 1]\r
-    sub     rax, rdx\r
-    ret\r
-InternalMemCompareMem   ENDP\r
-\r
-    END\r
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/x64/CopyMem.S b/MdePkg/Library/BaseMemoryLibRepStr/x64/CopyMem.S
deleted file mode 100644 (file)
index fe67040..0000000
+++ /dev/null
@@ -1,67 +0,0 @@
-#
-# ConvertAsm.py: Automatically generated from CopyMem.asm
-#
-#------------------------------------------------------------------------------
-#
-# Copyright (c) 2006, Intel Corporation
-# All rights reserved. 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:
-#
-#   CopyMem.S
-#
-# Abstract:
-#
-#   CopyMem function
-#
-# Notes:
-#
-#------------------------------------------------------------------------------
-
-
-#------------------------------------------------------------------------------
-#  VOID *
-#  EFIAPI
-#  InternalMemCopyMem (
-#    IN VOID   *Destination,
-#    IN VOID   *Source,
-#    IN UINTN  Count
-#    )
-#------------------------------------------------------------------------------
-.intel_syntax
-.globl _InternalMemCopyMem
-_InternalMemCopyMem:
-    push    rsi
-    push    rdi
-    mov     rsi, rdx                    # rsi <- Source
-    mov     rdi, rcx                    # rdi <- Destination
-    lea     r9, [rsi + r8 - 1]          # r9 <- End of Source
-    cmp     rsi, rdi
-    mov     rax, rdi                    # rax <- Destination as return value
-    jae     _InternalMemCopyMem_al_0000
-    cmp     r9, rdi
-    jae     _atSym_CopyBackward               # Copy backward if overlapped
-_InternalMemCopyMem_al_0000:
-    mov     rcx, r8
-    and     r8, 7
-    shr     rcx, 3
-    rep     movsq                       # Copy as many Qwords as possible
-    jmp     _atSym_CopyBytes
-_atSym_CopyBackward:
-    mov     rsi, r9                     # rsi <- End of Source
-    lea     rdi, [rdi + r8 - 1]         # esi <- End of Destination
-    std                                 # set direction flag
-_atSym_CopyBytes:
-    mov     rcx, r8
-    rep     movsb                       # Copy bytes backward
-    cld
-    pop     rdi
-    pop     rsi
-    ret
-
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/x64/CopyMem.asm b/MdePkg/Library/BaseMemoryLibRepStr/x64/CopyMem.asm
deleted file mode 100644 (file)
index c2b5d6f..0000000
+++ /dev/null
@@ -1,61 +0,0 @@
-;------------------------------------------------------------------------------\r
-;\r
-; Copyright (c) 2006, Intel Corporation\r
-; All rights reserved. This program and the accompanying materials\r
-; are licensed and made available under the terms and conditions of the BSD License\r
-; which accompanies this 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
-; Module Name:\r
-;\r
-;   CopyMem.Asm\r
-;\r
-; Abstract:\r
-;\r
-;   CopyMem function\r
-;\r
-; Notes:\r
-;\r
-;------------------------------------------------------------------------------\r
-\r
-    .code\r
-\r
-;------------------------------------------------------------------------------\r
-;  VOID *\r
-;  EFIAPI\r
-;  InternalMemCopyMem (\r
-;    IN VOID   *Destination,\r
-;    IN VOID   *Source,\r
-;    IN UINTN  Count\r
-;    )\r
-;------------------------------------------------------------------------------\r
-InternalMemCopyMem  PROC    USES    rsi rdi\r
-    mov     rsi, rdx                    ; rsi <- Source\r
-    mov     rdi, rcx                    ; rdi <- Destination\r
-    lea     r9, [rsi + r8 - 1]          ; r9 <- End of Source\r
-    cmp     rsi, rdi\r
-    mov     rax, rdi                    ; rax <- Destination as return value\r
-    jae     @F\r
-    cmp     r9, rdi\r
-    jae     @CopyBackward               ; Copy backward if overlapped\r
-@@:\r
-    mov     rcx, r8\r
-    and     r8, 7\r
-    shr     rcx, 3\r
-    rep     movsq                       ; Copy as many Qwords as possible\r
-    jmp     @CopyBytes\r
-@CopyBackward:\r
-    mov     rsi, r9                     ; rsi <- End of Source\r
-    lea     rdi, [rdi + r8 - 1]         ; esi <- End of Destination\r
-    std                                 ; set direction flag\r
-@CopyBytes:\r
-    mov     rcx, r8\r
-    rep     movsb                       ; Copy bytes backward\r
-    cld\r
-    ret\r
-InternalMemCopyMem  ENDP\r
-\r
-    END\r
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/x64/ScanMem16.S b/MdePkg/Library/BaseMemoryLibRepStr/x64/ScanMem16.S
deleted file mode 100644 (file)
index f56b9e9..0000000
+++ /dev/null
@@ -1,57 +0,0 @@
-#
-# ConvertAsm.py: Automatically generated from ScanMem16.asm
-#
-#------------------------------------------------------------------------------
-#
-# Copyright (c) 2006, Intel Corporation
-# All rights reserved. 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:
-#
-#   ScanMem16.S
-#
-# Abstract:
-#
-#   ScanMem16 function
-#
-# Notes:
-#
-#   The following BaseMemoryLib instances contain the same copy of this file:
-#
-#       BaseMemoryLibRepStr
-#       BaseMemoryLibMmx
-#       BaseMemoryLibSse2
-#       BaseMemoryLibOptDxe
-#       BaseMemoryLibOptPei
-#
-#------------------------------------------------------------------------------
-
-
-#------------------------------------------------------------------------------
-# CONST VOID *
-# EFIAPI
-# InternalMemScanMem16 (
-#   IN      CONST VOID                *Buffer,
-#   IN      UINTN                     Length,
-#   IN      UINT16                    Value
-#   );
-#------------------------------------------------------------------------------
-.intel_syntax
-.globl _InternalMemScanMem16
-_InternalMemScanMem16:
-    push    rdi
-    mov     rdi, rcx
-    mov     rax, r8
-    mov     rcx, rdx
-    repne   scasw
-    lea     rax, [rdi - 2]
-    cmovnz  rax, rcx
-    pop     rdi
-    ret
-
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/x64/ScanMem16.asm b/MdePkg/Library/BaseMemoryLibRepStr/x64/ScanMem16.asm
deleted file mode 100644 (file)
index 0871a4b..0000000
+++ /dev/null
@@ -1,53 +0,0 @@
-;------------------------------------------------------------------------------\r
-;\r
-; Copyright (c) 2006, Intel Corporation\r
-; All rights reserved. This program and the accompanying materials\r
-; are licensed and made available under the terms and conditions of the BSD License\r
-; which accompanies this 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
-; Module Name:\r
-;\r
-;   ScanMem16.Asm\r
-;\r
-; Abstract:\r
-;\r
-;   ScanMem16 function\r
-;\r
-; Notes:\r
-;\r
-;   The following BaseMemoryLib instances contain the same copy of this file:\r
-;\r
-;       BaseMemoryLibRepStr\r
-;       BaseMemoryLibMmx\r
-;       BaseMemoryLibSse2\r
-;       BaseMemoryLibOptDxe\r
-;       BaseMemoryLibOptPei\r
-;\r
-;------------------------------------------------------------------------------\r
-\r
-    .code\r
-\r
-;------------------------------------------------------------------------------\r
-; CONST VOID *\r
-; EFIAPI\r
-; InternalMemScanMem16 (\r
-;   IN      CONST VOID                *Buffer,\r
-;   IN      UINTN                     Length,\r
-;   IN      UINT16                    Value\r
-;   );\r
-;------------------------------------------------------------------------------\r
-InternalMemScanMem16    PROC    USES    rdi\r
-    mov     rdi, rcx\r
-    mov     rax, r8\r
-    mov     rcx, rdx\r
-    repne   scasw\r
-    lea     rax, [rdi - 2]\r
-    cmovnz  rax, rcx\r
-    ret\r
-InternalMemScanMem16    ENDP\r
-\r
-    END\r
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/x64/ScanMem32.S b/MdePkg/Library/BaseMemoryLibRepStr/x64/ScanMem32.S
deleted file mode 100644 (file)
index ef9cd75..0000000
+++ /dev/null
@@ -1,57 +0,0 @@
-#
-# ConvertAsm.py: Automatically generated from ScanMem32.asm
-#
-#------------------------------------------------------------------------------
-#
-# Copyright (c) 2006, Intel Corporation
-# All rights reserved. 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:
-#
-#   ScanMem32.S
-#
-# Abstract:
-#
-#   ScanMem32 function
-#
-# Notes:
-#
-#   The following BaseMemoryLib instances contain the same copy of this file:
-#
-#       BaseMemoryLibRepStr
-#       BaseMemoryLibMmx
-#       BaseMemoryLibSse2
-#       BaseMemoryLibOptDxe
-#       BaseMemoryLibOptPei
-#
-#------------------------------------------------------------------------------
-
-
-#------------------------------------------------------------------------------
-# CONST VOID *
-# EFIAPI
-# InternalMemScanMem32 (
-#   IN      CONST VOID                *Buffer,
-#   IN      UINTN                     Length,
-#   IN      UINT32                    Value
-#   );
-#------------------------------------------------------------------------------
-.intel_syntax
-.globl _InternalMemScanMem32
-_InternalMemScanMem32:
-    push    rdi
-    mov     rdi, rcx
-    mov     rax, r8
-    mov     rcx, rdx
-    repne   scasd
-    lea     rax, [rdi - 4]
-    cmovnz  rax, rcx
-    pop     rdi
-    ret
-
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/x64/ScanMem32.asm b/MdePkg/Library/BaseMemoryLibRepStr/x64/ScanMem32.asm
deleted file mode 100644 (file)
index 53a33ba..0000000
+++ /dev/null
@@ -1,53 +0,0 @@
-;------------------------------------------------------------------------------\r
-;\r
-; Copyright (c) 2006, Intel Corporation\r
-; All rights reserved. This program and the accompanying materials\r
-; are licensed and made available under the terms and conditions of the BSD License\r
-; which accompanies this 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
-; Module Name:\r
-;\r
-;   ScanMem32.Asm\r
-;\r
-; Abstract:\r
-;\r
-;   ScanMem32 function\r
-;\r
-; Notes:\r
-;\r
-;   The following BaseMemoryLib instances contain the same copy of this file:\r
-;\r
-;       BaseMemoryLibRepStr\r
-;       BaseMemoryLibMmx\r
-;       BaseMemoryLibSse2\r
-;       BaseMemoryLibOptDxe\r
-;       BaseMemoryLibOptPei\r
-;\r
-;------------------------------------------------------------------------------\r
-\r
-    .code\r
-\r
-;------------------------------------------------------------------------------\r
-; CONST VOID *\r
-; EFIAPI\r
-; InternalMemScanMem32 (\r
-;   IN      CONST VOID                *Buffer,\r
-;   IN      UINTN                     Length,\r
-;   IN      UINT32                    Value\r
-;   );\r
-;------------------------------------------------------------------------------\r
-InternalMemScanMem32    PROC    USES    rdi\r
-    mov     rdi, rcx\r
-    mov     rax, r8\r
-    mov     rcx, rdx\r
-    repne   scasd\r
-    lea     rax, [rdi - 4]\r
-    cmovnz  rax, rcx\r
-    ret\r
-InternalMemScanMem32    ENDP\r
-\r
-    END\r
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/x64/ScanMem64.S b/MdePkg/Library/BaseMemoryLibRepStr/x64/ScanMem64.S
deleted file mode 100644 (file)
index ee2ce39..0000000
+++ /dev/null
@@ -1,57 +0,0 @@
-#
-# ConvertAsm.py: Automatically generated from ScanMem64.asm
-#
-#------------------------------------------------------------------------------
-#
-# Copyright (c) 2006, Intel Corporation
-# All rights reserved. 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:
-#
-#   ScanMem64.S
-#
-# Abstract:
-#
-#   ScanMem64 function
-#
-# Notes:
-#
-#   The following BaseMemoryLib instances contain the same copy of this file:
-#
-#       BaseMemoryLibRepStr
-#       BaseMemoryLibMmx
-#       BaseMemoryLibSse2
-#       BaseMemoryLibOptDxe
-#       BaseMemoryLibOptPei
-#
-#------------------------------------------------------------------------------
-
-
-#------------------------------------------------------------------------------
-# CONST VOID *
-# EFIAPI
-# InternalMemScanMem64 (
-#   IN      CONST VOID                *Buffer,
-#   IN      UINTN                     Length,
-#   IN      UINT64                    Value
-#   );
-#------------------------------------------------------------------------------
-.intel_syntax
-.globl _InternalMemScanMem64
-_InternalMemScanMem64:
-    push    rdi
-    mov     rdi, rcx
-    mov     rax, r8
-    mov     rcx, rdx
-    repne   scasq
-    lea     rax, [rdi - 8]
-    cmovnz  rax, rcx
-    pop     rdi
-    ret
-
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/x64/ScanMem64.asm b/MdePkg/Library/BaseMemoryLibRepStr/x64/ScanMem64.asm
deleted file mode 100644 (file)
index 71f85a1..0000000
+++ /dev/null
@@ -1,53 +0,0 @@
-;------------------------------------------------------------------------------\r
-;\r
-; Copyright (c) 2006, Intel Corporation\r
-; All rights reserved. This program and the accompanying materials\r
-; are licensed and made available under the terms and conditions of the BSD License\r
-; which accompanies this 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
-; Module Name:\r
-;\r
-;   ScanMem64.Asm\r
-;\r
-; Abstract:\r
-;\r
-;   ScanMem64 function\r
-;\r
-; Notes:\r
-;\r
-;   The following BaseMemoryLib instances contain the same copy of this file:\r
-;\r
-;       BaseMemoryLibRepStr\r
-;       BaseMemoryLibMmx\r
-;       BaseMemoryLibSse2\r
-;       BaseMemoryLibOptDxe\r
-;       BaseMemoryLibOptPei\r
-;\r
-;------------------------------------------------------------------------------\r
-\r
-    .code\r
-\r
-;------------------------------------------------------------------------------\r
-; CONST VOID *\r
-; EFIAPI\r
-; InternalMemScanMem64 (\r
-;   IN      CONST VOID                *Buffer,\r
-;   IN      UINTN                     Length,\r
-;   IN      UINT64                    Value\r
-;   );\r
-;------------------------------------------------------------------------------\r
-InternalMemScanMem64    PROC    USES    rdi\r
-    mov     rdi, rcx\r
-    mov     rax, r8\r
-    mov     rcx, rdx\r
-    repne   scasq\r
-    lea     rax, [rdi - 8]\r
-    cmovnz  rax, rcx\r
-    ret\r
-InternalMemScanMem64    ENDP\r
-\r
-    END\r
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/x64/ScanMem8.S b/MdePkg/Library/BaseMemoryLibRepStr/x64/ScanMem8.S
deleted file mode 100644 (file)
index 4ff3a95..0000000
+++ /dev/null
@@ -1,57 +0,0 @@
-#
-# ConvertAsm.py: Automatically generated from ScanMem8.asm
-#
-#------------------------------------------------------------------------------
-#
-# Copyright (c) 2006, Intel Corporation
-# All rights reserved. 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:
-#
-#   ScanMem8.S
-#
-# Abstract:
-#
-#   ScanMem8 function
-#
-# Notes:
-#
-#   The following BaseMemoryLib instances contain the same copy of this file:
-#
-#       BaseMemoryLibRepStr
-#       BaseMemoryLibMmx
-#       BaseMemoryLibSse2
-#       BaseMemoryLibOptDxe
-#       BaseMemoryLibOptPei
-#
-#------------------------------------------------------------------------------
-
-
-#------------------------------------------------------------------------------
-# CONST VOID *
-# EFIAPI
-# InternalMemScanMem8 (
-#   IN      CONST VOID                *Buffer,
-#   IN      UINTN                     Length,
-#   IN      UINT8                     Value
-#   );
-#------------------------------------------------------------------------------
-.intel_syntax
-.globl _InternalMemScanMem8
-_InternalMemScanMem8:
-    push    rdi
-    mov     rdi, rcx
-    mov     rcx, rdx
-    mov     rax, r8
-    repne   scasb
-    lea     rax, [rdi - 1]
-    cmovnz  rax, rcx                    # set rax to 0 if not found
-    pop     rdi
-    ret
-
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/x64/ScanMem8.asm b/MdePkg/Library/BaseMemoryLibRepStr/x64/ScanMem8.asm
deleted file mode 100644 (file)
index 39adb01..0000000
+++ /dev/null
@@ -1,53 +0,0 @@
-;------------------------------------------------------------------------------\r
-;\r
-; Copyright (c) 2006, Intel Corporation\r
-; All rights reserved. This program and the accompanying materials\r
-; are licensed and made available under the terms and conditions of the BSD License\r
-; which accompanies this 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
-; Module Name:\r
-;\r
-;   ScanMem8.Asm\r
-;\r
-; Abstract:\r
-;\r
-;   ScanMem8 function\r
-;\r
-; Notes:\r
-;\r
-;   The following BaseMemoryLib instances contain the same copy of this file:\r
-;\r
-;       BaseMemoryLibRepStr\r
-;       BaseMemoryLibMmx\r
-;       BaseMemoryLibSse2\r
-;       BaseMemoryLibOptDxe\r
-;       BaseMemoryLibOptPei\r
-;\r
-;------------------------------------------------------------------------------\r
-\r
-    .code\r
-\r
-;------------------------------------------------------------------------------\r
-; CONST VOID *\r
-; EFIAPI\r
-; InternalMemScanMem8 (\r
-;   IN      CONST VOID                *Buffer,\r
-;   IN      UINTN                     Length,\r
-;   IN      UINT8                     Value\r
-;   );\r
-;------------------------------------------------------------------------------\r
-InternalMemScanMem8 PROC    USES    rdi\r
-    mov     rdi, rcx\r
-    mov     rcx, rdx\r
-    mov     rax, r8\r
-    repne   scasb\r
-    lea     rax, [rdi - 1]\r
-    cmovnz  rax, rcx                    ; set rax to 0 if not found\r
-    ret\r
-InternalMemScanMem8 ENDP\r
-\r
-    END\r
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/x64/SetMem.S b/MdePkg/Library/BaseMemoryLibRepStr/x64/SetMem.S
deleted file mode 100644 (file)
index d9f8b06..0000000
+++ /dev/null
@@ -1,48 +0,0 @@
-#
-# ConvertAsm.py: Automatically generated from SetMem.asm
-#
-#------------------------------------------------------------------------------
-#
-# Copyright (c) 2006, Intel Corporation
-# All rights reserved. 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:
-#
-#   SetMem.S
-#
-# Abstract:
-#
-#   SetMem function
-#
-# Notes:
-#
-#------------------------------------------------------------------------------
-
-
-#------------------------------------------------------------------------------
-#  VOID *
-#  EFIAPI
-#  InternalMemSetMem (
-#    IN VOID   *Buffer,
-#    IN UINTN  Count,
-#    IN UINT8  Value
-#    )
-#------------------------------------------------------------------------------
-.intel_syntax
-.globl _InternalMemSetMem
-_InternalMemSetMem:
-    push    rdi
-    mov     rax, r8    # rax = Value
-    mov     rdi, rcx   # rdi = Buffer
-    xchg    rcx, rdx   # rcx = Count, rdx = Buffer
-    rep     stosb
-    mov     rax, rdx   # rax = Buffer
-    pop     rdi
-    ret
-
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/x64/SetMem.asm b/MdePkg/Library/BaseMemoryLibRepStr/x64/SetMem.asm
deleted file mode 100644 (file)
index fe1bc70..0000000
+++ /dev/null
@@ -1,44 +0,0 @@
-;------------------------------------------------------------------------------\r
-;\r
-; Copyright (c) 2006, Intel Corporation\r
-; All rights reserved. This program and the accompanying materials\r
-; are licensed and made available under the terms and conditions of the BSD License\r
-; which accompanies this 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
-; Module Name:\r
-;\r
-;   SetMem.Asm\r
-;\r
-; Abstract:\r
-;\r
-;   SetMem function\r
-;\r
-; Notes:\r
-;\r
-;------------------------------------------------------------------------------\r
-\r
-    .code\r
-\r
-;------------------------------------------------------------------------------\r
-;  VOID *\r
-;  EFIAPI\r
-;  InternalMemSetMem (\r
-;    IN VOID   *Buffer,\r
-;    IN UINTN  Count,\r
-;    IN UINT8  Value\r
-;    )\r
-;------------------------------------------------------------------------------\r
-InternalMemSetMem   PROC    USES    rdi\r
-    mov     rax, r8    ; rax = Value\r
-    mov     rdi, rcx   ; rdi = Buffer\r
-    xchg    rcx, rdx   ; rcx = Count, rdx = Buffer\r
-    rep     stosb\r
-    mov     rax, rdx   ; rax = Buffer\r
-    ret\r
-InternalMemSetMem   ENDP\r
-\r
-    END\r
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/x64/SetMem16.S b/MdePkg/Library/BaseMemoryLibRepStr/x64/SetMem16.S
deleted file mode 100644 (file)
index 5f19646..0000000
+++ /dev/null
@@ -1,48 +0,0 @@
-#
-# ConvertAsm.py: Automatically generated from SetMem16.asm
-#
-#------------------------------------------------------------------------------
-#
-# Copyright (c) 2006, Intel Corporation
-# All rights reserved. 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:
-#
-#   SetMem16.S
-#
-# Abstract:
-#
-#   SetMem16 function
-#
-# Notes:
-#
-#------------------------------------------------------------------------------
-
-
-#------------------------------------------------------------------------------
-#  VOID *
-#  EFIAPI
-#  InternalMemSetMem16 (
-#    IN VOID   *Buffer,
-#    IN UINTN  Count,
-#    IN UINT16 Value
-#    )
-#------------------------------------------------------------------------------
-.intel_syntax
-.globl _InternalMemSetMem16
-_InternalMemSetMem16:
-    push    rdi
-    mov     rdi, rcx
-    mov     rax, r8
-    xchg    rcx, rdx
-    rep     stosw
-    mov     rax, rdx
-    pop     rdi
-    ret
-
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/x64/SetMem16.asm b/MdePkg/Library/BaseMemoryLibRepStr/x64/SetMem16.asm
deleted file mode 100644 (file)
index fce9ed7..0000000
+++ /dev/null
@@ -1,44 +0,0 @@
-;------------------------------------------------------------------------------\r
-;\r
-; Copyright (c) 2006, Intel Corporation\r
-; All rights reserved. This program and the accompanying materials\r
-; are licensed and made available under the terms and conditions of the BSD License\r
-; which accompanies this 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
-; Module Name:\r
-;\r
-;   SetMem16.Asm\r
-;\r
-; Abstract:\r
-;\r
-;   SetMem16 function\r
-;\r
-; Notes:\r
-;\r
-;------------------------------------------------------------------------------\r
-\r
-    .code\r
-\r
-;------------------------------------------------------------------------------\r
-;  VOID *\r
-;  EFIAPI\r
-;  InternalMemSetMem16 (\r
-;    IN VOID   *Buffer,\r
-;    IN UINTN  Count,\r
-;    IN UINT16 Value\r
-;    )\r
-;------------------------------------------------------------------------------\r
-InternalMemSetMem16 PROC    USES    rdi\r
-    mov     rdi, rcx\r
-    mov     rax, r8\r
-    xchg    rcx, rdx\r
-    rep     stosw\r
-    mov     rax, rdx\r
-    ret\r
-InternalMemSetMem16 ENDP\r
-\r
-    END\r
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/x64/SetMem32.S b/MdePkg/Library/BaseMemoryLibRepStr/x64/SetMem32.S
deleted file mode 100644 (file)
index 72243ae..0000000
+++ /dev/null
@@ -1,48 +0,0 @@
-#
-# ConvertAsm.py: Automatically generated from SetMem32.asm
-#
-#------------------------------------------------------------------------------
-#
-# Copyright (c) 2006, Intel Corporation
-# All rights reserved. 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:
-#
-#   SetMem32.S
-#
-# Abstract:
-#
-#   SetMem32 function
-#
-# Notes:
-#
-#------------------------------------------------------------------------------
-
-
-#------------------------------------------------------------------------------
-#  VOID *
-#  EFIAPI
-#  InternalMemSetMem32 (
-#    IN VOID   *Buffer,
-#    IN UINTN  Count,
-#    IN UINT32 Value
-#    );
-#------------------------------------------------------------------------------
-.intel_syntax
-.globl _InternalMemSetMem32
-_InternalMemSetMem32:
-    push    rdi
-    mov     rdi, rcx
-    mov     rax, r8
-    xchg    rcx, rdx
-    rep     stosd
-    mov     rax, rdx
-    pop     rdi
-    ret
-
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/x64/SetMem32.asm b/MdePkg/Library/BaseMemoryLibRepStr/x64/SetMem32.asm
deleted file mode 100644 (file)
index ce9e54d..0000000
+++ /dev/null
@@ -1,44 +0,0 @@
-;------------------------------------------------------------------------------\r
-;\r
-; Copyright (c) 2006, Intel Corporation\r
-; All rights reserved. This program and the accompanying materials\r
-; are licensed and made available under the terms and conditions of the BSD License\r
-; which accompanies this 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
-; Module Name:\r
-;\r
-;   SetMem32.Asm\r
-;\r
-; Abstract:\r
-;\r
-;   SetMem32 function\r
-;\r
-; Notes:\r
-;\r
-;------------------------------------------------------------------------------\r
-\r
-    .code\r
-\r
-;------------------------------------------------------------------------------\r
-;  VOID *\r
-;  EFIAPI\r
-;  InternalMemSetMem32 (\r
-;    IN VOID   *Buffer,\r
-;    IN UINTN  Count,\r
-;    IN UINT32 Value\r
-;    );\r
-;------------------------------------------------------------------------------\r
-InternalMemSetMem32 PROC    USES    rdi\r
-    mov     rdi, rcx\r
-    mov     rax, r8\r
-    xchg    rcx, rdx\r
-    rep     stosd\r
-    mov     rax, rdx\r
-    ret\r
-InternalMemSetMem32 ENDP\r
-\r
-    END\r
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/x64/SetMem64.S b/MdePkg/Library/BaseMemoryLibRepStr/x64/SetMem64.S
deleted file mode 100644 (file)
index a8a4a0b..0000000
+++ /dev/null
@@ -1,47 +0,0 @@
-#
-# ConvertAsm.py: Automatically generated from SetMem64.asm
-#
-#------------------------------------------------------------------------------
-#
-# Copyright (c) 2006, Intel Corporation
-# All rights reserved. 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:
-#
-#   SetMem64.S
-#
-# Abstract:
-#
-#   SetMem64 function
-#
-# Notes:
-#
-#------------------------------------------------------------------------------
-
-
-#------------------------------------------------------------------------------
-#  VOID *
-#  InternalMemSetMem64 (
-#    IN VOID   *Buffer,
-#    IN UINTN  Count,
-#    IN UINT64 Value
-#    )
-#------------------------------------------------------------------------------
-.intel_syntax
-.globl _InternalMemSetMem64
-_InternalMemSetMem64:
-    push    rdi
-    mov     rdi, rcx
-    mov     rax, r8
-    xchg    rcx, rdx
-    rep     stosq
-    mov     rax, rdx
-    pop     rdi
-    ret
-
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/x64/SetMem64.asm b/MdePkg/Library/BaseMemoryLibRepStr/x64/SetMem64.asm
deleted file mode 100644 (file)
index 97884a3..0000000
+++ /dev/null
@@ -1,43 +0,0 @@
-;------------------------------------------------------------------------------\r
-;\r
-; Copyright (c) 2006, Intel Corporation\r
-; All rights reserved. This program and the accompanying materials\r
-; are licensed and made available under the terms and conditions of the BSD License\r
-; which accompanies this 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
-; Module Name:\r
-;\r
-;   SetMem64.Asm\r
-;\r
-; Abstract:\r
-;\r
-;   SetMem64 function\r
-;\r
-; Notes:\r
-;\r
-;------------------------------------------------------------------------------\r
-\r
-    .code\r
-\r
-;------------------------------------------------------------------------------\r
-;  VOID *\r
-;  InternalMemSetMem64 (\r
-;    IN VOID   *Buffer,\r
-;    IN UINTN  Count,\r
-;    IN UINT64 Value\r
-;    )\r
-;------------------------------------------------------------------------------\r
-InternalMemSetMem64 PROC    USES    rdi\r
-    mov     rdi, rcx\r
-    mov     rax, r8\r
-    xchg    rcx, rdx\r
-    rep     stosq\r
-    mov     rax, rdx\r
-    ret\r
-InternalMemSetMem64 ENDP\r
-\r
-    END\r
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/x64/ZeroMem.S b/MdePkg/Library/BaseMemoryLibRepStr/x64/ZeroMem.S
deleted file mode 100644 (file)
index 6233b06..0000000
+++ /dev/null
@@ -1,51 +0,0 @@
-#
-# ConvertAsm.py: Automatically generated from ZeroMem.asm
-#
-#------------------------------------------------------------------------------
-#
-# Copyright (c) 2006, Intel Corporation
-# All rights reserved. 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:
-#
-#   ZeroMem.S
-#
-# Abstract:
-#
-#   ZeroMem function
-#
-# Notes:
-#
-#------------------------------------------------------------------------------
-
-
-#------------------------------------------------------------------------------
-#  VOID *
-#  InternalMemZeroMem (
-#    IN VOID   *Buffer,
-#    IN UINTN  Count
-#    );
-#------------------------------------------------------------------------------
-.intel_syntax
-.globl _InternalMemZeroMem
-_InternalMemZeroMem:
-    push    rdi
-    push    rcx
-    xor     rax, rax
-    mov     rdi, rcx
-    mov     rcx, rdx
-    shr     rcx, 3
-    and     rdx, 7
-    rep     stosq
-    mov     ecx, edx
-    rep     stosb
-    pop     rax
-    pop     rdi
-    ret
-
diff --git a/MdePkg/Library/BaseMemoryLibRepStr/x64/ZeroMem.asm b/MdePkg/Library/BaseMemoryLibRepStr/x64/ZeroMem.asm
deleted file mode 100644 (file)
index c01af8e..0000000
+++ /dev/null
@@ -1,47 +0,0 @@
-;------------------------------------------------------------------------------\r
-;\r
-; Copyright (c) 2006, Intel Corporation\r
-; All rights reserved. This program and the accompanying materials\r
-; are licensed and made available under the terms and conditions of the BSD License\r
-; which accompanies this 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
-; Module Name:\r
-;\r
-;   ZeroMem.Asm\r
-;\r
-; Abstract:\r
-;\r
-;   ZeroMem function\r
-;\r
-; Notes:\r
-;\r
-;------------------------------------------------------------------------------\r
-\r
-    .code\r
-\r
-;------------------------------------------------------------------------------\r
-;  VOID *\r
-;  InternalMemZeroMem (\r
-;    IN VOID   *Buffer,\r
-;    IN UINTN  Count\r
-;    );\r
-;------------------------------------------------------------------------------\r
-InternalMemZeroMem  PROC    USES    rdi\r
-    push    rcx\r
-    xor     rax, rax\r
-    mov     rdi, rcx\r
-    mov     rcx, rdx\r
-    shr     rcx, 3\r
-    and     rdx, 7\r
-    rep     stosq\r
-    mov     ecx, edx\r
-    rep     stosb\r
-    pop     rax\r
-    ret\r
-InternalMemZeroMem  ENDP\r
-\r
-    END\r