1 ; Copyright (C) 2012-2023 Free Software Foundation, Inc.
2 ; Contributed by Red Hat.
4 ; This file is free software; you can redistribute it and/or modify it
5 ; under the terms of the GNU General Public License as published by the
6 ; Free Software Foundation; either version 3, or (at your option) any
9 ; This file is distributed in the hope that it will be useful, but
10 ; WITHOUT ANY WARRANTY; without even the implied warranty of
11 ; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 ; General Public License for more details.
14 ; Under Section 7 of GPL version 3, you are granted additional
15 ; permissions described in the GCC Runtime Library Exception, version
16 ; 3.1, as published by the Free Software Foundation.
18 ; You should have received a copy of the GNU General Public License and
19 ; a copy of the GCC Runtime Library Exception along with this program;
20 ; see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
21 ; <http://www.gnu.org/licenses/>.
26 ;; Argument is in [SP+4], return in R8.
29 .global __clzhi2_internal
47 ;; Argument is in [SP+6]:[SP+4], return in R8.
50 bnz $__clzhi2_internal
52 call !__clzhi2_internal
61 ;; Argument is in [SP+4], return in R8.
64 .global __ctzhi2_internal
82 ;; Argument is in [SP+6]:[SP+4], return in R8.
85 bnz $__ctzhi2_internal
87 call !__ctzhi2_internal
96 ;; Argument is in [SP+4], return in R8.
99 .global __ffshi2_internal
117 ;; Argument is in [SP+6]:[SP+4], return in R8.
120 bnz $__ffshi2_internal
124 call !__ffshi2_internal
133 START_FUNC ___parityqi_internal
148 END_FUNC ___parityqi_internal
151 START_FUNC ___parityhi2
152 ;; Argument is in [SP+4], return in R8.
155 br $___parityqi_internal
156 END_FUNC ___parityhi2
159 START_FUNC ___paritysi2
160 ;; Argument is in [SP+6]:[SP+4], return in R8.
167 br $___parityqi_internal
168 END_FUNC ___paritysi2
172 START_FUNC ___popcounthi2
173 ;; Argument is in [SP+4], return in R8.
175 br $___popcountqi_internal
176 END_FUNC ___popcounthi2
179 START_FUNC ___popcountsi2
180 ;; Argument is in [SP+6]:[SP+4], return in R8.
182 br $___popcountqi_internal
183 END_FUNC ___popcountsi2
186 START_FUNC ___popcountqi_internal
187 ;; There are D bytes starting at [HL]
188 ;; store count in R8.
213 END_FUNC ___popcountqi_internal