]> git.proxmox.com Git - mirror_edk2.git/blame - ArmPkg/Library/CompilerIntrinsicsLib/Arm/uwrite.asm
ArmPkg/CompilerIntrinsicsLib: Added missing __aeabi_uread8 and __aeabi_uwrite8
[mirror_edk2.git] / ArmPkg / Library / CompilerIntrinsicsLib / Arm / uwrite.asm
CommitLineData
2ef2b01e
A
1//------------------------------------------------------------------------------
2//
d6ebcab7 3// Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
2ef2b01e 4//
d6ebcab7 5// This program and the accompanying materials
2ef2b01e
A
6// are licensed and made available under the terms and conditions of the BSD License
7// which accompanies this distribution. The full text of the license may be found at
8// http://opensource.org/licenses/bsd-license.php
9//
10// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
11// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
12//
13//------------------------------------------------------------------------------
14
15
16 EXPORT __aeabi_uwrite4
836a7825 17 EXPORT __aeabi_uwrite8
2ef2b01e
A
18
19 AREA Uwrite4, CODE, READONLY
20
21;
22;UINT32
23;EFIAPI
24;__aeabi_uwrite4 (
25; IN UINT32 Data,
26; IN VOID *Pointer
27; );
28;
29;
30__aeabi_uwrite4
31 mov r2, r0, lsr #8
32 strb r0, [r1]
33 strb r2, [r1, #1]
34 mov r2, r0, lsr #16
35 strb r2, [r1, #2]
36 mov r2, r0, lsr #24
37 strb r2, [r1, #3]
38 bx lr
836a7825 39
40;
41;UINT64
42;EFIAPI
43;__aeabi_uwrite8 (
44; IN UINT64 Data, //r0-r1
45; IN VOID *Pointer //r2
46; );
47;
48;
49__aeabi_uwrite8
50 mov r3, r0, lsr #8
51 strb r0, [r2]
52 strb r3, [r2, #1]
53 mov r3, r0, lsr #16
54 strb r3, [r2, #2]
55 mov r3, r0, lsr #24
56 strb r3, [r2, #3]
57
58 mov r3, r1, lsr #8
59 strb r1, [r2, #4]
60 strb r3, [r2, #5]
61 mov r3, r1, lsr #16
62 strb r3, [r2, #6]
63 mov r3, r1, lsr #24
64 strb r3, [r2, #7]
2ef2b01e
A
65 END
66