PDA

View Full Version : Assembly Code Multiplication


DoomSlice
09-26-2005, 12:13 AM
Anyone know how to do an efficient Assembly Code multiplication of 2 15 bit numbers into a 32 bit register using the following operations:

nand rA rB dest
add rA rB dest
beq rA rB offset (branch to offset or label if rA = rB)
halt

I need to simulate bit shifting by using add and somehow use nand to figure out the product of the two by using some combination of nands.

2ndGoat
09-27-2005, 04:02 PM
This wouldn't happen to be a homework problem for junior level architecture, would it?

You wouldn't be trying to get someone to do your homework for you, would you?

2nd

MyMindIsGoing
09-27-2005, 04:26 PM
http://www.cs.wisc.edu/~smoler/x86text/lect.notes/arith.int.html