diff options
author | usa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2012-11-09 02:21:31 +0000 |
---|---|---|
committer | usa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2012-11-09 02:21:31 +0000 |
commit | 122b6dbcb7c7c5e3c02277d75b5f38bc6d5c3103 (patch) | |
tree | 1fec9f368f04d5636ee625c5888233b3be8a677d /bignum.c | |
parent | 88566f08b7f9294706b6ef786cd6d57bd6aa5e5c (diff) |
merge revision(s) 37565: [Backport #7315]
* bignum.c (bigmul0): disable big_mul_toom3_temporalily.
[ruby-core:48552] [Bug #7242]
* test/ruby/test_bignum.rb (test_mul_large_numbers):
add a test for bigmul1_toom3 suggested in [Bug #7242].
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_9_3@37570 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'bignum.c')
-rw-r--r-- | bignum.c | 9 |
1 files changed, 2 insertions, 7 deletions
@@ -2535,13 +2535,8 @@ bigmul0(VALUE x, VALUE y) /* balance multiplication by slicing y when x is much smaller than y */ if (2 * xn <= yn) return bigmul1_balance(x, y); - if (xn < TOOM3_MUL_DIGITS) { - /* multiplication by karatsuba method */ - return bigmul1_karatsuba(x, y); - } - else if (3*xn <= 2*(yn + 2)) - return bigmul1_balance(x, y); - return bigmul1_toom3(x, y); + /* multiplication by karatsuba method */ + return bigmul1_karatsuba(x, y); } /* |