]> git.proxmox.com Git - mirror_edk2.git/blob - MdePkg/Library/BaseMemoryLibRepStr/X64/SetMem16.nasm
MdePkg: Replace BSD License with BSD+Patent License
[mirror_edk2.git] / MdePkg / Library / BaseMemoryLibRepStr / X64 / SetMem16.nasm
1 ;------------------------------------------------------------------------------
2 ;
3 ; Copyright (c) 2006, Intel Corporation. All rights reserved.<BR>
4 ; SPDX-License-Identifier: BSD-2-Clause-Patent
5 ;
6 ; Module Name:
7 ;
8 ; SetMem16.Asm
9 ;
10 ; Abstract:
11 ;
12 ; SetMem16 function
13 ;
14 ; Notes:
15 ;
16 ;------------------------------------------------------------------------------
17
18 DEFAULT REL
19 SECTION .text
20
21 ;------------------------------------------------------------------------------
22 ; VOID *
23 ; EFIAPI
24 ; InternalMemSetMem16 (
25 ; IN VOID *Buffer,
26 ; IN UINTN Count,
27 ; IN UINT16 Value
28 ; )
29 ;------------------------------------------------------------------------------
30 global ASM_PFX(InternalMemSetMem16)
31 ASM_PFX(InternalMemSetMem16):
32 push rdi
33 mov rdi, rcx
34 mov rax, r8
35 xchg rcx, rdx
36 rep stosw
37 mov rax, rdx
38 pop rdi
39 ret
40