Re: A89: Re: Displaying numbers
[Prev][Next][Index][Thread]
Re: A89: Re: Displaying numbers
On Fri, 9 Jun 2000, Scott Noveck wrote:
>
> Not the fastest? I haven't seen any other algorithms, so would you care to
> enlighten me as to how else this can be done?
You could store the number in BCD form, then division would be unneeded,
as you could just shift bits to get to them. The 68000 does have BCD add,
subtract, and negate instructions, so this is feasible for things like a
game's score and number of lives. Also, if the numbers are 16 or 32 bits
in length (4 or 8 digits) you can just cmp.w or cmp.l them as regular
values, for comparing with a high score table or such.
Follow-Ups:
References: