* in the generic implementation of fpc_mul_int64, fallback directly to

fpc_mul_qword directly in case overflow checking is not used

git-svn-id: trunk@26483 -
This commit is contained in:
nickysn 2014-01-17 01:25:41 +00:00
parent e210d5f30e
commit 34cf432600

View File

@ -310,6 +310,13 @@
q1,q2,q3 : qword;
begin
{ there's no difference between signed and unsigned multiplication,
when the destination size is equal to the source size and overflow
checking is off }
if not checkoverflow then
{ qword(f1)*qword(f2) is coded as a call to mulqword }
fpc_mul_int64:=int64(qword(f1)*qword(f2))
else
begin
sign:=false;
if f1<0 then
@ -329,7 +336,7 @@
{ the q1*q2 is coded as call to mulqword }
q3:=q1*q2;
if checkoverflow and (q1 <> 0) and (q2 <>0) and
if (q1 <> 0) and (q2 <>0) and
((q1>q3) or (q2>q3) or
{ the bit 63 can be only set if we have $80000000 00000000 }
{ and sign is true }