diff options
Diffstat (limited to 'MdePkg/Library/BaseMemoryLibOptPei/Ia32/SetMem.S')
-rw-r--r-- | MdePkg/Library/BaseMemoryLibOptPei/Ia32/SetMem.S | 23 |
1 files changed, 9 insertions, 14 deletions
diff --git a/MdePkg/Library/BaseMemoryLibOptPei/Ia32/SetMem.S b/MdePkg/Library/BaseMemoryLibOptPei/Ia32/SetMem.S index aa803ca580..64fdfaff5d 100644 --- a/MdePkg/Library/BaseMemoryLibOptPei/Ia32/SetMem.S +++ b/MdePkg/Library/BaseMemoryLibOptPei/Ia32/SetMem.S @@ -21,10 +21,7 @@ # #------------------------------------------------------------------------------ - .386: - .code: - -.globl _InternalMemSetMem +.globl ASM_PFX(InternalMemSetMem) #------------------------------------------------------------------------------ # VOID * @@ -34,22 +31,20 @@ # IN UINT8 Value # ) #------------------------------------------------------------------------------ -_InternalMemSetMem: +ASM_PFX(InternalMemSetMem): push %edi movl 12(%esp),%ecx movb 16(%esp),%al - movb %ah, %al
+ movb %al, %ah shrd $16, %eax, %edx shld $16, %edx, %eax - movl %edx, %ecx
+ movl %ecx, %edx movl 8(%esp),%edi - shrd $2, %ecx, %ecx
- rep
- stosl
- movl %ecx, %edx
- andl $3, %ecx
- rep - stosb + shr $2, %ecx + rep stosl + movl %edx, %ecx + andl $3, %ecx + rep stosb movl 8(%esp),%eax pop %edi ret |