source: trunk/libs/newlib/src/newlib/libc/machine/h8500/mulhi3.c @ 444

Last change on this file since 444 was 444, checked in by satin@…, 6 years ago

add newlib,libalmos-mkh, restructure shared_syscalls.h and mini-libc

File size: 153 bytes
Line 
1
2
3short 
4__mulhi3(short a, short b)
5{
6  int r;
7
8  r = 0;
9  while (a) 
10    {
11      if (a & 1) 
12        {
13          r += b;
14          a>>=1;
15          b<<=1;
16        }
17    }
18  return r;
19}
20
21
Note: See TracBrowser for help on using the repository browser.