1 /* SHA512 using sparc crypto opcodes.
2 Copyright (C) 2012-2015 Free Software Foundation, Inc.
3 This file is part of the GNU C Library.
4 Contributed by David S. Miller (davem@davemloft.net)
6 The GNU C Library is free software; you can redistribute it and/or
7 modify it under the terms of the GNU Lesser General Public
8 License as published by the Free Software Foundation; either
9 version 2.1 of the License, or (at your option) any later version.
11 The GNU C Library is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 Lesser General Public License for more details.
16 You should have received a copy of the GNU Lesser General Public
17 License along with the GNU C Library; if not, see
18 <http://www.gnu.org/licenses/>. */
27 ENTRY(__sha512_process_block_crop)
28 /* %o0=buffer, %o1=len, %o2=CTX */
39 1: ldd [%o2 + 0x00], %f0
44 ldd [%o2 + 0x28], %f10
46 ldd [%o2 + 0x30], %f12
48 ldd [%o2 + 0x38], %f14
51 ldd [%o0 + 0x00], %f16
52 ldd [%o0 + 0x08], %f18
53 ldd [%o0 + 0x10], %f20
54 ldd [%o0 + 0x18], %f22
55 ldd [%o0 + 0x20], %f24
56 ldd [%o0 + 0x28], %f26
57 ldd [%o0 + 0x30], %f28
58 ldd [%o0 + 0x38], %f30
59 ldd [%o0 + 0x40], %f32
60 ldd [%o0 + 0x48], %f34
61 ldd [%o0 + 0x50], %f36
62 ldd [%o0 + 0x58], %f38
63 ldd [%o0 + 0x60], %f40
64 ldd [%o0 + 0x68], %f42
65 ldd [%o0 + 0x70], %f44
66 ldd [%o0 + 0x78], %f46
80 std %f10, [%o2 + 0x28]
81 std %f12, [%o2 + 0x30]
83 std %f14, [%o2 + 0x38]
85 alignaddr %o0, %g0, %o0
87 ldd [%o0 + 0x00], %f18
89 ldd [%o0 + 0x08], %f20
90 ldd [%o0 + 0x10], %f22
91 ldd [%o0 + 0x18], %f24
92 ldd [%o0 + 0x20], %f26
93 ldd [%o0 + 0x28], %f28
94 ldd [%o0 + 0x30], %f30
95 ldd [%o0 + 0x38], %f32
96 ldd [%o0 + 0x40], %f34
97 ldd [%o0 + 0x48], %f36
98 ldd [%o0 + 0x50], %f38
99 ldd [%o0 + 0x58], %f40
100 ldd [%o0 + 0x60], %f42
101 ldd [%o0 + 0x68], %f44
102 ldd [%o0 + 0x70], %f46
103 ldd [%o0 + 0x78], %f48
104 ldd [%o0 + 0x80], %f50
106 faligndata %f18, %f20, %f16
107 faligndata %f20, %f22, %f18
108 faligndata %f22, %f24, %f20
109 faligndata %f24, %f26, %f22
110 faligndata %f26, %f28, %f24
111 faligndata %f28, %f30, %f26
112 faligndata %f30, %f32, %f28
113 faligndata %f32, %f34, %f30
114 faligndata %f34, %f36, %f32
115 faligndata %f36, %f38, %f34
116 faligndata %f38, %f40, %f36
117 faligndata %f40, %f42, %f38
118 faligndata %f42, %f44, %f40
119 faligndata %f44, %f46, %f42
120 faligndata %f46, %f48, %f44
121 faligndata %f48, %f50, %f46
131 END(__sha512_process_block_crop)