"idiv"ing double words - Printable Version +- Qbasicnews.com (http://qbasicnews.com/newforum) +-- Forum: QBasic (http://qbasicnews.com/newforum/forum-4.html) +--- Forum: QB Discussion & Programming Help (http://qbasicnews.com/newforum/forum-11.html) +--- Thread: "idiv"ing double words (/thread-4381.html) |
"idiv"ing double words - rCX - 07-28-2004 I'm stuck Awhile back I asked if there was a way to divide dx:ax by bx and get a double word anwer. (like FFFFFFFFh / Ah = 19999999h) and I got this peice of code..... Code: ;*dx:ax/bx; dx:ax = answer, cx = remainder* I was wondering if anyone knew how to do the same thing with the "idiv" (divide with sign) function. Thanks. "idiv"ing double words - DrV - 07-29-2004 If that code above is correct (too lazy to check it now), just replace div with idiv. "idiv"ing double words - rCX - 07-31-2004 Sorry I took so long.... I got this piece of code to work most of the time but when I tried to divide 6 0000h by Ah or 6 0000h by FFF6 (-Ah) I get a divide overflow error. Code: ;Register Function "idiv"ing double words - relsoft - 08-01-2004 Why not try to do a: Code: Cwde instead of a Code: cwd Dunno if you can use extended regs though. :*) "idiv"ing double words - rCX - 08-02-2004 I'm using DEBUG.exe I can't use double words... "idiv"ing double words - Plasma - 08-02-2004 http://www.aogosoft.com/download/debug32.rar |