Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

dx:cx:bx:ax <-- cx:bx * dx:ax

[b][red]This message was edited by deki at 2006-3-8 21:29:31[/red][/b][hr]
Hi, I need someone who understands assembly well to answer some questions:
1. I'm trying to read in 2^32 bit integer using 16 bit registers
(not allowed to use extended reg:eax)
-In file, file0.asm loop:I read char from keyboard then convert to
integer by ( mov ax, 0fh 30->0, 31->1 ...) then call file1.asm to
to perform multiplication of cx:dx * dx:ax-> the result is stored in
dx:cx:bx:ax,(multiply each converted char to digit by 10), then in
the next loop do the same thing and this time add the product stored
in the dx:cx:bx:ax. The thing is I dont understand if I
save the current number let say the product is ax:ffff
bx:0000
cx:0000
dx:0023
so the hex in dx:ax, but in the next loop I need to use ax and dx.
and I would like to store temporary 23ffff, then add it to the next
product. How do you reffer to dx:ax, if you want to push and pop
dx:ax?Please any help is appreciated.

Comments

  • dekideki Member Posts: 2
    : [b][red]This message was edited by deki at 2006-3-8 21:29:31[/red][/b][hr]
    : Hi, I need someone who understands assembly well to answer some questions:
    : 1. I'm trying to read in 2^32 bit integer using 16 bit registers
    : (not allowed to use extended reg:eax)
    : -In file, file0.asm loop:I read char from keyboard then convert to
    : integer by ( mov ax, 0fh 30->0, 31->1 ...) then call file1.asm to
    : to perform multiplication of cx:dx * dx:ax-> the result is stored in
    : dx:cx:bx:ax,(multiply each converted char to digit by 10), then in
    : the next loop do the same thing and this time add the product stored
    : in the dx:cx:bx:ax. The thing is I dont understand if I
    : save the current number let say the product is ax:ffff
    : bx:0000
    : cx:0000
    : dx:0023
    : so the hex in dx:ax, but in the next loop I need to use ax and dx.
    : and I would like to store temporary 23ffff, then add it to the next
    : product. How do you reffer to dx:ax, if you want to push and pop
    : dx:ax?Please any help is appreciated.
    :
    I've figure it out!
Sign In or Register to comment.