linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* Fix for __div64_32 locks when using some 64 bit numbers
@ 2009-03-17 21:15 davidastro
  2009-03-17 23:03 ` Benjamin Herrenschmidt
  0 siblings, 1 reply; 7+ messages in thread
From: davidastro @ 2009-03-17 21:15 UTC (permalink / raw)
  To: linuxppc-dev


I found a bug when using the function __div64_32 in assembly in a 32 bit ppc
architecture unit.

I tried the numbers 55834565048000000 for the dividend and 4294967079 for
the divisor. When passing these two numbers to the function  __div64_32, I
had a software lock. I searched for possible patches online and in different
forums but I could not find anything related to the assembly implementation
to this function (I would have to apologize if somebody already found a fix
:-) ).

Anyway, when analyzing the assembly code, I found out with gdb the problem.
I am not an expert in ppc architecture but I read the documentation and I am
pretty sure I solved the issue (I have been testing for couple of days using
random 64 to 32 number combinations with good results).

Who or Where should I post the fix to be reviewed.

Thanks for your attention
-- 
View this message in context: http://www.nabble.com/Fix-for-__div64_32-locks-when-using-some-64-bit-numbers-tp22567864p22567864.html
Sent from the linuxppc-dev mailing list archive at Nabble.com.

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2009-03-23 17:56 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-03-17 21:15 Fix for __div64_32 locks when using some 64 bit numbers davidastro
2009-03-17 23:03 ` Benjamin Herrenschmidt
2009-03-18 15:33   ` davidastro
2009-03-23  4:39     ` Paul Mackerras
2009-03-23 17:56       ` davidastro
2009-03-20 19:33   ` davidastro
2009-03-21 21:46     ` Benjamin Herrenschmidt

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).