Project

General

Profile

Bug #10464

Bignum同士の乗算の不具合

Added by Nishihama (Kohji Nishihama) over 4 years ago. Updated over 4 years ago.

Status:
Closed
Priority:
Normal
Target version:
ruby -v:
ruby 2.1.4p265 (2014-10-27 revision 48166) [i386-mingw32]
[ruby-dev:48723]

Description

あるBignum同士を乗算すると、誤った値が出力されます。
OSはWindows Vista Home Premium。
なお、ruby 1.8.7 (2008-08-11 patchlevel 72) [i386-mswin32]、ruby 1.9.3p484 (2013-11-22) [i386-mingw32]、200: ruby 2.0.0p353 (2013-11-22) [i386-mingw32]では正常に動作し、
ruby 2.1.3p242 (2014-09-19 revision 47630) [i386-mingw32]では同様に不具合が生じました。

$ ruby bug.rb
5470148495 # 誤った乗算の値
1943359375 # 真の乗算の値
#なお、冗長になるので下10桁のみを表示しています


Files

bug.rb (16.9 KB) bug.rb Nishihama (Kohji Nishihama), 11/01/2014 04:18 AM

Related issues

Copied to Ruby trunk - Bug #10465: Bug of multiplication between BignumsClosed11/01/2014Actions

Associated revisions

Revision 905b5221
Added by akr (Akira Tanaka) over 4 years ago

  • bignum.c (bary_mul_balance_with_mulfunc): Fix free work area location. [ruby-dev:48723] [Bug #10464] [ruby-core:66044] [Bug #10465] Reported by Kohji Nishihama.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48222 b2dd03c8-39d4-4d8f-98ff-823fe69b080e

Revision 48222
Added by akr (Akira Tanaka) over 4 years ago

  • bignum.c (bary_mul_balance_with_mulfunc): Fix free work area location. [ruby-dev:48723] [Bug #10464] [ruby-core:66044] [Bug #10465] Reported by Kohji Nishihama.

Revision 48222
Added by akr (Akira Tanaka) over 4 years ago

  • bignum.c (bary_mul_balance_with_mulfunc): Fix free work area location. [ruby-dev:48723] [Bug #10464] [ruby-core:66044] [Bug #10465] Reported by Kohji Nishihama.

Revision 48222
Added by akr (Akira Tanaka) over 4 years ago

  • bignum.c (bary_mul_balance_with_mulfunc): Fix free work area location. [ruby-dev:48723] [Bug #10464] [ruby-core:66044] [Bug #10465] Reported by Kohji Nishihama.

Revision 48222
Added by akr (Akira Tanaka) over 4 years ago

  • bignum.c (bary_mul_balance_with_mulfunc): Fix free work area location. [ruby-dev:48723] [Bug #10464] [ruby-core:66044] [Bug #10465] Reported by Kohji Nishihama.

Revision 48222
Added by akr (Akira Tanaka) over 4 years ago

  • bignum.c (bary_mul_balance_with_mulfunc): Fix free work area location. [ruby-dev:48723] [Bug #10464] [ruby-core:66044] [Bug #10465] Reported by Kohji Nishihama.

Revision 48222
Added by akr (Akira Tanaka) over 4 years ago

  • bignum.c (bary_mul_balance_with_mulfunc): Fix free work area location. [ruby-dev:48723] [Bug #10464] [ruby-core:66044] [Bug #10465] Reported by Kohji Nishihama.

Revision a7987d8b
Added by nagachika (Tomoyuki Chikanaga) over 4 years ago

merge revision(s) r48222: [Backport #10464] [Backport #10465]

* bignum.c (bary_mul_balance_with_mulfunc): Fix free work area
  location.
  [ruby-dev:48723] [Bug #10464]
  [ruby-core:66044] [Bug #10465]
  Reported by Kohji Nishihama.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_1@48272 b2dd03c8-39d4-4d8f-98ff-823fe69b080e

Revision 48272
Added by nagachika (Tomoyuki Chikanaga) over 4 years ago

merge revision(s) r48222: [Backport #10464] [Backport #10465]

* bignum.c (bary_mul_balance_with_mulfunc): Fix free work area
  location.
  [ruby-dev:48723] [Bug #10464]
  [ruby-core:66044] [Bug #10465]
  Reported by Kohji Nishihama.

History

Updated by Nishihama (Kohji Nishihama) over 4 years ago

対象バージョン:を誤ってしまいました。
正しくは2.1.0です。

Updated by Nishihama (Kohji Nishihama) over 4 years ago

  • Copied to Bug #10465: Bug of multiplication between Bignums added

Updated by akr (Akira Tanaka) over 4 years ago

  • Status changed from Open to Closed
  • % Done changed from 0 to 100

Applied in changeset r48222.


  • bignum.c (bary_mul_balance_with_mulfunc): Fix free work area location. [ruby-dev:48723] [Bug #10464] [ruby-core:66044] [Bug #10465] Reported by Kohji Nishihama.

Updated by nagachika (Tomoyuki Chikanaga) over 4 years ago

  • Backport changed from 2.0.0: UNKNOWN, 2.1: UNKNOWN to 2.0.0: DONTNEED, 2.1: REQUIRED

Updated by nagachika (Tomoyuki Chikanaga) over 4 years ago

  • Backport changed from 2.0.0: DONTNEED, 2.1: REQUIRED to 2.0.0: DONTNEED, 2.1: DONE

Backported into ruby_2_1 at r48272.

Also available in: Atom PDF