blob: 4d93c8a5e6c09069774d9deaf9d55f830e09c0c5 [file] [log] [blame]
Wolfgang Denkba94a1b2006-05-30 15:56:48 +02001/* Copyright 1995, 1996, 1998, 1999, 2000, 2003, 2004, 2005
2 Free Software Foundation, Inc.
3
Wolfgang Denk1a459662013-07-08 09:37:19 +02004 * SPDX-License-Identifier: GPL-2.0+
5 */
Wolfgang Denkba94a1b2006-05-30 15:56:48 +02006
7#ifdef __ARMEB__
8#define al r1
9#define ah r0
10#else
11#define al r0
12#define ah r1
13#endif
14
15.globl __ashrdi3
Wolfgang Denk59b4d742009-08-06 21:29:59 +020016.globl __aeabi_lasr
Wolfgang Denkba94a1b2006-05-30 15:56:48 +020017__ashrdi3:
Wolfgang Denk59b4d742009-08-06 21:29:59 +020018__aeabi_lasr:
Wolfgang Denkba94a1b2006-05-30 15:56:48 +020019
20 subs r3, r2, #32
21 rsb ip, r2, #32
22 movmi al, al, lsr r2
23 movpl al, ah, asr r3
24 orrmi al, al, ah, lsl ip
25 mov ah, ah, asr r2
26 mov pc, lr