[前][次][番号順一覧][スレッド一覧]

ruby-changes:29449

From: akr <ko1@a...>
Date: Thu, 20 Jun 2013 23:09:43 +0900 (JST)
Subject: [ruby-changes:29449] akr:r41501 (trunk): * bignum.c (bigmul1_toom3): Don't call bignorm twice.

akr	2013-06-20 23:09:32 +0900 (Thu, 20 Jun 2013)

  New Revision: 41501

  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=41501

  Log:
    * bignum.c (bigmul1_toom3): Don't call bignorm twice.

  Modified files:
    trunk/ChangeLog
    trunk/bignum.c

Index: ChangeLog
===================================================================
--- ChangeLog	(revision 41500)
+++ ChangeLog	(revision 41501)
@@ -1,3 +1,7 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1
+Thu Jun 20 22:52:42 2013  Tanaka Akira  <akr@f...>
+
+	* bignum.c (bigmul1_toom3): Don't call bignorm twice.
+
 Thu Jun 20 22:49:27 2013  Tanaka Akira  <akr@f...>
 
 	* bignum.c (bignorm): Don't call bigtrunc if the result is a fixnum.
Index: bignum.c
===================================================================
--- bignum.c	(revision 41500)
+++ bignum.c	(revision 41501)
@@ -3684,7 +3684,6 @@ bigmul1_toom3(VALUE x, VALUE y) https://github.com/ruby/ruby/blob/trunk/bignum.c#L3684
     bigadd_core(zds + 2*n, zn - 2*n, BDIGITS(z2), big_real_len(z2), zds + 2*n, zn - 2*n);
     bigadd_core(zds + 3*n, zn - 3*n, BDIGITS(z3), big_real_len(z3), zds + 3*n, zn - 3*n);
     bigadd_core(zds + 4*n, zn - 4*n, BDIGITS(z4), big_real_len(z4), zds + 4*n, zn - 4*n);
-    z = bignorm(z);
 
     return bignorm(z);
 }

--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]