Re: Signed multiplication

From: Spiro Trikaliotis <ml-cbmhackers_at_trikaliotis.net>
Date: Sat, 7 Nov 2009 12:12:56 +0100
Message-ID: <20091107111256.GA3918@trikaliotis.net>
Hello Uz,

* On Wed, Nov 04, 2009 at 02:42:37PM +0100 Ullrich von Bassewitz wrote:

> I'm looking for a signed 16x16 => 32 multiplication routine. Currently I'm
> using the 16x16 => 32 unsigned routine with the absolute values of the
> operands, and adjust the sign of the result if necessary. But this quite some
> overhead. 

Have you had a look at the Booth Algorithm?

  http://en.wikipedia.org/wiki/Booth_algorithm
  http://de.wikipedia.org/wiki/Booth-Algorithmus

  or at my former working group:

  http://ivs.cs.uni-magdeburg.de/EuK/lehre/lehrveranstaltungen/ws0809/tgi.shtml,
  here: Slides for "Computerarithmetik (Part 4)", Slides 34ff

I do not know of a 6502 implementation of it, though, and I do not know
if it would be faster than what is currently available.

Looking for example at
http://www.freepatentsonline.com/y2007/0198625.html, Booth algorithm
still seems to be widely used. AFAIK, it is often used for hardware
implementations of Multiplications.

HTH,
Spiro.

-- 
Spiro R. Trikaliotis                              http://opencbm.sf.net/
http://www.trikaliotis.net/                     http://www.viceteam.org/

       Message was sent through the cbm-hackers mailing list
Received on 2009-11-07 12:00:04

Archive generated by hypermail 2.2.0.