mirror of https://github.com/acidanthera/audk.git
MdePkg/BaseMemoryLibRepStr: Support IA32 processors without CMOVx
Remove use of CMOVx instruction from IA32 assembly files in BaseMemoryLibRepStr. This matches compiler flags for all supported C compilers. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Michael Kinney <michael.d.kinney@intel.com> Reviewed-by: Jordan Justen <jordan.l.justen@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@17214 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
parent
88a75d260c
commit
cfe41b57ab
|
@ -4,7 +4,7 @@
|
|||
# Base Memory Library that uses REP string instructions for
|
||||
# high performance and small size. Optimized for use in PEI.
|
||||
#
|
||||
# Copyright (c) 2007 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
# Copyright (c) 2007 - 2015, 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
|
||||
|
@ -22,7 +22,7 @@
|
|||
MODULE_UNI_FILE = BaseMemoryLibRepStr.uni
|
||||
FILE_GUID = e7884bf4-51a1-485b-982a-ff89129983bc
|
||||
MODULE_TYPE = BASE
|
||||
VERSION_STRING = 1.0
|
||||
VERSION_STRING = 1.1
|
||||
LIBRARY_CLASS = BaseMemoryLib
|
||||
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#------------------------------------------------------------------------------
|
||||
#
|
||||
# Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR>
|
||||
# Copyright (c) 2006 - 2015, 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
|
||||
|
@ -47,6 +47,8 @@ ASM_PFX(InternalMemScanMem16):
|
|||
movl 16(%esp), %eax
|
||||
repne scasw
|
||||
leal -2(%edi), %eax
|
||||
cmovnz %ecx, %eax
|
||||
jz L0
|
||||
movl %ecx, %eax
|
||||
L0:
|
||||
pop %edi
|
||||
ret
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
;------------------------------------------------------------------------------
|
||||
;
|
||||
; Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR>
|
||||
; Copyright (c) 2006 - 2015, 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
|
||||
|
@ -48,7 +48,9 @@ InternalMemScanMem16 PROC USES edi
|
|||
mov eax, [esp + 16]
|
||||
repne scasw
|
||||
lea eax, [edi - 2]
|
||||
cmovnz eax, ecx
|
||||
jz @F
|
||||
mov eax, ecx
|
||||
@@:
|
||||
ret
|
||||
InternalMemScanMem16 ENDP
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#------------------------------------------------------------------------------
|
||||
#
|
||||
# Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR>
|
||||
# Copyright (c) 2006 - 2015, 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
|
||||
|
@ -47,6 +47,8 @@ ASM_PFX(InternalMemScanMem32):
|
|||
movl 16(%esp), %eax
|
||||
repne scasl
|
||||
leal -4(%edi), %eax
|
||||
cmovnz %ecx, %eax
|
||||
jz L0
|
||||
movl %ecx, %eax
|
||||
L0:
|
||||
pop %edi
|
||||
ret
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
;------------------------------------------------------------------------------
|
||||
;
|
||||
; Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR>
|
||||
; Copyright (c) 2006 - 2015, 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
|
||||
|
@ -48,7 +48,9 @@ InternalMemScanMem32 PROC USES edi
|
|||
mov eax, [esp + 16]
|
||||
repne scasd
|
||||
lea eax, [edi - 4]
|
||||
cmovnz eax, ecx
|
||||
jz @F
|
||||
mov eax, ecx
|
||||
@@:
|
||||
ret
|
||||
InternalMemScanMem32 ENDP
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#------------------------------------------------------------------------------
|
||||
#
|
||||
# Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR>
|
||||
# Copyright (c) 2006 - 2015, 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
|
||||
|
@ -56,6 +56,8 @@ L0:
|
|||
jne L0
|
||||
L1:
|
||||
leal -8(%edi), %eax
|
||||
cmovne %ecx, %eax
|
||||
jz L2
|
||||
movl %ecx, %eax
|
||||
L2:
|
||||
pop %edi
|
||||
ret
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
;------------------------------------------------------------------------------
|
||||
;
|
||||
; Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR>
|
||||
; Copyright (c) 2006 - 2015, 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
|
||||
|
@ -57,7 +57,9 @@ InternalMemScanMem64 PROC USES edi
|
|||
jne @B
|
||||
@@:
|
||||
lea eax, [edi - 8]
|
||||
cmovne eax, ecx
|
||||
jz @F
|
||||
mov eax, ecx
|
||||
@@:
|
||||
ret
|
||||
InternalMemScanMem64 ENDP
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#------------------------------------------------------------------------------
|
||||
#
|
||||
# Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR>
|
||||
# Copyright (c) 2006 - 2015, 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
|
||||
|
@ -47,6 +47,8 @@ ASM_PFX(InternalMemScanMem8):
|
|||
movb 16(%esp), %al
|
||||
repne scasb
|
||||
leal -1(%edi), %eax
|
||||
cmovnz %ecx, %eax
|
||||
jz L0
|
||||
movl %ecx, %eax
|
||||
L0:
|
||||
pop %edi
|
||||
ret
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
;------------------------------------------------------------------------------
|
||||
;
|
||||
; Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR>
|
||||
; Copyright (c) 2006 - 2015, 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
|
||||
|
@ -48,7 +48,9 @@ InternalMemScanMem8 PROC USES edi
|
|||
mov al, [esp + 16]
|
||||
repne scasb
|
||||
lea eax, [edi - 1]
|
||||
cmovnz eax, ecx
|
||||
jz @F
|
||||
mov eax, ecx
|
||||
@@:
|
||||
ret
|
||||
InternalMemScanMem8 ENDP
|
||||
|
||||
|
|
Loading…
Reference in New Issue