Re: Fast Binary to BCD method on ARM9 with huge numbers?
From: Al Borowski (aj.borowski_at_erasethis.student.qut.edu.au)
Date: 03/09/04
- Next message: Al Borowski: "Re: Fast Binary to BCD method on ARM9 with huge numbers?"
- Previous message: Jack Klein: "Re: BLDC motor motor control - speed time response"
- In reply to: Robert Wessel: "Re: Fast Binary to BCD method on ARM9 with huge numbers?"
- Next in thread: Robert Wessel: "Re: Fast Binary to BCD method on ARM9 with huge numbers?"
- Reply: Robert Wessel: "Re: Fast Binary to BCD method on ARM9 with huge numbers?"
- Reply: Robert Wessel: "Re: Fast Binary to BCD method on ARM9 with huge numbers?"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Wed, 10 Mar 2004 03:10:11 +1000
Thanks for the replies...
> For a simple improvement, instead of dividing my ten, divide by
> 1,000,000,000 repeatedly, and then process each remained down into
> nine decimal digits. About nine times faster, overall. Or use the
> largest power of ten you can comfortably divide by. With ARM you'll
> probably be doing the usually multiply-by-reciprocal-and-shift thing
> for the division.
I have no idea how this works - can you please give me some pointers?
My divide-by-ten uses the method at
http://courses.cs.vt.edu/~cs1104/Division/ShiftSubtract/Shift.Subtract.html
There is no floating point unit, so I don't understand how to multiply
by .1. I'd apreciate it if you colud help me out.
>If you've got an ARM with long multiplies, divide
> by one billion, without long multiplies, you're probably best off
> using 10,000. You can tweak this a little by dividing by the largest
> convenient power of five instead, and then shifting by enough extra
> bits to convert that back to a power of ten (you can do 13 digits at a
> time by dividing by 5**13 and 2**13 in each pass). And be sure to
> keep truncating your dividend as the high words zero out – that'll
> double throughput right there.
>
Thanks, you've given me many things to think about.
Al
- Next message: Al Borowski: "Re: Fast Binary to BCD method on ARM9 with huge numbers?"
- Previous message: Jack Klein: "Re: BLDC motor motor control - speed time response"
- In reply to: Robert Wessel: "Re: Fast Binary to BCD method on ARM9 with huge numbers?"
- Next in thread: Robert Wessel: "Re: Fast Binary to BCD method on ARM9 with huge numbers?"
- Reply: Robert Wessel: "Re: Fast Binary to BCD method on ARM9 with huge numbers?"
- Reply: Robert Wessel: "Re: Fast Binary to BCD method on ARM9 with huge numbers?"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|