diff options
author | klu2 <klu2@6f19259b-4bc3-4df7-8a09-765794883524> | 2008-10-24 01:49:11 +0000 |
---|---|---|
committer | klu2 <klu2@6f19259b-4bc3-4df7-8a09-765794883524> | 2008-10-24 01:49:11 +0000 |
commit | 1dc58db39be88de3bb8ab12b6acb016549703318 (patch) | |
tree | e602a3927f8b5f0b1d12c1f10a3add8ea752b8c3 /MdePkg/Library/BaseMemoryLibOptDxe/X64/ScanMem8.S | |
parent | bf131e739a9bc751d72e8f2cc221e16f0d554b3d (diff) | |
download | edk2-platforms-1dc58db39be88de3bb8ab12b6acb016549703318.tar.xz |
Add S assembler file for BaseMemoryLibOptDxe driver.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@6201 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'MdePkg/Library/BaseMemoryLibOptDxe/X64/ScanMem8.S')
-rw-r--r-- | MdePkg/Library/BaseMemoryLibOptDxe/X64/ScanMem8.S | 57 |
1 files changed, 57 insertions, 0 deletions
diff --git a/MdePkg/Library/BaseMemoryLibOptDxe/X64/ScanMem8.S b/MdePkg/Library/BaseMemoryLibOptDxe/X64/ScanMem8.S new file mode 100644 index 0000000000..1d8b4e1b23 --- /dev/null +++ b/MdePkg/Library/BaseMemoryLibOptDxe/X64/ScanMem8.S @@ -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 noprefix +.globl ASM_PFX(InternalMemScanMem8) +ASM_PFX(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 + |