http://git.etherboot.org
/
people
/
dverkamp
/
gpxe.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c789e86
)
Assert that division result is correct
author
Michael Brown
<mcb30@etherboot.org>
Wed, 31 Jan 2007 23:58:52 +0000
(23:58 +0000)
committer
Michael Brown
<mcb30@etherboot.org>
Wed, 31 Jan 2007 23:58:52 +0000
(23:58 +0000)
src/arch/i386/core/udivmod64.c
patch
|
blob
|
history
diff --git
a/src/arch/i386/core/udivmod64.c
b/src/arch/i386/core/udivmod64.c
index
bb58102
..
b4f14b1
100644
(file)
--- a/
src/arch/i386/core/udivmod64.c
+++ b/
src/arch/i386/core/udivmod64.c
@@
-303,6
+303,9
@@
UDItype __udivmoddi4 ( UDItype x, UDItype d, UDItype *r ) {
udivmod64 ( ( struct uint64 * ) _x, ( struct uint64 * ) _d,
( struct uint64 * ) _q, ( struct uint64 * ) _r );
+
+ assert ( ( x == ( ( d * q ) + (*r) ) ) );
+
return q;
}